Base class for an attitude factor that constrains the rotation between body and navigation frames. More...
#include <AttitudeFactor.h>
Public Member Functions | |
Vector | attitudeError (const Rot3 &p, OptionalJacobian< 2, 3 > H={}) const |
AttitudeFactor () | |
AttitudeFactor (const Unit3 &nRef, const Unit3 &bMeasured=Unit3(0, 0, 1)) | |
Constructor. More... | |
const Unit3 & | bMeasured () const |
const Unit3 & | nRef () const |
Protected Attributes | |
Unit3 | bMeasured_ |
Position measurement in. More... | |
Unit3 | nRef_ |
Base class for an attitude factor that constrains the rotation between body and navigation frames.
This factor enforces that when the measured direction in the body frame (e.g., from an IMU accelerometer) is rotated into the navigation frame using the rotation variable, it should align with a known reference direction in the navigation frame (e.g., gravity vector).
Mathematically, the error is zero when: nRb * bMeasured == nRef
This is useful for incorporating absolute orientation measurements into the factor graph.
Definition at line 45 of file AttitudeFactor.h.
|
inline |
default constructor - only use for serialization
Definition at line 51 of file AttitudeFactor.h.
|
inline |
Constructor.
nRef | Reference direction in the navigation frame (e.g., gravity). |
bMeasured | Measured direction in the body frame (e.g., from IMU accelerometer). Default is Unit3(0, 0, 1). |
Definition at line 59 of file AttitudeFactor.h.
Vector gtsam::AttitudeFactor::attitudeError | ( | const Rot3 & | p, |
OptionalJacobian< 2, 3 > | H = {} |
||
) | const |
vector of errors
Definition at line 26 of file AttitudeFactor.cpp.
|
inline |
Definition at line 66 of file AttitudeFactor.h.
|
inline |
Definition at line 65 of file AttitudeFactor.h.
|
protected |
Position measurement in.
Definition at line 47 of file AttitudeFactor.h.
|
protected |
Definition at line 47 of file AttitudeFactor.h.