Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
polympc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Petr Listov
polympc
Commits
bab5321f
Commit
bab5321f
authored
3 years ago
by
Petr Listov
Browse files
Options
Downloads
Patches
Plain Diff
typos fix in ocp chapter
parent
0c58022a
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
docs/source/ocp.rst
+7
-7
7 additions, 7 deletions
docs/source/ocp.rst
with
7 additions
and
7 deletions
docs/source/ocp.rst
+
7
−
7
View file @
bab5321f
...
@@ -236,12 +236,12 @@ using *PolyMPC*.
...
@@ -236,12 +236,12 @@ using *PolyMPC*.
/** initialise weight matrices to identity (for example)*/
/** initialise weight matrices to identity (for example)*/
Q.setIdentity();
Q.setIdentity();
R.setIdentity();
R.setIdentity();
QN.setIdentity;
QN.setIdentity
()
;
}
}
Matrix<scalar_t, 3, 3> Q;
Matrix<scalar_t, 3, 3> Q;
Matrix<scalar_t, 2, 2> R;
Matrix<scalar_t, 2, 2> R;
Eigen::Diagonal
Matrix<scalar_t, 3> QN
{1,1,1}
;
Matrix<scalar_t,
3,
3> QN;
template<typename T>
template<typename T>
inline void dynamics_impl(const Ref<const state_t<T>> x, const Ref<const control_t<T>> u,
inline void dynamics_impl(const Ref<const state_t<T>> x, const Ref<const control_t<T>> u,
...
@@ -330,12 +330,12 @@ Let's now move on to defining the dynamics functions.
...
@@ -330,12 +330,12 @@ Let's now move on to defining the dynamics functions.
/** initialise weight matrices to identity (for example)*/
/** initialise weight matrices to identity (for example)*/
Q.setIdentity();
Q.setIdentity();
R.setIdentity();
R.setIdentity();
QN.setIdentity;
QN.setIdentity
()
;
}
}
Matrix<scalar_t, 3, 3> Q;
Matrix<scalar_t, 3, 3> Q;
Matrix<scalar_t, 2, 2> R;
Matrix<scalar_t, 2, 2> R;
Eigen::Diagonal
Matrix<scalar_t, 3> QN
{1,1,1}
;
Matrix<scalar_t,
3,
3> QN;
template<typename T>
template<typename T>
inline void dynamics_impl(const Ref<const state_t<T>> x, const Ref<const control_t<T>> u,
inline void dynamics_impl(const Ref<const state_t<T>> x, const Ref<const control_t<T>> u,
...
@@ -442,8 +442,8 @@ this problem as described in :ref:`chapter-nlp` chapter. We create a nonlinear s
...
@@ -442,8 +442,8 @@ this problem as described in :ref:`chapter-nlp` chapter. We create a nonlinear s
using box_admm_solver = boxADMM<RobotOCP::VAR_SIZE, RobotOCP::NUM_EQ, RobotOCP::scalar_t,
using box_admm_solver = boxADMM<RobotOCP::VAR_SIZE, RobotOCP::NUM_EQ, RobotOCP::scalar_t,
RobotOCP::MATRIXFMT, linear_solver_traits<RobotOCP::MATRIXFMT>::default_solver>;
RobotOCP::MATRIXFMT, linear_solver_traits<RobotOCP::MATRIXFMT>::default_solver>;
using preconditioner_t =
polympc::
RuizEquilibration<RobotOCP::scalar_t, RobotOCP::VAR_SIZE,
using preconditioner_t = RuizEquilibration<RobotOCP::scalar_t, RobotOCP::VAR_SIZE,
RobotOCP::NUM_EQ, RobotOCP::MATRIXFMT>;
RobotOCP::NUM_EQ, RobotOCP::MATRIXFMT>;
int main(void)
int main(void)
{
{
...
@@ -505,7 +505,7 @@ Here is how our particular example will look like with the MPC wrapper:
...
@@ -505,7 +505,7 @@ Here is how our particular example will look like with the MPC wrapper:
int main(void)
int main(void)
{
{
/** create an MPC algorithm and set the prediction horison */
/** create an MPC algorithm and set the prediction horison */
using mpc_t = MPC<RobotOCP,
My
Solver, box_admm_solver>;
using mpc_t = MPC<RobotOCP, Solver, box_admm_solver>;
mpc_t mpc;
mpc_t mpc;
mpc.settings().max_iter = 20;
mpc.settings().max_iter = 20;
mpc.settings().line_search_max_iter = 10;
mpc.settings().line_search_max_iter = 10;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment