Commit 9ef4677a authored by Rohan Budhiraja's avatar Rohan Budhiraja
Browse files

fix dintegratetransport unittest

parent 081025b0
......@@ -276,17 +276,16 @@ BOOST_AUTO_TEST_CASE ( dIntegrate_assignementop_test )
//Transport
std::vector<Eigen::MatrixXd> J(3,Eigen::MatrixXd::Zero(model.nv,2*model.nv));
J[1] = Eigen::MatrixXd::Random(model.nv, 2*model.nv);
J[2] = J[1];
dIntegrate(model,qs,vs,J[0],ARG0,SETTO);
dIntegrateTransport(model,qs,vs,J[2],J[1],ARG0);
BOOST_CHECK(results[1].isApprox(J[0] * J[2]));
results[0].setZero();
dIntegrate(model,qs,vs,results[0],ARG0,SETTO);
dIntegrateTransport(model,qs,vs,J[1],J[2],ARG0);
BOOST_CHECK(J[2].isApprox(results[0] * J[1]));
J[1] = Eigen::MatrixXd::Random(model.nv, 2*model.nv);
J[2] = J[1];
J[0].setZero();
dIntegrate(model,qs,vs,J[0],ARG1,SETTO);
dIntegrateTransport(model,qs,vs,J[2],J[1],ARG1);
BOOST_CHECK(results[1].isApprox(J[0] * J[2]));
results[0].setZero();
dIntegrate(model,qs,vs,results[0],ARG1,SETTO);
dIntegrateTransport(model,qs,vs,J[1],J[2],ARG1);
BOOST_CHECK(J[2].isApprox(results[0] * J[1]));
}
BOOST_AUTO_TEST_CASE ( integrate_difference_test )
......
Supports Markdown
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