Main Content

Joint-Space Motion Model

The joint-space motion model characterizes the closed-loop motion of a manipulator under joint-space control, where the control action is defined in the joint configuration space with respect to the desired joint configuration. This topic covers the variables and equations for calculating joint-space motion control used in the jointSpaceMotionModel object. For task-space motion models, see the Plan and Execute Task- and Joint-Space Trajectories Using KINOVA Gen3 Manipulator object.

Types of joint-space control:

For an example that covers the difference between task-space and joint-space control, see Plan and Execute Task- and Joint-Space Trajectories Using KINOVA Gen3 Manipulator.

Th joint-space motion model has the following state:

  • q — Robot joint configuration vector containing the array of joint positions defined in rad for revolute and m for prismatic joints

  • q˙ — Vector of joint velocities in rads and ms

  • q¨ — Vector of joint accelerations in rads2 or ms2

The motion model includes three ways to model and control the overall behavior:

  • Independent Joint Motion: Each joint is modeled independently as a second-order system. This model may be considered a best-case scenario for how closed-loop motion may behave since the dynamics are simplified and directly prescribed.

  • Computed Torque Control: The rigid body dynamics are modeled using the standard equations of motion, but compensating for the full-body dynamics and assigning error dynamics. This is a higher-fidelity version of the independent joint motion control.

  • PD Control: The rigid body dynamics are modeled using the standard equations of motion with a joint torque input given by proportional-derivative (PD) control. This model represents a controller that does not compensate tightly for the overall effects of rigid body motion.

To set these different control types, see the MotionType property on the jointSpaceMotionModel object

Equations of Motion

Independent Joint Motion

When performing inpdependent joint motion control, instead of modeling the robot with the standard rigid body dynamics, each joint is modeled as a second-order system. Therefore, the i-th joint has the following dynamics:

q¨i=-ωn2qi-2ζωnq˙i

qi=qi-qi,ref

These parameters characterize the desired response defined for each joint:

  • ωn — the natural frequency specified in units of 1/s

  • ζ — t the damping ratio, which is unitless

The manipulator dynamics are then modeled as:

ddt[qq˙]=[0I[-ωn2]diag[-2ζωn]diag][qq˙]+[0I[ωn2]diag[2ζωn]diag][qrefq˙ref]

The control input relies on these user-defined parameters:

  • [-ωn2]diag — Diagonal matrix where the (i,i)-th element corresponds to the i-th element of the N-element vector of natural frequencies (NaturalFrequency) in Hz (s-1)

  • [-2ζωn2]diag — Diagonal matrix where the (i,i)-th element corresponds to a product of the natural frequencies and the damping ratios (DampingRatio) of the i-th element.

This model accepts the following inputs:

  • qref — Reference joint configuration vector containing the array of reference robot joint positions specified in rad for revolute and m for prismatic joints

  • q˙ref — Reference joint velocities vector, in rad/s or m/s for revolute and prismatic joints, respectively

The values of ωn iand ζ may be set directly, or they may be provided using the updateErrorDynamicsFromStep object function, which computes values for ωn iand ζ based on desired unit step response.

Computed Torque Control

With computed torque control, the motion model uses standard rigid body dynamics, but with the torque input τ given by a control law that compensates for the rigid body dynamics and instead assigns a second-order dynamics response:

ddt[qq˙]=fdyn(q,q˙,τ,Fext)

τ=M(q)aa+C(q,q˙)q˙+G(q)

aq=q¨ref-[ωn2]diagq-[2ζωn]diagq˙

qi=q-qref

where,

  • M(q) — Joint-space mass matrix based on the current robot configuration calculated by the massMatrix object function.

  • C(q,q˙) — Coriolis terms, which when multiplied by q˙ results in the velocity product calculated by the velocityProduct object function.

  • G(q) — Gravity torques and forces for all joints to maintain their positions in the specified gravity (Gravity) calculated by the gravityTorque object function.

The control input relies on these user-defined parameters:

  • [-ωn2]diag — Diagonal matrix where the (i,i)-th element corresponds to the i-th element of the N-element vector of natural frequencies (NaturalFrequency) in Hz (s-1)

  • [-2ζωn2]diag — Diagonal matrix where the (i,i)-th element corresponds to a product of the natural frequencies and the damping ratios (DampingRatio) of the i-th element.

This model accepts qref,q˙ref,q¨ref as the desired reference joint configuration, velocities, and accelrations.

Because the dynamics are compensated, no external forces should be felt. The computed torque control motion model behaves the same as the independent joint motion model.

As with independent joint motion, the values of ωn iand ζ may be set directly, or they may be provided using the the updateErrorDynamicsFromStep object function, which computes values for ωn iand ζ based on desired unit step response.

Proportional-Derivative (PD) Control

With PD control, the robot models behavior according to standard rigid body dynamics, but with the torque input τ given by a control law that applies PD control based on the joint error and gravity compensation:

ddt[qq˙]=fdyn(q,q˙,τ,Fext)

τ=-KP(q-qref)-KD(q˙-q˙ref)+G(q)

where

  • G(q) — Gravity torques and forces for all joints to maintain their positions in the specified gravity (Gravity) calculated by the gravityTorque object function.

The control input relies on these user-defined parameters:

  • KP: Proportional gain, specified as an N-by-N matrix

  • KD: Derivative gain, specified as an N-by-N matrix

This model accepts qref,q˙ref as the desired reference joint configuration and velocities.