33 virtual Vector3
omega_b(
double t)
const = 0;
34 virtual Vector3
velocity_n(
double t)
const = 0;
40 NavState navState(
double t)
const {
return NavState(
pose(t),
velocity_n(t)); }
42 Vector3 velocity_b(
double t)
const {
43 const Rot3 nRb = rotation(t);
47 Vector3 acceleration_b(
double t)
const {
48 const Rot3 nRb = rotation(t);
65 : twist_((Vector6() << w, v).finished()), a_b_(w.
cross(v)), nTb0_(nTb0) {}
70 Vector3
omega_b(
double t)
const override {
return twist_.head<3>(); }
72 return rotation(t).
matrix() * twist_.tail<3>();
74 Vector3
acceleration_n(
double t)
const override {
return rotation(t) * a_b_; }
89 const Vector3&
omega_b = Vector3::Zero())
90 : nRb_(nRb), p0_(p0), v0_(v0), a_n_(a_n), omega_b_(
omega_b) {}
93 return Pose3(nRb_.
expmap(omega_b_ * t), p0_ + v0_ * t + a_n_ * t * t / 2.0);
95 Vector3
omega_b(
double t)
const override {
return omega_b_; }
96 Vector3
velocity_n(
double t)
const override {
return v0_ + a_n_ * t; }
101 const Vector3 p0_, v0_, a_n_, omega_b_;
virtual Vector3 velocity_n(double t) const =0
velocity at time t, in nav frame
Vector3 acceleration_n(double t) const override
acceleration in nav frame
Definition: Scenario.h:97
Matrix3 matrix() const
return 3*3 rotation matrix
Definition: Rot3M.cpp:180
virtual Vector3 acceleration_n(double t) const =0
acceleration in nav frame
Scenario with constant twist 3D trajectory.
Definition: Scenario.h:60
ConstantTwistScenario(const Vector3 &w, const Vector3 &v, const Pose3 &nTb0=Pose3())
Construct scenario with constant twist [w,v].
Definition: Scenario.h:63
Point3 cross(const Point3 &p, const Point3 &q, OptionalJacobian< 3, 3 > H1, OptionalJacobian< 3, 3 > H2)
cross product
Definition: Point3.cpp:121
Simple trajectory simulator.
Definition: Scenario.h:25
Vector3 omega_b(double t) const override
angular velocity in body frame
Definition: Scenario.h:95
Vector3 acceleration_n(double t) const override
acceleration in nav frame
Definition: Scenario.h:74
Vector3 velocity_n(double t) const override
velocity at time t, in nav frame
Definition: Scenario.h:96
Accelerating from an arbitrary initial state, with optional rotation.
Definition: Scenario.h:83
Vector3 omega_b(double t) const override
angular velocity in body frame
Definition: Scenario.h:70
Pose3 pose(double t) const override
pose at time t
Definition: Scenario.h:67
Vector3 velocity_n(double t) const override
velocity at time t, in nav frame
Definition: Scenario.h:71
AcceleratingScenario(const Rot3 &nRb, const Point3 &p0, const Vector3 &v0, const Vector3 &a_n, const Vector3 &omega_b=Vector3::Zero())
Construct scenario with constant acceleration in navigation frame and optional angular velocity in bo...
Definition: Scenario.h:87
const Rot3 & rotation(OptionalJacobian< 3, 6 > H=boost::none) const
get rotation
Definition: Pose3.cpp:272
Class expmap(const TangentVector &v) const
expmap as required by manifold concept Applies exponential map to v and composes with *this
Definition: Lie.h:80
Pose3 pose(double t) const override
pose at time t
Definition: Scenario.h:92
Global functions in a separate testing namespace.
Definition: chartTesting.h:28
Navigation state composing of attitude, position, and velocity.
static Pose3 Expmap(const Vector6 &xi, OptionalJacobian< 6, 6 > H=boost::none)
Exponential map at identity - create a rotation from canonical coordinates .
Definition: Pose3.cpp:120
virtual Pose3 pose(double t) const =0
pose at time t
virtual Vector3 omega_b(double t) const =0
angular velocity in body frame
virtual ~Scenario()
virtual destructor
Definition: Scenario.h:28