diff options
author | Claudius "keldu" Holeksa <mail@keldu.de> | 2025-06-26 13:46:27 +0200 |
---|---|---|
committer | Claudius "keldu" Holeksa <mail@keldu.de> | 2025-06-26 13:46:27 +0200 |
commit | cab30f5fff0c8e96a81f2addb7c190a55b9f5377 (patch) | |
tree | 9eadd8110467378714b5f9b70da9c3f48ba43bc7 /examples | |
parent | 3a1401dff3839ade801eb09598985d318e514350 (diff) |
Intermittent changes
Diffstat (limited to 'examples')
-rw-r--r-- | examples/cavity_2d.cpp | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/examples/cavity_2d.cpp b/examples/cavity_2d.cpp index ca291d3..ca42894 100644 --- a/examples/cavity_2d.cpp +++ b/examples/cavity_2d.cpp @@ -259,7 +259,7 @@ void lbm_step( switch(info({0u}).get()){ case 1u: { - coll.apply(latt, {{i,j}}, time_step); + coll.apply(latt, {{i,j}}, time_step+1u); break; } case 2u: { @@ -270,13 +270,30 @@ void lbm_step( case 3u: { auto& df = even_step ? cell.template get<"dfs_old">() : cell.template get<"dfs">(); // bb_two.apply(df); - bb.apply(latt, {{i,j}}, time_step); + // bb.apply(latt, {{i,j}}, time_step); break; } + default: + break; } } } + apply_for_cells([&](auto cell, size_t i, size_t j){ + auto& info = cell.template get<"info">(); + + auto info_v = info({0u}).get(); + switch(info_v){ + case 3u: { + auto& df = even_step ? cell.template get<"dfs_old">() : cell.template get<"dfs">(); + bb_two.apply(df); + break; + } + default: + break; + } + },latt); + // Stream for(uint64_t i = 1u; (i+1u) < latt.template get_dim_size<0>().get(); ++i){ for(uint64_t j = 1u; (j+1u) < latt.template get_dim_size<1>().get(); ++j){ |