25 using namespace gtsam;
44 Q q1(5
e-06, 0, 0, 1),
q2(-5
e-06, 0, 0, -1);
112 EXPECT(check_group_invariants(
id,
id));
113 EXPECT(check_group_invariants(
id, R1));
114 EXPECT(check_group_invariants(R2,
id));
115 EXPECT(check_group_invariants(R2, R1));
117 EXPECT(check_manifold_invariants(
id,
id));
118 EXPECT(check_manifold_invariants(
id, R1));
119 EXPECT(check_manifold_invariants(R2,
id));
120 EXPECT(check_manifold_invariants(R2, R1));
static int runAllTests(TestResult &result)
Q id(Eigen::AngleAxisd(0, Q_z_axis))
BOOST_CONCEPT_ASSERT((boost::RandomAccessRangeConcept< ListOfOneContainer< int > >))
Some functions to compute numerical derivatives.
EIGEN_DEVICE_FUNC Quaternion< Scalar > inverse() const
#define CHECK_LIE_GROUP_DERIVATIVES(t1, t2)
EIGEN_DEVICE_FUNC bool isApprox(const QuaternionBase< OtherDerived > &other, const RealScalar &prec=NumTraits< Scalar >::dummy_precision()) const
#define EXPECT(condition)
BetweenFactor< Rot3 > Between
Array< double, 1, 3 > e(1./3., 0.5, 2.)
traits< Q >::ChartJacobian QuaternionJacobian
EIGEN_DEVICE_FUNC const Scalar & q
Q R1(Eigen::AngleAxisd(1, Q_z_axis))
TEST(Quaternion, Concept)
bool assert_equal(const Matrix &expected, const Matrix &actual, double tol)
Vector3 Q_z_axis(0, 0, 1)
The quaternion class used to represent 3D orientations and rotations.
#define CHECK_CHART_DERIVATIVES(t1, t2)
Q R2(Eigen::AngleAxisd(2, Vector3(0, 1, 0)))
Represents a 3D rotation as a rotation angle around an arbitrary 3D axis.