pinocchio  3.3.1
A fast and flexible implementation of Rigid Body Dynamics algorithms and their analytical derivatives
Pendulum Class Reference

Public Member Functions

def __init__ (self, nbJoint=1)
 
def createPendulum (self, nbJoint, rootId=0, prefix="", jointPlacement=None)
 
def display (self, q)
 
def dynamics (self, x, u, display=False)
 
def nobs (self)
 
def nq (self)
 
def nu (self)
 
def nv (self)
 
def nx (self)
 
def obs (self, x)
 
def render (self)
 
def reset (self, x0=None)
 
def step (self, u)
 
def tip (self, q)
 

Public Attributes

 data
 
 DT
 
 Kf
 
 model
 
 NDT
 
 q0
 
 r
 
 umax
 
 viewer
 
 visuals
 
 vmax
 
 withSinCos
 
 x
 

Detailed Description

Define a class Robot with 7DOF (shoulder=3 + elbow=1 + wrist=3).
The configuration is nq=7. The velocity is the same.
The members of the class are:
* viewer: a display encapsulating a gepetto viewer client to create 3D objects and
  place them.
* model: the kinematic tree of the robot.
* data: the temporary variables to be used by the kinematic algorithms.
* visuals: the list of all the 'visual' 3D objects to render the robot, each element
  of the list being an object Visual (see above).

See tp1.py for an example of use.

Definition at line 43 of file pendulum.py.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  nbJoint = 1 
)
Create a Pinocchio model of a N-pendulum, with N the argument <nbJoint>.

Definition at line 58 of file pendulum.py.

Member Function Documentation

◆ dynamics()

def dynamics (   self,
  x,
  u,
  display = False 
)
Dynamic function: x,u -> xnext=f(x,y).
Put the result in x (the initial value is destroyed).
Also compute the cost of making this step.
Return x for convenience along with the cost.

Definition at line 182 of file pendulum.py.

◆ tip()

def tip (   self,
  q 
)
Return the altitude of pendulum tip

Definition at line 177 of file pendulum.py.


The documentation for this class was generated from the following file: