summaryrefslogtreecommitdiff
path: root/c++
diff options
context:
space:
mode:
authorClaudius "keldu" Holeksa <mail@keldu.de>2025-04-18 16:35:52 +0200
committerClaudius "keldu" Holeksa <mail@keldu.de>2025-04-18 16:35:52 +0200
commitb0a68aba927aaafc97816d18b50b219a595b4dd2 (patch)
tree34eb4c44677609e1e15c676857c4121292247b65 /c++
parentae8711ba90ac2a47ea7654dc873927fb2783ff91 (diff)
Compileable state
Diffstat (limited to 'c++')
-rw-r--r--c++/descriptor.hpp3
-rw-r--r--c++/macroscopic.hpp12
2 files changed, 10 insertions, 5 deletions
diff --git a/c++/descriptor.hpp b/c++/descriptor.hpp
index aa8c943..b1ee5b1 100644
--- a/c++/descriptor.hpp
+++ b/c++/descriptor.hpp
@@ -1,6 +1,7 @@
#pragma once
#include <forstio/codec/data.hpp>
+#include <forstio/codec/schema_factory.hpp>
namespace kel {
namespace lbm {
@@ -164,10 +165,12 @@ public:
factory_struct_{inp}
{}
+ /*
template<typename TA, saw::string_literal KA>
constexpr auto require() const noexcept {
return {factory_struct_.add_maybe()};
}
+ */
};
}
diff --git a/c++/macroscopic.hpp b/c++/macroscopic.hpp
index 608b89e..43c727b 100644
--- a/c++/macroscopic.hpp
+++ b/c++/macroscopic.hpp
@@ -1,18 +1,20 @@
#pragma once
+#include "descriptor.hpp"
+
namespace kel {
namespace lbm {
/**
* Calculate the macroscopic variables rho and u in Lattice Units.
*/
-template<typename Desc>
+template<typename T, typename Desc>
void compute_rho_u (
- const saw::data<sch::DfCell<Desc>>& dfs,
- typename saw::native_data_type<sch::T>::type& rho,
- std::array<typename saw::native_data_type<sch::T>::type, 2>& vel
+ saw::data<sch::Cell<T, Desc, 0, 0, 1>>& dfs,
+ typename saw::native_data_type<T>::type& rho,
+ std::array<typename saw::native_data_type<T>::type, 2>& vel
)
{
- using dfi = df_info<sch::T, Desc>;
+ using dfi = df_info<T, Desc>;
rho = 0;
std::fill(vel.begin(), vel.end(), 0);