diff options
| author | Claudius "keldu" Holeksa <mail@keldu.de> | 2026-09-07 15:08:20 +0200 |
|---|---|---|
| committer | Claudius "keldu" Holeksa <mail@keldu.de> | 2026-09-07 15:08:20 +0200 |
| commit | 96619fc23312e91e9fbe453cb115f116784c032a (patch) | |
| tree | 9d931191117f54f2134b3ad3615e2092870a99ca /examples/one_particle_sedimentation_2d | |
| parent | d2a406aceeb935d4eac1b5ae02e268be4463b6b0 (diff) | |
| parent | 54dfad7ac102fe40d71d8818d77801160a7073c1 (diff) | |
| download | libs-lbm-96619fc23312e91e9fbe453cb115f116784c032a.tar.gz | |
Diffstat (limited to 'examples/one_particle_sedimentation_2d')
4 files changed, 6 insertions, 5 deletions
diff --git a/examples/one_particle_sedimentation_2d/common.hpp b/examples/one_particle_sedimentation_2d/common.hpp index 18d6584..ffb7f40 100644 --- a/examples/one_particle_sedimentation_2d/common.hpp +++ b/examples/one_particle_sedimentation_2d/common.hpp @@ -23,8 +23,8 @@ namespace lbm { * fluid density 0.001g/mm³ */ -constexpr uint64_t dim_y = 800ul; constexpr uint64_t dim_x = 200ul; +constexpr uint64_t dim_y = 800ul; constexpr uint64_t particle_amount = 1ul; diff --git a/examples/one_particle_sedimentation_2d/init.hpp b/examples/one_particle_sedimentation_2d/init.hpp index d9b8a37..8bcc236 100644 --- a/examples/one_particle_sedimentation_2d/init.hpp +++ b/examples/one_particle_sedimentation_2d/init.hpp @@ -75,7 +75,7 @@ saw::error_or<void> init( { saw::data<sch::Scalar<T>> radius_p; - radius_p.at({}).set(conv.meter_si_to_lbm({{0.05}}).handle().get()); + radius_p.at({}).set(conv.meter_si_to_lbm({{0.00125}}).handle().get()); std::cout<<"RADIUS: "<<radius_p.at({}).get()<<std::endl; saw::data<sch::Scalar<T>> dense_p; dense_p.at({}).set(1); diff --git a/examples/one_particle_sedimentation_2d/sim.cpp b/examples/one_particle_sedimentation_2d/sim.cpp index a722fc3..0cb3ce0 100644 --- a/examples/one_particle_sedimentation_2d/sim.cpp +++ b/examples/one_particle_sedimentation_2d/sim.cpp @@ -51,7 +51,8 @@ saw::error_or<void> lbm_main(const saw::data<args::LbmArgs>& args){ {{1.5e-6}} }; - print_lbm_meta<T,Desc>(conv,{1e-3},{1e-4},{0.02}); + print_lbm_meta<T,Desc>(conv,{1e-3},{1e-4},{2}); + std::cout<<"Position: "<<conv.meter_si_to_lbm({{0.01}}).handle().get()<<", "<<conv.meter_si_to_lbm({{0.04}}).handle().get()<<std::endl; // saw::data<sch::FixedArray<sch::UInt64,Desc::D>> meta{{dim_x,dim_y}}; auto lbm_data_ptr = saw::heap<saw::data<sch::ChunkStruct<T,Desc>>>(); @@ -144,7 +145,7 @@ saw::error_or<void> lbm_main(const saw::data<args::LbmArgs>& args){ } } { - auto eov = write_csv_file(out_dir,"ops_2d",i.get(), *lbm_macro_data_ptr); + auto eov = write_vtk_file(out_dir,"ops_2d",i.get(), *lbm_macro_data_ptr); if(eov.is_error()){ return eov; } diff --git a/examples/one_particle_sedimentation_2d/step.hpp b/examples/one_particle_sedimentation_2d/step.hpp index 86064ae..c3a3b8a 100644 --- a/examples/one_particle_sedimentation_2d/step.hpp +++ b/examples/one_particle_sedimentation_2d/step.hpp @@ -175,7 +175,7 @@ saw::error_or<void> step( index.at({{i}}).set(idx[i]); } - fplbm_one_part.apply(fields,macros,particles,index,t_i,{16u}); + fplbm_one_part.apply(fields,macros,particles,index,t_i,{32u}); }); }).wait(); |
