|
A sparse MPC solver for walking motion generation (old version).
|
API of the sparse MPC solver. More...
#include <smpc_solver.h>
Public Member Functions | |
| solver (const int N, const double Alpha=150.0, const double Beta=2000.0, const double Gamma=1.0, const double regularization=0.01, const double tol=1e-7) | |
| Constructor: initialize an active set method solver. | |
| solver (const int N, const int max_iter, const double Alpha=150.0, const double Beta=2000.0, const double Gamma=1.0, const double regularization=0.01, const double tol=1e-3, const double tol_out=1e-2, const double t=100, const double mu=15, const double bs_alpha=0.01, const double bs_beta=0.5) | |
| Constructor: initialize an interior-point method solver. | |
| ~solver () | |
| void | enable_fexceptions () |
| Enable floating point exceptions: die rather than processing incorrect data). SIGFPE is sent to the program, when an error occurs. | |
| void | set_parameters (const double *T, const double *h, const double h_initial, const double *angle, const double *zref_x, const double *zref_y, const double *lb, const double *ub) |
| Initializes quadratic problem. | |
| void | form_init_fp (const double *x_coord, const double *y_coord, const state_orig &init_state, double *X) |
| Generates an initial feasible point. | |
| int | solve () |
| Solve QP problem. | |
Public Attributes | |
| qp_solver * | qp_sol |
| Internal representation. | |
API of the sparse MPC solver.
Definition at line 243 of file smpc_solver.h.
| smpc::solver::solver | ( | const int | N, |
| const double | Alpha = 150.0, |
||
| const double | Beta = 2000.0, |
||
| const double | Gamma = 1.0, |
||
| const double | regularization = 0.01, |
||
| const double | tol = 1e-7 |
||
| ) |
Constructor: initialize an active set method solver.
| [in] | N | Number of sampling times in a preview window |
| [in] | Alpha | Velocity gain |
| [in] | Beta | Position gain |
| [in] | Gamma | Jerk gain |
| [in] | regularization | regularization |
| [in] | tol | tolerance |
Definition at line 34 of file smpc_solver.cpp.
| smpc::solver::solver | ( | const int | N, |
| const int | max_iter, | ||
| const double | Alpha = 150.0, |
||
| const double | Beta = 2000.0, |
||
| const double | Gamma = 1.0, |
||
| const double | regularization = 0.01, |
||
| const double | tol = 1e-3, |
||
| const double | tol_out = 1e-2, |
||
| const double | t = 100, |
||
| const double | mu = 15, |
||
| const double | bs_alpha = 0.01, |
||
| const double | bs_beta = 0.5 |
||
| ) |
Constructor: initialize an interior-point method solver.
| [in] | N | Number of sampling times in a preview window |
| [in] | max_iter | maximum number of internal loop iterations |
| [in] | Alpha | Velocity gain |
| [in] | Beta | Position gain |
| [in] | Gamma | Jerk gain |
| [in] | regularization | regularization |
| [in] | tol | tolerance (internal loop) |
| [in] | tol_out | tolerance of the outer loop, which resolves the problem with new t (kappa) parameter. |
| [in] | t | logarithmic barrier parameter |
| [in] | mu | multiplier of t, >1. |
| [in] | bs_alpha | backtracking search parameter 0 < alpha < 0.5 |
| [in] | bs_beta | backtracking search parameter 0 < beta < 1 |
Definition at line 43 of file smpc_solver.cpp.
Definition at line 59 of file smpc_solver.cpp.
| void smpc::solver::enable_fexceptions | ( | ) |
Enable floating point exceptions: die rather than processing incorrect data). SIGFPE is sent to the program, when an error occurs.
Definition at line 68 of file smpc_solver.cpp.
| void smpc::solver::form_init_fp | ( | const double * | x_coord, |
| const double * | y_coord, | ||
| const state_orig & | init_state, | ||
| double * | X | ||
| ) |
Generates an initial feasible point.
| [in] | x_coord | x coordinates of points satisfying constraints |
| [in] | y_coord | y coordinates of points satisfying constraints |
| [in] | init_state | initial state |
| [in,out] | X | solution of optimization problem |
Definition at line 93 of file smpc_solver.cpp.
| void smpc::solver::set_parameters | ( | const double * | T, |
| const double * | h, | ||
| const double | h_initial, | ||
| const double * | angle, | ||
| const double * | zref_x, | ||
| const double * | zref_y, | ||
| const double * | lb, | ||
| const double * | ub | ||
| ) |
Initializes quadratic problem.
| [in] | T | sampling time for each time step [sec.] |
| [in] | h | height of the center of mass divided by gravity for each time step |
| [in] | h_initial | initial value of height of the center of mass divided by gravity |
| [in] | angle | rotation angle for each state relative to the world frame |
| [in] | zref_x | reference values of x coordinate of ZMP |
| [in] | zref_y | reference values of y coordinate of ZMP |
| [in] | lb | array of lower bounds for coordinates of ZMP |
| [in] | ub | array of upper bounds for coordinates of ZMP |
Definition at line 79 of file smpc_solver.cpp.
| int smpc::solver::solve | ( | ) |
Solve QP problem.
Definition at line 107 of file smpc_solver.cpp.
Internal representation.
Definition at line 367 of file smpc_solver.h.
1.8.0