Classes | Functions | Variables
ocp Namespace Reference

Classes

class  CallBack
 

Functions

def cost (U)
 
def display (U, verbose=False)
 

Variables

 approx_grad
 
list bounds = [ [-env.umax,env.umax], ]*env.nu*NSTEPS
 
 c
 
 callback = CallBack()
 
 cost
 
 env = Pendulum(1)
 
 info
 
int NSTEPS = 50
 
 True
 
 U
 
 U0 = zero(NSTEPS*env.nu)-env.umax
 — OCP resolution More...
 
 x0 = env.reset().copy()
 

Detailed Description

Example of optimal control resolution by direct optimization of a single trajectory.

Function Documentation

◆ cost()

def ocp.cost (   U)
Cost for a trajectory starting at state X0 with control U

Definition at line 18 of file ocp.py.

◆ display()

def ocp.display (   U,
  verbose = False 
)
Display the trajectory on Gepetto viewer.

Definition at line 28 of file ocp.py.

Variable Documentation

◆ approx_grad

ocp.approx_grad

Definition at line 62 of file ocp.py.

◆ bounds

ocp.bounds = [ [-env.umax,env.umax], ]*env.nu*NSTEPS

Definition at line 58 of file ocp.py.

◆ c

ocp.c

Definition at line 61 of file ocp.py.

◆ callback

ocp.callback = CallBack()

Definition at line 53 of file ocp.py.

◆ cost

ocp.cost

Definition at line 61 of file ocp.py.

◆ env

ocp.env = Pendulum(1)

Definition at line 14 of file ocp.py.

◆ info

ocp.info

Definition at line 61 of file ocp.py.

◆ NSTEPS

int ocp.NSTEPS = 50

Definition at line 15 of file ocp.py.

◆ True

ocp.True

Definition at line 62 of file ocp.py.

◆ U

ocp.U

Definition at line 61 of file ocp.py.

◆ U0

ocp.U0 = zero(NSTEPS*env.nu)-env.umax

— OCP resolution

Definition at line 57 of file ocp.py.

◆ x0

ocp.x0 = env.reset().copy()

Definition at line 16 of file ocp.py.



pinocchio
Author(s):
autogenerated on Fri Jun 23 2023 02:38:34