4#include <eigenpy/std-array.hpp>
10using lqr_t = LQRProblemTpl<context::Scalar>;
15 auto &[xs, us, vs, lbdas] = ss;
27 +[](
const lqr_t &problem, Scalar mudyn, Scalar mueq) {
29 return bp::make_tuple(std::get<0>(mat_rhs), std::get<1>(mat_rhs));
31 (
"problem"_a,
"mudyn",
"mueq"));
34 (
"problem"_a,
"mudyn",
"mueq",
"mat",
"rhs",
"update"),
35 "Create or update a sparse matrix from an LQRProblem.");
40 (
"problem"_a,
"xs",
"us",
"vs",
"lbdas",
"mudyn",
"mueq",
"theta",
42 "Compute the KKT residual of the LQR problem.");
auto lqrInitializeSolution(const LQRProblemTpl< Scalar > &problem)
bool lqrDenseMatrix(const LQRProblemTpl< Scalar > &problem, Scalar mudyn, Scalar mueq, typename math_types< Scalar >::MatrixXs &mat, typename math_types< Scalar >::VectorXs &rhs)
Fill in a KKT constraint matrix and vector for the given LQ problem with the given dual-regularizatio...
void lqrCreateSparseMatrix(const LQRProblemTpl< Scalar > &problem, const Scalar mudyn, const Scalar mueq, Eigen::SparseMatrix< Scalar > &mat, Eigen::Matrix< Scalar, -1, 1 > &rhs, bool update)
std::array< Scalar, 3 > lqrComputeKktError(const LQRProblemTpl< Scalar > &problem, boost::span< const typename math_types< Scalar >::VectorXs > xs, boost::span< const typename math_types< Scalar >::VectorXs > us, boost::span< const typename math_types< Scalar >::VectorXs > vs, boost::span< const typename math_types< Scalar >::VectorXs > lbdas, const Scalar mudyn, const Scalar mueq, const std::optional< typename math_types< Scalar >::ConstVectorRef > &theta_, bool verbose=false)
bp::dict lqr_sol_initialize_wrap(const lqr_t &problem)
LQRProblemTpl< context::Scalar > lqr_t