Abstract class providing common interface functions.
More...
#include <smpc_solver.h>
|
virtual | ~solver ()=0 |
| Virtual destructor. More...
|
|
virtual 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)=0 |
| Initializes quadratic problem. More...
|
|
virtual void | solve ()=0 |
| Solve QP problem. More...
|
|
virtual void | get_first_controls (control &c) const =0 |
| Returns the controls that must be applied to reach the next state. More...
|
|
virtual void | get_controls (control &c, const int ind) const =0 |
| The same as get_first_controls, but takes an additional parameter - the index of the control inputs. Control[ind] is applied to State[ind-1] to reach State[ind]. More...
|
|
|
virtual void | form_init_fp (const double *x_coord, const double *y_coord, const state_com &init_state, double *X)=0 |
| Generates an initial feasible point. More...
|
|
virtual void | form_init_fp (const double *x_coord, const double *y_coord, const state_zmp &init_state, double *X)=0 |
| Generates an initial feasible point. More...
|
|
|
virtual void | get_next_state (state_com &s) const =0 |
| Returns the next state. More...
|
|
virtual void | get_next_state (state_zmp &s) const =0 |
| Returns the next state. More...
|
|
|
virtual void | get_state (state_com &s, const int ind) const =0 |
| Returns a state with given index. More...
|
|
virtual void | get_state (state_zmp &s, const int ind) const =0 |
| Returns a state with given index. More...
|
|
Abstract class providing common interface functions.
Definition at line 201 of file smpc_solver.h.
◆ ~solver()
smpc::solver::~solver |
( |
| ) |
|
|
pure virtual |
◆ form_init_fp() [1/2]
virtual void smpc::solver::form_init_fp |
( |
const double * |
x_coord, |
|
|
const double * |
y_coord, |
|
|
const state_com & |
init_state, |
|
|
double * |
X |
|
) |
| |
|
pure virtual |
Generates an initial feasible point.
- Parameters
-
[in] | x_coord | x coordinates of points satisfying constraints |
[in] | y_coord | y coordinates of points satisfying constraints |
[in] | init_state | initial state (smpc::state_com or smpc::state_zmp) |
[in,out] | X | solution of optimization problem |
Implemented in smpc::solver_ip, and smpc::solver_as.
◆ form_init_fp() [2/2]
virtual void smpc::solver::form_init_fp |
( |
const double * |
x_coord, |
|
|
const double * |
y_coord, |
|
|
const state_zmp & |
init_state, |
|
|
double * |
X |
|
) |
| |
|
pure virtual |
Generates an initial feasible point.
- Parameters
-
[in] | x_coord | x coordinates of points satisfying constraints |
[in] | y_coord | y coordinates of points satisfying constraints |
[in] | init_state | initial state (smpc::state_com or smpc::state_zmp) |
[in,out] | X | solution of optimization problem |
Implemented in smpc::solver_ip, and smpc::solver_as.
◆ get_controls()
virtual void smpc::solver::get_controls |
( |
control & |
c, |
|
|
const int |
ind |
|
) |
| const |
|
pure virtual |
The same as get_first_controls, but takes an additional parameter - the index of the control inputs. Control[ind] is applied to State[ind-1] to reach State[ind].
- Parameters
-
[out] | c | an output control vector |
[in] | ind | index of control inputs [0 : N-1]. |
Implemented in smpc::solver_ip, and smpc::solver_as.
◆ get_first_controls()
virtual void smpc::solver::get_first_controls |
( |
control & |
c | ) |
const |
|
pure virtual |
Returns the controls that must be applied to reach the next state.
- Parameters
-
[out] | c | an output control vector |
Implemented in smpc::solver_ip, and smpc::solver_as.
◆ get_next_state() [1/2]
virtual void smpc::solver::get_next_state |
( |
state_com & |
s | ) |
const |
|
pure virtual |
◆ get_next_state() [2/2]
virtual void smpc::solver::get_next_state |
( |
state_zmp & |
s | ) |
const |
|
pure virtual |
◆ get_state() [1/2]
virtual void smpc::solver::get_state |
( |
state_com & |
s, |
|
|
const int |
ind |
|
) |
| const |
|
pure virtual |
Returns a state with given index.
- Parameters
-
[out] | s | an output state. |
[in] | ind | index of a state [0 : N-1]. |
Implemented in smpc::solver_ip, and smpc::solver_as.
◆ get_state() [2/2]
virtual void smpc::solver::get_state |
( |
state_zmp & |
s, |
|
|
const int |
ind |
|
) |
| const |
|
pure virtual |
Returns a state with given index.
- Parameters
-
[out] | s | an output state. |
[in] | ind | index of a state [0 : N-1]. |
Implemented in smpc::solver_ip, and smpc::solver_as.
◆ set_parameters()
virtual 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 |
|
) |
| |
|
pure virtual |
Initializes quadratic problem.
- Parameters
-
[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 |
Implemented in smpc::solver_ip, and smpc::solver_as.
◆ solve()
virtual void smpc::solver::solve |
( |
| ) |
|
|
pure virtual |
The documentation for this class was generated from the following files: