From c59aeef2e0c86ec3f0f34ce77c205f3ef0b034cc Mon Sep 17 00:00:00 2001 From: "Claudius \"keldu\" Holeksa" Date: Sun, 8 Nov 2026 22:04:06 +0100 Subject: Abstract move. Forstio independence --- modules/core/tests/particles.cpp | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'modules/core/tests/particles.cpp') diff --git a/modules/core/tests/particles.cpp b/modules/core/tests/particles.cpp index e060097..823bcd7 100644 --- a/modules/core/tests/particles.cpp +++ b/modules/core/tests/particles.cpp @@ -12,7 +12,7 @@ using T = Float64; SAW_TEST("Verlet step 2D - Planar"){ using namespace kel; - saw::data> particle; + kel::lbm::data> particle; auto& body = particle.template get<"rigid_body">(); auto& pos = body.template get<"position">(); auto& pos_old = body.template get<"position_old">(); @@ -22,7 +22,7 @@ SAW_TEST("Verlet step 2D - Planar"){ acc.at({{0}}).set({1.0}); - saw::data> dt; + kel::lbm::data> dt; dt.at({}).set(0.5); lbm::verlet_step_lambda(particle,dt); @@ -33,7 +33,7 @@ SAW_TEST("Verlet step 2D - Planar"){ SAW_TEST("No Collision Spheroid 2D"){ using namespace kel; - saw::data> part_a; + kel::lbm::data> part_a; { auto& body = part_a.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -42,7 +42,7 @@ SAW_TEST("No Collision Spheroid 2D"){ pos.at({{1u}}) = 0.2; } - saw::data> part_b; + kel::lbm::data> part_b; { auto& body = part_b.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -59,7 +59,7 @@ SAW_TEST("No Collision Spheroid 2D"){ SAW_TEST("Collision Spheroid 2D"){ using namespace kel; - saw::data> part_a; + kel::lbm::data> part_a; { auto& body = part_a.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -72,7 +72,7 @@ SAW_TEST("Collision Spheroid 2D"){ pos.at({{1u}}) = 0.2; } - saw::data> part_b; + kel::lbm::data> part_b; { auto& body = part_b.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -93,7 +93,7 @@ SAW_TEST("Collision Spheroid 2D"){ SAW_TEST("Moving particles 2D"){ using namespace kel; - saw::data> part_a; + kel::lbm::data> part_a; { auto& body = part_a.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -110,7 +110,7 @@ SAW_TEST("Moving particles 2D"){ acc.at({{0u}}) = 0.1; } - saw::data> part_b; + kel::lbm::data> part_b; { auto& body = part_b.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -127,7 +127,7 @@ SAW_TEST("Moving particles 2D"){ acc.at({{0u}}) = -0.1; } - saw::data> dt; + kel::lbm::data> dt; dt.at({}).set(0.5); bool has_collided = false; for(uint64_t i = 0u; i < 32u; ++i){ @@ -147,7 +147,7 @@ SAW_TEST("Moving particles 2D"){ SAW_TEST("Particle Matrix Rotation"){ using namespace kel; - saw::data> part_a; + kel::lbm::data> part_a; { auto& body = part_a.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -164,7 +164,7 @@ SAW_TEST("Particle Matrix Rotation"){ SAW_TEST("Particle Collision Impulse"){ using namespace kel; - saw::data> part_a; + kel::lbm::data> part_a; { auto& body = part_a.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -181,7 +181,7 @@ SAW_TEST("Particle Collision Impulse"){ acc.at({{0u}}) = 0.1; } - saw::data> part_b; + kel::lbm::data> part_b; { auto& body = part_b.template get<"rigid_body">(); auto& pos = body.template get<"position">(); @@ -210,15 +210,15 @@ SAW_TEST("Minor Test for mask"){ auto& grid = mask.template get<"grid">(); - for(saw::data i{0u}; i < grid.template get_dim_size<0>(); ++i){ - for(saw::data j{0u}; j < grid.template get_dim_size<1>(); ++j){ + for(kel::lbm::data i{0u}; i < grid.template get_dim_size<0>(); ++i){ + for(kel::lbm::data j{0u}; j < grid.template get_dim_size<1>(); ++j){ std::cout<> reference_mask{{{4+2,4+2}}}; + //kel::lbm::data> reference_mask{{{4+2,4+2}}}; //reference_mask.at({{0,0}}); } */ @@ -228,7 +228,7 @@ SAW_TEST("Verlet integration test 2D"){ lbm::particle_system> system; { - saw::data> particle; + kel::lbm::data> particle; auto& rb = particle.template get<"rigid_body">(); auto& acc = rb.template get<"acceleration">(); auto& pos = rb.template get<"position">(); @@ -245,21 +245,21 @@ SAW_TEST("Verlet integration test 2D"){ auto& rb = p.template get<"rigid_body">(); auto& pos = rb.template get<"position">(); - for(saw::data i{0u}; i < saw::data{2u}; ++i){ + for(kel::lbm::data i{0u}; i < kel::lbm::data{2u}; ++i){ std::cout<{1e-1}); + system.step(kel::lbm::data{1e-1}); { auto& p = system.at({0u}); auto& rb = p.template get<"rigid_body">(); auto& pos = rb.template get<"position">(); - for(saw::data i{0u}; i < saw::data{2u}; ++i){ + for(kel::lbm::data i{0u}; i < kel::lbm::data{2u}; ++i){ std::cout<> radi,dense; + kel::lbm::data> radi,dense; radi.at({}) = 2.2f; dense.at({}) = 1.0f; auto spheroid_pgrp = lbm::create_spheroid_particle_group(radi,dense,{8u}); -- cgit v1.3.1