17 cout << s << (s ==
"" ?
"" :
"\n");
18 cout <<
"LocalOrientedPlane3Factor Factor (" << keyFormatter(
key1()) <<
", " 19 << keyFormatter(
key2()) <<
", " << keyFormatter(
key3()) <<
")\n";
20 measured_p_.print(
"Measured Plane");
21 this->noiseModel_->print(
" noise model: ");
25 Vector LocalOrientedPlane3Factor::evaluateError(
const Pose3& wTwi,
27 boost::optional<Matrix&> H1, boost::optional<Matrix&> H2,
28 boost::optional<Matrix&> H3)
const {
30 Matrix66 aTai_H_wTwa, aTai_H_wTwi;
31 Matrix36 predicted_H_aTai;
32 Matrix33 predicted_H_plane, error_H_predicted;
36 H2 ? &aTai_H_wTwa :
nullptr,
37 H1 ? &aTai_H_wTwi :
nullptr);
41 H2 ? &predicted_H_plane :
nullptr,
42 (H1 || H3) ? &predicted_H_aTai :
nullptr);
46 boost::none, (H1 || H2 || H3) ? &error_H_predicted :
nullptr);
50 *H1 = error_H_predicted * predicted_H_aTai * aTai_H_wTwi;
54 *H2 = error_H_predicted * predicted_H_aTai * aTai_H_wTwa;
58 *H3 = error_H_predicted * predicted_H_plane;
void print(const Matrix &A, const string &s, ostream &stream)
Represents an infinite plane in 3D, which is composed of a planar normal and its perpendicular distan...
const Symbol key1('v', 1)
OrientedPlane3 transform(const Pose3 &xr, OptionalJacobian< 3, 3 > Hp=boost::none, OptionalJacobian< 3, 6 > Hr=boost::none) const
Pose3 transformPoseTo(const Pose3 &wTb, OptionalJacobian< 6, 6 > Hself=boost::none, OptionalJacobian< 6, 6 > HwTb=boost::none) const
std::function< std::string(Key)> KeyFormatter
Typedef for a function to format a key, i.e. to convert it to a string.
Vector3 errorVector(const OrientedPlane3 &other, OptionalJacobian< 3, 3 > H1=boost::none, OptionalJacobian< 3, 3 > H2=boost::none) const
const Symbol key3('v', 3)
const Symbol key2('v', 2)