Skip to content
Snippets Groups Projects
Commit b2ae861c authored by Pietro Incardona's avatar Pietro Incardona
Browse files

Fixing a broken test

parent 47699aa1
No related branches found
No related tags found
No related merge requests found
Pipeline #2142 passed
......@@ -28,7 +28,7 @@ void Test3D_extended_grid(const Box<3,float> & domain, long int k)
float factor = pow(create_vcluster().getProcessingUnits()/2.0f,1.0f/3.0f);
// This test in order to work must have at least one ghost
for ( ; (0.01 / factor) > (domain.getHigh(0) - domain.getLow(0) / k) ; k-= (k > 2*big_step)?big_step:small_step )
for ( ; (0.01 / factor) > ((domain.getHigh(0) - domain.getLow(0)) / k) ; k-= (k > 2*big_step)?big_step:small_step )
{
BOOST_TEST_CHECKPOINT( "Testing 3D extended grid k=" << k );
......
......@@ -226,17 +226,6 @@ BOOST_AUTO_TEST_CASE( sgrid_dist_id_basic_test_2D)
4.0*sg.template get<0>(key);
good &= (lap == 4.0);
if (good == false)
{
int debug = 0;
std::cout << sg.template get<0>(key.move(x,1)) << " " << sg.template get<0>(key.move(x,-1)) << " " <<
sg.template get<0>(key.move(y,1))<< " " << sg.template get<0>(key.move(y,-1)) << " " <<
4.0*sg.template get<0>(key) << std::endl;
debug++;
}
}
++it4;
......@@ -501,17 +490,6 @@ BOOST_AUTO_TEST_CASE( sparse_grid_fast_stencil_vectorized_simplified_conv2)
- deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * F * (grid.get<U>(Cp) - 1.0) - grid.get<U_next>(Cp)) > 0.000000001 )
{
std::cout << "U: " << grid.get<U>(Cp) + uFactor * (
grid.get<U>(mz) +
grid.get<U>(pz) +
grid.get<U>(my) +
grid.get<U>(py) +
grid.get<U>(mx) +
grid.get<U>(px) -
6.0*grid.get<U>(Cp)) +
- deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * F * (grid.get<U>(Cp) - 1.0) << " != " << grid.get<U_next>(Cp) << " " << Cp.to_string() << std::endl;
match = false;
break;
}
......@@ -528,16 +506,6 @@ BOOST_AUTO_TEST_CASE( sparse_grid_fast_stencil_vectorized_simplified_conv2)
deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * (F+K) * grid.get<V>(Cp) - grid.get<V_next>(Cp)) > 0.000000001 )
{
std::cout << "V: " << grid.get<V>(Cp) + vFactor * (
grid.get<V>(mz) +
grid.get<V>(pz) +
grid.get<V>(my) +
grid.get<V>(py) +
grid.get<V>(mx) +
grid.get<V>(px) -
6*grid.get<V>(Cp)) +
deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * (F+K) * grid.get<V>(Cp) << "!= " << grid.get<V_next>(Cp) << " " << Cp.to_string() << std::endl;
match = false;
break;
}
......@@ -698,16 +666,6 @@ BOOST_AUTO_TEST_CASE( sparse_grid_fast_stencil_vectorized_simplified_conv2_cross
- deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * F * (grid.get<U>(Cp) - 1.0) - grid.get<U_next>(Cp)) > 0.000000001 )
{
std::cout << "U: " << grid.get<U>(Cp) + uFactor * (
grid.get<U>(mz) +
grid.get<U>(pz) +
grid.get<U>(my) +
grid.get<U>(py) +
grid.get<U>(mx) +
grid.get<U>(px) -
6.0*grid.get<U>(Cp)) +
- deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * F * (grid.get<U>(Cp) - 1.0) << " != " << grid.get<U_next>(Cp) << " " << Cp.to_string() << std::endl;
match = false;
break;
}
......@@ -724,17 +682,6 @@ BOOST_AUTO_TEST_CASE( sparse_grid_fast_stencil_vectorized_simplified_conv2_cross
deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * (F+K) * grid.get<V>(Cp) - grid.get<V_next>(Cp)) > 0.000000001 )
{
std::cout << "V: " << grid.get<V>(Cp) + vFactor * (
grid.get<V>(mz) +
grid.get<V>(pz) +
grid.get<V>(my) +
grid.get<V>(py) +
grid.get<V>(mx) +
grid.get<V>(px) -
6*grid.get<V>(Cp)) +
deltaT * grid.get<U>(Cp) * grid.get<V>(Cp) * grid.get<V>(Cp) +
- deltaT * (F+K) * grid.get<V>(Cp) << " != " << grid.get<V_next>(Cp) << " key: " << Cp.to_string() << std::endl;
match = false;
break;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment