Skip to content

Commit

Permalink
non-zero starting point
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Voigt authored and Alexander Voigt committed Jul 11, 2015
1 parent 735e1d5 commit 7fa8d58
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/test_root_solver.cpp
Expand Up @@ -63,7 +63,10 @@ class Parabola_constraint : public Constraint<Root> {

BOOST_AUTO_TEST_CASE( test_parabola_2dim )
{
Eigen::Array2d x_init;
x_init << 10., 10.;
Static_model model;
model.set_parameters(x_init);
Parabola_convergence_tester ct;
Parabola_constraint constraint;

Expand All @@ -80,6 +83,6 @@ BOOST_AUTO_TEST_CASE( test_parabola_2dim )
BOOST_FAIL("Error: " << e.what());
}

BOOST_CHECK_CLOSE_FRACTION(model.get_parameters()(0), 5., 1e-10);
BOOST_CHECK_CLOSE_FRACTION(model.get_parameters()(1), 1., 1e-10);
BOOST_CHECK_CLOSE_FRACTION(model.get_parameters()(0), 5., 1e-5);
BOOST_CHECK_CLOSE_FRACTION(model.get_parameters()(1), 1., 1e-5);
}

0 comments on commit 7fa8d58

Please sign in to comment.