1#ifndef ROBOTOC_SPLIT_CONSTRAINTED_RICCATI_FACTORIZATION_HXX_
2#define ROBOTOC_SPLIT_CONSTRAINTED_RICCATI_FACTORIZATION_HXX_
12 : Ginv(Eigen::MatrixXd::
Zero(robot.dimu(), robot.dimu())),
13 DtM(Eigen::MatrixXd::
Zero(robot.dimu(), robot.dimu())),
14 KtDtM(Eigen::MatrixXd::
Zero(2*robot.dimv(), 2*robot.dimv())),
15 DGinv_full_(Eigen::MatrixXd::
Zero(robot.max_dimf(), robot.dimu())),
16 S_full_(Eigen::MatrixXd::
Zero(robot.max_dimf(), robot.max_dimf())),
17 Sinv_full_(Eigen::MatrixXd::
Zero(robot.max_dimf(), robot.max_dimf())),
18 SinvDGinv_full_(Eigen::MatrixXd::
Zero(robot.max_dimf(), robot.dimu())),
20 dimx_(2*robot.dimv()),
58inline Eigen::Block<Eigen::MatrixXd>
60 return DGinv_full_.topLeftCorner(dims_, dimu_);
64inline const Eigen::Block<const Eigen::MatrixXd>
66 return DGinv_full_.topLeftCorner(dims_, dimu_);
70inline Eigen::Block<Eigen::MatrixXd>
72 return S_full_.topLeftCorner(dims_, dims_);
76inline const Eigen::Block<const Eigen::MatrixXd>
78 return S_full_.topLeftCorner(dims_, dims_);
82inline Eigen::Block<Eigen::MatrixXd>
84 return Sinv_full_.topLeftCorner(dims_, dims_);
88inline const Eigen::Block<const Eigen::MatrixXd>
90 return Sinv_full_.topLeftCorner(dims_, dims_);
94inline Eigen::Block<Eigen::MatrixXd>
96 return SinvDGinv_full_.topLeftCorner(dims_, dimu_);
100inline const Eigen::Block<const Eigen::MatrixXd>
102 return SinvDGinv_full_.topLeftCorner(dims_, dimu_);
108 if (
dims() != other.
dims())
return false;
113 if (!
Ginv.isApprox(other.
Ginv))
return false;
114 if (!
DtM.isApprox(other.
DtM))
return false;
115 if (!
KtDtM.isApprox(other.
KtDtM))
return false;
125 if (
Ginv.hasNaN())
return true;
126 if (
DtM.hasNaN())
return true;
127 if (
KtDtM.hasNaN())
return true;
Dynamics and kinematics model of robots. Wraps pinocchio::Model and pinocchio::Data....
Definition: robot.hpp:32
Riccati factorization matrix and vector for the switching constraint.
Definition: split_constrained_riccati_factorization.hpp:17
Eigen::Block< Eigen::MatrixXd > SinvDGinv()
Definition: split_constrained_riccati_factorization.hxx:95
SplitConstrainedRiccatiFactorization()
Default constructor.
Definition: split_constrained_riccati_factorization.hxx:27
Eigen::Block< Eigen::MatrixXd > S()
Definition: split_constrained_riccati_factorization.hxx:71
void setConstraintDimension(const int dimi=0)
Definition: split_constrained_riccati_factorization.hxx:47
Eigen::Block< Eigen::MatrixXd > Sinv()
Definition: split_constrained_riccati_factorization.hxx:83
Eigen::MatrixXd KtDtM
Definition: split_constrained_riccati_factorization.hpp:84
~SplitConstrainedRiccatiFactorization()
Destructor.
Definition: split_constrained_riccati_factorization.hxx:43
bool hasNaN() const
Definition: split_constrained_riccati_factorization.hxx:120
int dims() const
Definition: split_constrained_riccati_factorization.hxx:53
Eigen::MatrixXd DtM
Definition: split_constrained_riccati_factorization.hpp:82
bool isApprox(const SplitConstrainedRiccatiFactorization &other) const
Definition: split_constrained_riccati_factorization.hxx:106
Eigen::MatrixXd Ginv
Definition: split_constrained_riccati_factorization.hpp:80
Eigen::Block< Eigen::MatrixXd > DGinv()
Definition: split_constrained_riccati_factorization.hxx:59
Definition: constraint_component_base.hpp:17