15 using namespace gtsam;
17 static const double tol = 1
e-5;
20 TEST( testPose3Upright, basics ) {
43 actual2(1.0, 2.0, 3.0, 0.1), actual3(4.0,-7.0, 3.0, 0.3);
56 TEST( testPose3Upright, conversions ) {
67 TEST( testPose3Upright, manifold ) {
75 Vector delta12 = (
Vector(4) << 3.0, 0.0, 4.0, 0.0).finished(), delta21 = -delta12;
84 TEST( testPose3Upright, lie ) {
99 Matrix actualH1, actualH2, numericH1, numericH2;
114 Matrix actualH1, actualH2, numericH1, numericH2;
129 Matrix actualH1, numericH1;
Provides additional testing facilities for common data structures.
static Pose3Upright Expmap(const Vector &xi)
Exponential map at identity - create a rotation from canonical coordinates.
size_t dim() const
Dimensionality of tangent space = 4 DOF.
static int runAllTests(TestResult &result)
set noclip points set clip one set noclip two set bar set border lt lw set xdata set ydata set zdata set x2data set y2data set boxwidth set dummy y set format x g set format y g set format x2 g set format y2 g set format z g set angles radians set nogrid set key title set key left top Right noreverse box linetype linewidth samplen spacing width set nolabel set noarrow set nologscale set logscale x set set pointsize set encoding default set nopolar set noparametric set set set set surface set nocontour set clabel set mapping cartesian set nohidden3d set cntrparam order set cntrparam linear set cntrparam levels auto set cntrparam points set size set origin
Pose3Upright inverse_proxy(const Pose3Upright &x1)
Pose3Upright between(const Pose3Upright &p2, boost::optional< Matrix & > H1=boost::none, boost::optional< Matrix & > H2=boost::none) const
Pose3Upright compose(const Pose3Upright &p2, boost::optional< Matrix & > H1=boost::none, boost::optional< Matrix & > H2=boost::none) const
compose this transformation onto another (first *this and then p2)
static Vector Logmap(const Pose3Upright &p)
Log map at identity - return the canonical coordinates of this rotation.
Some functions to compute numerical derivatives.
Pose3 x2(Rot3::Ypr(0.0, 0.0, 0.0), l2)
internal::FixedSizeMatrix< Y, X1 >::type numericalDerivative21(const boost::function< Y(const X1 &, const X2 &)> &h, const X1 &x1, const X2 &x2, double delta=1e-5)
#define EXPECT_DOUBLES_EQUAL(expected, actual, threshold)
Point2 translation2() const
Pose3Upright retract(const Vector &v) const
Class compose(const Class &g) const
static Rot3 Yaw(double t)
Positive yaw is to right (as in aircraft heading). See ypr.
internal::FixedSizeMatrix< Y, X2 >::type numericalDerivative22(boost::function< Y(const X1 &, const X2 &)> h, const X1 &x1, const X2 &x2, double delta=1e-5)
static const Pose3 pose(Rot3(Vector3(1,-1,-1).asDiagonal()), Point3(0, 0, 0.5))
#define EXPECT(condition)
Vector localCoordinates(const Pose3Upright &p2) const
Local 3D coordinates of Pose3Upright manifold neighborhood around current pose.
Array< double, 1, 3 > e(1./3., 0.5, 2.)
Point3 translation() const
Pose3Upright between_proxy(const Pose3Upright &x1, const Pose3Upright &x2)
bool assert_equal(const Matrix &expected, const Matrix &actual, double tol)
Class retract(const TangentVector &v) const
retract as required by manifold concept: applies v at *this
#define EXPECT_LONGS_EQUAL(expected, actual)
Expression< T > compose(const Expression< T > &t1, const Expression< T > &t2)
Class between(const Class &g) const
TEST(LPInitSolver, InfiniteLoopSingleVar)
bool assert_inequal(const Matrix &A, const Matrix &B, double tol)
static Rot2 fromAngle(double theta)
Named constructor from angle in radians.
GTSAM_EXPORT Pose2 inverse() const
inverse
internal::FixedSizeMatrix< Y, X >::type numericalDerivative11(boost::function< Y(const X &)> h, const X &x, double delta=1e-5)
New-style numerical derivatives using manifold_traits.
Pose3Upright inverse(boost::optional< Matrix & > H1=boost::none) const
inverse transformation with derivatives
Expression< T > between(const Expression< T > &t1, const Expression< T > &t2)
EIGEN_DEVICE_FUNC const InverseReturnType inverse() const
Pose3Upright compose_proxy(const Pose3Upright &x1, const Pose3Upright &x2)
TangentVector localCoordinates(const Class &g) const
localCoordinates as required by manifold concept: finds tangent vector between *this and g ...
Variation of a Pose3 in which the rotation is constained to purely yaw This state is essentially a Po...