Reformat Unit3 test
parent
5c4e5a4b23
commit
21163e9bdc
|
|
@ -373,23 +373,19 @@ TEST(Unit3, retract) {
|
|||
|
||||
//*******************************************************************************
|
||||
TEST (Unit3, jacobian_retract) {
|
||||
Matrix22 H;
|
||||
Unit3 p;
|
||||
boost::function<Unit3(const Vector2&)> f =
|
||||
boost::bind(&Unit3::retract, p, _1, boost::none);
|
||||
Matrix22 H;
|
||||
{
|
||||
Vector2 v (-0.2, 0.1);
|
||||
p.retract(v, H);
|
||||
|
||||
// Test that jacobian is numerically as expected.
|
||||
Matrix H_expected_numerical = numericalDerivative11(f, v);
|
||||
EXPECT(assert_equal(H_expected_numerical, H, 1e-9));
|
||||
}
|
||||
{
|
||||
Vector2 v (0, 0);
|
||||
p.retract(v, H);
|
||||
|
||||
// Test that jacobian is numerically as expected.
|
||||
Matrix H_expected_numerical = numericalDerivative11(f, v);
|
||||
EXPECT(assert_equal(H_expected_numerical, H, 1e-9));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue