Go to the documentation of this file.
47 return std::static_pointer_cast<gtsam::NonlinearFactor>(
55 if (H1) *H1 = -Matrix::Identity(
p,
p);
56 if (H2) *H2 = Matrix::Identity(
p,
p);
57 if (H3) *H3 = Matrix::Identity(
p,
p)*
h_;
58 return (
Vector(1) << qk+
v*
h_-qk1).finished();
97 return std::static_pointer_cast<gtsam::NonlinearFactor>(
105 if (H1) *H1 = -Matrix::Identity(
p,
p);
106 if (H2) *H2 = Matrix::Identity(
p,
p);
144 double h,
double m = 1.0,
double r = 1.0,
double g = 9.81,
double alpha = 0.0,
double mu = 1000.0)
150 return std::static_pointer_cast<gtsam::NonlinearFactor>(
163 if (H1) *H1 = -Matrix::Identity(
p,
p);
164 if (H2) *H2 = Matrix::Identity(
p,
p)*(-mr2_h + mgrh*(1-
alpha_)*(1-
alpha_)*
cos(qmid));
165 if (H3) *H3 = Matrix::Identity(
p,
p)*( mr2_h + mgrh*(1-
alpha_)*(
alpha_)*
cos(qmid));
167 return (
Vector(1) << mr2_h * (qk1 - qk) + mgrh * (1 -
alpha_) *
sin(qmid) - pk).finished();
202 double h,
double m = 1.0,
double r = 1.0,
double g = 9.81,
double alpha = 0.0,
double mu = 1000.0)
208 return std::static_pointer_cast<gtsam::NonlinearFactor>(
221 if (H1) *H1 = -Matrix::Identity(
p,
p);
225 return (
Vector(1) << mr2_h * (qk1 - qk) - mgrh *
alpha_ *
sin(qmid) - pk1).finished();
NoiseModelFactorN< double, double, double > Base
gtsam::NonlinearFactor::shared_ptr clone() const override
std::shared_ptr< This > shared_ptr
Jet< T, N > sin(const Jet< T, N > &f)
virtual Vector evaluateError(const ValueTypes &... x, OptionalMatrixTypeT< ValueTypes >... H) const=0
gtsam::NonlinearFactor::shared_ptr clone() const override
PendulumFactorPk(Key pKey, Key qKey, Key qKey1, double h, double m=1.0, double r=1.0, double g=9.81, double alpha=0.0, double mu=1000.0)
Constructor.
gtsam::NonlinearFactor::shared_ptr clone() const override
Vector evaluateError(const double &pk, const double &qk, const double &qk1, OptionalMatrixType H1, OptionalMatrixType H2, OptionalMatrixType H3) const override
PendulumFactor2(Key vk1, Key vk, Key qkey, double h, double r=1.0, double g=9.81, double mu=1000.0)
Constructor. vk1: v_{k+1}, vk: v_k, qkey: q's key depending on the chosen method, h: time step.
NoiseModelFactorN< double, double, double > Base
PendulumFactor1(Key k1, Key k, Key velKey, double h, double mu=1000.0)
Constructor. k1: q_{k+1}, k: q_k, velKey: velocity variable depending on the chosen method,...
Jet< T, N > cos(const Jet< T, N > &f)
std::shared_ptr< PendulumFactor2 > shared_ptr
EIGEN_DEVICE_FUNC const Scalar & q
const SharedNoiseModel & noiseModel() const
access to the noise model
std::shared_ptr< PendulumFactor1 > shared_ptr
Vector evaluateError(const double &qk1, const double &qk, const double &v, OptionalMatrixType H1, OptionalMatrixType H2, OptionalMatrixType H3) const override
PendulumFactorPk1(Key pKey1, Key qKey, Key qKey1, double h, double m=1.0, double r=1.0, double g=9.81, double alpha=0.0, double mu=1000.0)
Constructor.
std::shared_ptr< PendulumFactorPk > shared_ptr
std::shared_ptr< PendulumFactorPk1 > shared_ptr
void g(const string &key, int i)
Non-linear factor base classes.
gtsam::NonlinearFactor::shared_ptr clone() const override
NoiseModelFactorN< double, double, double > Base
Vector evaluateError(const double &pk1, const double &qk, const double &qk1, OptionalMatrixType H1, OptionalMatrixType H2, OptionalMatrixType H3) const override
Array< int, Dynamic, 1 > v
Matrix * OptionalMatrixType
Vector evaluateError(const double &vk1, const double &vk, const double &q, OptionalMatrixType H1, OptionalMatrixType H2, OptionalMatrixType H3) const override
NoiseModelFactorN< double, double, double > Base
std::uint64_t Key
Integer nonlinear key type.
gtsam
Author(s):
autogenerated on Sun Dec 22 2024 04:12:42