diff options
Diffstat (limited to 'tests/particles.cpp')
-rw-r--r-- | tests/particles.cpp | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/tests/particles.cpp b/tests/particles.cpp new file mode 100644 index 0000000..6332195 --- /dev/null +++ b/tests/particles.cpp @@ -0,0 +1,34 @@ +#include <forstio/test/suite.hpp> + +#include <iostream> +#include "../c++/particle/geometry/circle.hpp" + + +namespace { +namespace sch { +using namespace kel::lbm::sch; + +using T = Float64; +} + +SAW_TEST("Minor Test for mask"){ + using namespace kel; + + lbm::particle_circle_geometry<sch::T> geo; + + auto mask = geo.generate_mask<sch::T>(4,2); + + auto& grid = mask.template get<"grid">(); + + for(saw::data<sch::UInt64> i{0u}; i < grid.template get_dim_size<0>(); ++i){ + for(saw::data<sch::UInt64> j{0u}; j < grid.template get_dim_size<1>(); ++j){ + std::cout<<grid.at({{i,j}}).get()<<" "; + } + std::cout<<"\n"; + } + std::cout<<std::endl; + + //saw::data<sch::Array<sch::T,2>> reference_mask{{{4+2,4+2}}}; + //reference_mask.at({{0,0}}); +} +} |