diff options
| author | Claudius "keldu" Holeksa <mail@keldu.de> | 2026-06-02 19:16:37 +0200 |
|---|---|---|
| committer | Claudius "keldu" Holeksa <mail@keldu.de> | 2026-06-02 19:16:37 +0200 |
| commit | d7c88d561d4e2b7a2706d14c11ea5fa4cd6ceaf3 (patch) | |
| tree | 076199318c78e16ef8f73e3a07db833937c6f972 | |
| parent | eb97ceef955fa1c5e3794c74fc9894fda1ce6f21 (diff) | |
| download | libs-lbm-d7c88d561d4e2b7a2706d14c11ea5fa4cd6ceaf3.tar.gz | |
Fixing Desc name
| -rw-r--r-- | lib/core/c++/hlbm.hpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/core/c++/hlbm.hpp b/lib/core/c++/hlbm.hpp index ed49353..6ae7d80 100644 --- a/lib/core/c++/hlbm.hpp +++ b/lib/core/c++/hlbm.hpp @@ -43,8 +43,8 @@ public: /** * HLBM collision operator for LBM */ -template<typename T, typename Descriptor, typename Encode> -class component<T, Descriptor, cmpt::Hlbm, Encode> final { +template<typename T, typename Desc, typename Encode> +class component<T, Desc, cmpt::Hlbm, Encode> final { private: typename saw::native_data_type<T>::type relaxation_; saw::data<T> frequency_; @@ -55,7 +55,7 @@ public: {} template<typename CellFieldSchema, typename MacroFieldSchema> - void apply(const saw::data<CellFieldSchema, Encode>& field, const saw::data<MacroFieldSchema,Encode>& macros, saw::data<sch::FixedArray<sch::UInt64,Descriptor::D>> index, saw::data<sch::UInt64> time_step) const { + void apply(const saw::data<CellFieldSchema, Encode>& field, const saw::data<MacroFieldSchema,Encode>& macros, saw::data<sch::FixedArray<sch::UInt64,Desc::D>> index, saw::data<sch::UInt64> time_step) const { bool is_even = ((time_step.get() % 2) == 0); @@ -68,9 +68,9 @@ public: auto& vel_f = macros.template get<"velocity">(); saw::data<sch::Scalar<T>>& rho = rho_f.at(index); - saw::data<sch::Vector<T,Descriptor::D>>& vel = vel_f.at(index); + saw::data<sch::Vector<T,Desc::D>>& vel = vel_f.at(index); - compute_rho_u<T,Descriptor>(dfs_old_f.at(index), rho, vel); + compute_rho_u<T,Desc>(dfs_old_f.at(index), rho, vel); auto& porosity = porosity_f.at(index); saw::data<sch::Scalar<T>> one; @@ -80,13 +80,13 @@ public: auto& N = particle_N_f.at(index); auto& D = particle_D_f.at(index); // Convex combination of velocities - vel = vel * porosity + [&]() -> saw::data<sch::Vector<T,Descriptor::D>> { + vel = vel * porosity + [&]() -> saw::data<sch::Vector<T,Desc::D>> { return (D.at({}).get() > 0.0 ? N * flip_porosity / D : N); }(); // Equilibrium - auto eq = equilibrium<T,Descriptor>(rho,vel); + auto eq = equilibrium<T,Desc>(rho,vel); - for(uint64_t i = 0u; i < Descriptor::Q; ++i){ + for(uint64_t i = 0u; i < Desc::Q; ++i){ dfs_old_f.at(index).at({i}) = dfs_old_f.at(index).at({i}) + frequency_ * (eq.at(i) - dfs_old_f.at(index).at({i})); } @@ -101,7 +101,7 @@ namespace impl { } template<typename T, typename Desc, typename Encode> -class component<T, Descriptor, cmpt::HlbmParticle, Encode> final { +class component<T, Desc, cmpt::HlbmParticle, Encode> final { private: template<typename CellFieldSchema, typename MacroFieldSchema, typename ParticleSchema, uint64_t i> void apply_i(const saw::data<CellFieldSchema, Encode>& field, const saw::data<MacroFieldSchema,Encode>& macros, const saw::data<ParticleSchema,Encode>& part_groups, saw::data<sch::FixedArray<sch::UInt64,1u>> index, saw::data<sch::UInt64> time_step) const { |
