summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--examples/one_particle_sedimentation_2d/.nix/derivation.nix (renamed from examples/one_particle_sedimentation/.nix/derivation.nix)3
-rw-r--r--examples/one_particle_sedimentation_2d/SConscript (renamed from examples/one_particle_sedimentation/SConscript)0
-rw-r--r--examples/one_particle_sedimentation_2d/SConstruct (renamed from examples/one_particle_sedimentation/SConstruct)0
-rw-r--r--examples/one_particle_sedimentation_2d/common.hpp (renamed from examples/one_particle_sedimentation/common.hpp)2
-rw-r--r--examples/one_particle_sedimentation_2d/init.hpp (renamed from examples/one_particle_sedimentation/init.hpp)24
-rw-r--r--examples/one_particle_sedimentation_2d/sim.cpp (renamed from examples/one_particle_sedimentation/sim.cpp)8
-rw-r--r--examples/one_particle_sedimentation_2d/step.hpp (renamed from examples/one_particle_sedimentation/step.hpp)0
-rw-r--r--examples/schaefer_turek_durst_krause_rannbacher/.nix/derivation.nix3
8 files changed, 9 insertions, 31 deletions
diff --git a/examples/one_particle_sedimentation/.nix/derivation.nix b/examples/one_particle_sedimentation_2d/.nix/derivation.nix
index a062133..49fa939 100644
--- a/examples/one_particle_sedimentation/.nix/derivation.nix
+++ b/examples/one_particle_sedimentation_2d/.nix/derivation.nix
@@ -8,12 +8,11 @@
, version
, adaptive-cpp
, kel
-, particle_coupling ? "fplbm"
}:
let
in stdenv.mkDerivation {
- pname = "${pname}-examples-ops_2d_gpu_${particle_coupling}";
+ pname = "${pname}-examples-ops_2d_gpu";
inherit version;
src = ./..;
diff --git a/examples/one_particle_sedimentation/SConscript b/examples/one_particle_sedimentation_2d/SConscript
index 40f4052..40f4052 100644
--- a/examples/one_particle_sedimentation/SConscript
+++ b/examples/one_particle_sedimentation_2d/SConscript
diff --git a/examples/one_particle_sedimentation/SConstruct b/examples/one_particle_sedimentation_2d/SConstruct
index 0611b67..0611b67 100644
--- a/examples/one_particle_sedimentation/SConstruct
+++ b/examples/one_particle_sedimentation_2d/SConstruct
diff --git a/examples/one_particle_sedimentation/common.hpp b/examples/one_particle_sedimentation_2d/common.hpp
index be9a538..37e0402 100644
--- a/examples/one_particle_sedimentation/common.hpp
+++ b/examples/one_particle_sedimentation_2d/common.hpp
@@ -22,7 +22,7 @@ namespace lbm {
*/
constexpr uint64_t dim_y = 512ul;
-constexpr uint64_t dim_x = static_cast<uint64_t>(dim_y * (220.0 / 41.0));
+constexpr uint64_t dim_x = 256ul;
constexpr uint64_t particle_amount = 1ul;
diff --git a/examples/one_particle_sedimentation/init.hpp b/examples/one_particle_sedimentation_2d/init.hpp
index af7eb89..a35c6e8 100644
--- a/examples/one_particle_sedimentation/init.hpp
+++ b/examples/one_particle_sedimentation_2d/init.hpp
@@ -12,10 +12,9 @@ saw::error_or<void> init(
saw::data<sch::MacroStruct<T,Desc>>& macros,
saw::data<sch::ParticleSpheroidGroup<T,Desc>>& particles
){
- (void) conv;
-
auto& info_f = fields.template get<"info">();
auto& porous_f = macros.template get<"porosity">();
+
// Set everything as walls
iterator<Desc::D>::apply(
[&](auto& index){
@@ -25,6 +24,7 @@ saw::error_or<void> init(
info_f.get_dims(),
{}
);
+
// Fluid
iterator<Desc::D>::apply(
[&](auto& index){
@@ -35,26 +35,6 @@ saw::error_or<void> init(
{{1u,1u}}
);
- // Inflow
- iterator<Desc::D>::apply(
- [&](auto& index){
- info_f.at(index).set(3u);
- },
- {{0u,0u}},
- {{1u,dim_y}},
- {{0u,1u}}
- );
-
- // Outflow
- iterator<Desc::D>::apply(
- [&](auto& index){
- info_f.at(index).set(4u);
- },
- {{dim_x-1u,0u}},
- {{dim_x, dim_y}},
- {{0u,1u}}
- );
- //
auto& df_f = fields.template get<"dfs_old">();
auto& rho_f = macros.template get<"density">();
auto& vel_f = macros.template get<"momentum">();
diff --git a/examples/one_particle_sedimentation/sim.cpp b/examples/one_particle_sedimentation_2d/sim.cpp
index b3422a5..7c9a56c 100644
--- a/examples/one_particle_sedimentation/sim.cpp
+++ b/examples/one_particle_sedimentation_2d/sim.cpp
@@ -34,7 +34,7 @@ saw::error_or<void> lbm_main(const saw::data<args::LbmArgs>& args){
}
auto& lbm_dir = eo_lbm_dir.get_value();
- auto out_dir = lbm_dir / "stdkr_2d_gpu" / an.template get<"coupling">().stl_view();
+ auto out_dir = lbm_dir / "ops_2d" / an.template get<"coupling">().stl_view();
{
std::error_code ec;
@@ -144,7 +144,7 @@ saw::error_or<void> lbm_main(const saw::data<args::LbmArgs>& args){
}
}
{
- auto eov = write_csv_file(out_dir,"stdkr_2d",i.get(), *lbm_macro_data_ptr);
+ auto eov = write_csv_file(out_dir,"ops_2d",i.get(), *lbm_macro_data_ptr);
if(eov.is_error()){
return eov;
}
@@ -173,7 +173,7 @@ saw::error_or<void> lbm_main(const saw::data<args::LbmArgs>& args){
std::cout<<"Status: "<<i.get()<<" of "<<time_steps.get()<<" - "<<(i.template cast_to<sch::Float64>().get() * 100 / time_steps.get())<<"%"<<std::endl;
print_status = false;
}
- print_progress_bar(i.get(), time_steps.get()-1u);
+ print_progress_bar(i.get()+1u, time_steps.get());
}
// After Loop
sycl_q.wait();
@@ -184,7 +184,7 @@ saw::error_or<void> lbm_main(const saw::data<args::LbmArgs>& args){
}
}
{
- auto eov = write_vtk_file(out_dir,std::string{"stdkr_2d_"}+an.template get<"coupling">().stl_string(),time_steps.get(), *lbm_macro_data_ptr);
+ auto eov = write_vtk_file(out_dir,std::string{"ops_2d_"}+an.template get<"coupling">().stl_string(),time_steps.get(), *lbm_macro_data_ptr);
if(eov.is_error()){
return eov;
}
diff --git a/examples/one_particle_sedimentation/step.hpp b/examples/one_particle_sedimentation_2d/step.hpp
index 07f51d1..07f51d1 100644
--- a/examples/one_particle_sedimentation/step.hpp
+++ b/examples/one_particle_sedimentation_2d/step.hpp
diff --git a/examples/schaefer_turek_durst_krause_rannbacher/.nix/derivation.nix b/examples/schaefer_turek_durst_krause_rannbacher/.nix/derivation.nix
index 958955f..af24ac5 100644
--- a/examples/schaefer_turek_durst_krause_rannbacher/.nix/derivation.nix
+++ b/examples/schaefer_turek_durst_krause_rannbacher/.nix/derivation.nix
@@ -8,12 +8,11 @@
, version
, adaptive-cpp
, kel
-, particle_coupling ? "fplbm"
}:
let
in stdenv.mkDerivation {
- pname = "${pname}-examples-stdkr_2d_gpu_${particle_coupling}";
+ pname = "${pname}-examples-stdkr_2d_gpu";
inherit version;
src = ./..;