Commit 76b26a9b authored by incardon's avatar incardon

Testing on taurus

parent 228d67f6
......@@ -117,6 +117,42 @@ void Test2D(const Box<2,float> & domain, long int k)
bool val = g_dist.getDecomposition().check_consistency();
BOOST_REQUIRE_EQUAL(val,true);
/////////////// DEBUG /////////////////////
// get the decomposition
auto & dec = g_dist.getDecomposition();
Vcluster & v_cl = *global_v_cluster;
// check the consistency of the decomposition
val = dec.check_consistency();
BOOST_REQUIRE_EQUAL(val,true);
// for each local volume
// Get the number of local grid needed
size_t n_grid = dec.getNLocalHyperCube();
size_t vol = 0;
// Allocate the grids
for (size_t i = 0 ; i < n_grid ; i++)
{
// Get the local hyper-cube
SpaceBox<2,float> sub = dec.getLocalHyperCube(i);
Box<2,size_t> g_box = g_dist.getCellDecomposer().convertDomainSpaceIntoGridUnits(sub);
vol += g_box.getVolumeKey();
}
v_cl.reduce(vol);
v_cl.execute();
BOOST_REQUIRE_EQUAL(vol,k*k);
/////////////////////////////////////
// Grid sm
grid_sm<2,void> info(sz);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment