@@ -96,8 +96,8 @@ BOOST_AUTO_TEST_CASE(KinodynamicsID_contact)
9696 Eigen::VectorXd tau = Eigen::VectorXd::Zero (model_handler.getModel ().nv - 6 );
9797
9898 // Let the robot stabilize
99- const int N_STEP_ON_GROUND = 10000 ;
100- const int N_STEP_FREE_FALL = 1000 ;
99+ const int N_STEP_ON_GROUND = 6000 ;
100+ const int N_STEP_FREE_FALL = 2000 ;
101101 for (int i = 0 ; i < N_STEP_ON_GROUND + N_STEP_FREE_FALL; i++)
102102 {
103103 // Solve and get solution
@@ -108,12 +108,11 @@ BOOST_AUTO_TEST_CASE(KinodynamicsID_contact)
108108 t += dt;
109109 q = pinocchio::integrate (model_handler.getModel (), q, (v + a / 2 . * dt) * dt);
110110 v += a * dt;
111-
112111 if (i == N_STEP_ON_GROUND)
113112 {
114113 // Robot had time to reach permanent regime, is it stable on ground ?
115- BOOST_CHECK_SMALL (a.head (3 ).norm (), 1e-8 );
116- BOOST_CHECK_SMALL (v.head (3 ).norm (), 1e-8 );
114+ BOOST_CHECK_SMALL (a.head (3 ).norm (), 1e-4 );
115+ BOOST_CHECK_SMALL (v.head (3 ).norm (), 1e-4 );
117116
118117 // Remove contacts
119118 solver.setTarget (
@@ -123,7 +122,7 @@ BOOST_AUTO_TEST_CASE(KinodynamicsID_contact)
123122 if (i == N_STEP_ON_GROUND + N_STEP_FREE_FALL - 1 )
124123 {
125124 // Robot had time to reach permanent regime, is it robot free falling ?
126- BOOST_CHECK_SMALL (( a.head (3 ) - model_handler.getModel ().gravity .linear ()) .norm (), 0.1 );
125+ BOOST_CHECK_SMALL (a.head (3 ). norm () - model_handler.getModel ().gravity .linear ().norm (), 0.01 );
127126 }
128127 }
129128}
0 commit comments