Module 5: Applications Lesson 2 of 3

Velocity Kinematics

Forward kinematics tells us where the end-effector is. But for real-time control, we also need to know how fast it’s moving and in which direction. This is the domain of velocity kinematics, and its central object is the Jacobian matrix.

From Positions to Velocities

Recall from the previous lesson that forward kinematics gives us a vector function:

x=f(q)\mathbf{x} = f(\mathbf{q})

where q=[θ1,θ2,,θn]T\mathbf{q} = [\theta_1, \theta_2, \ldots, \theta_n]^T is the joint angle vector and x\mathbf{x} is the end-effector pose. Differentiating with respect to time:

x˙=fqq˙=J(q)q˙\dot{\mathbf{x}} = \frac{\partial f}{\partial \mathbf{q}} \dot{\mathbf{q}} = J(\mathbf{q}) \dot{\mathbf{q}}

The matrix J(q)J(\mathbf{q}) is the Jacobian — it linearly maps joint velocities q˙\dot{\mathbf{q}} to end-effector velocities x˙\dot{\mathbf{x}}.

The Jacobian Is a Matrix of Partial Derivatives

Each entry of the Jacobian is a partial derivative:

Jij=xiqjJ_{ij} = \frac{\partial x_i}{\partial q_j}

Row ii tells how end-effector component xix_i responds to each joint. Column jj tells what velocity the end-effector gets when only joint jj moves.

For the 2R arm from the previous lesson:

x=L1cosθ1+L2cos(θ1+θ2)x = L_1\cos\theta_1 + L_2\cos(\theta_1 + \theta_2) y=L1sinθ1+L2sin(θ1+θ2)y = L_1\sin\theta_1 + L_2\sin(\theta_1 + \theta_2)

Taking partial derivatives:

J=[xθ1xθ2yθ1yθ2]=[L1s1L2s12L2s12L1c1+L2c12L2c12]J = \begin{bmatrix} \frac{\partial x}{\partial \theta_1} & \frac{\partial x}{\partial \theta_2} \\[6pt] \frac{\partial y}{\partial \theta_1} & \frac{\partial y}{\partial \theta_2} \end{bmatrix} = \begin{bmatrix} -L_1 s_1 - L_2 s_{12} & -L_2 s_{12} \\ L_1 c_1 + L_2 c_{12} & L_2 c_{12} \end{bmatrix}

where s1=sinθ1s_1 = \sin\theta_1, c1=cosθ1c_1 = \cos\theta_1, s12=sin(θ1+θ2)s_{12} = \sin(\theta_1 + \theta_2), c12=cos(θ1+θ2)c_{12} = \cos(\theta_1 + \theta_2).

Reading the Jacobian

The end-effector velocity is a linear combination:

[x˙y˙]=θ˙1J1+θ˙2J2\begin{bmatrix} \dot{x} \\ \dot{y} \end{bmatrix} = \dot\theta_1 \cdot \mathbf{J}_1 + \dot\theta_2 \cdot \mathbf{J}_2

where J1\mathbf{J}_1 and J2\mathbf{J}_2 are the columns of JJ.

Velocity Computation Robotics Application

At θ1=45°,θ2=90°\theta_1 = 45°, \theta_2 = 90° with L1=2,L2=1.5L_1 = 2, L_2 = 1.5:

s1=0.707,c1=0.707,s12=sin(135°)=0.707,c12=cos(135°)=0.707s_1 = 0.707, \quad c_1 = 0.707, \quad s_{12} = \sin(135°) = 0.707, \quad c_{12} = \cos(135°) = -0.707J=[2(0.707)1.5(0.707)1.5(0.707)2(0.707)+1.5(0.707)1.5(0.707)]=[2.4751.0610.3541.061]J = \begin{bmatrix} -2(0.707) - 1.5(0.707) & -1.5(0.707) \\ 2(0.707) + 1.5(-0.707) & 1.5(-0.707) \end{bmatrix} = \begin{bmatrix} -2.475 & -1.061 \\ 0.354 & -1.061 \end{bmatrix}

If joint 1 rotates at 1 rad/s and joint 2 is stationary:

x˙=J[10]=[2.4750.354] m/s\dot{\mathbf{x}} = J \begin{bmatrix} 1 \\ 0 \end{bmatrix} = \begin{bmatrix} -2.475 \\ 0.354 \end{bmatrix} \text{ m/s}

The end-effector moves mostly in the x-x direction — it’s swinging leftward.

Singularities

A configuration is singular when the Jacobian loses rank — that is, when det(J)=0\det(J) = 0. At a singularity, there exist directions in which the end-effector cannot move regardless of joint velocities.

For the 2R arm:

det(J)=L1L2sinθ2\det(J) = L_1 L_2 \sin\theta_2

This is zero when θ2=0\theta_2 = 0 or θ2=π\theta_2 = \pi:

Singularities in Practice

Near a singularity:

  • Some end-effector velocities require infinite joint velocities (the robot can’t keep up)
  • The inverse Jacobian J1J^{-1} blows up — computed joint commands become unreasonably large
  • The robot may exhibit jerky, unstable motion
  • Force control becomes problematic: the robot can exert very large forces in certain directions with tiny joint torques

Industrial robots have singularity-avoidance algorithms that detect when the robot approaches a singular configuration and modify the trajectory accordingly.

Singularities of 6-DOF Arms

For a 6-DOF arm, singularities are more complex. Common cases include:

The Manipulability Ellipsoid

The manipulability ellipsoid visualizes how “capable” the robot is at a given configuration. It answers: if the joints can produce unit-speed velocities, what is the set of achievable end-effector velocities?

Mathematically, the set {x˙:q˙1}\{\dot{\mathbf{x}} : \|\dot{\mathbf{q}}\| \leq 1\} forms an ellipsoid in task space. This ellipsoid is characterized by JJTJ J^T:

x˙T(JJT)1x˙1\dot{\mathbf{x}}^T (J J^T)^{-1} \dot{\mathbf{x}} \leq 1

The eigenvectors of JJTJ J^T give the principal directions of the ellipsoid, and the square roots of the eigenvalues (σ1,σ2,\sigma_1, \sigma_2, \ldots) are the singular values — the semi-axis lengths.

Connection to Eigenvalues (Module 4)

The manipulability ellipsoid is a direct application of eigenanalysis from Module 4. The eigenvalues of JJTJ J^T determine the ellipsoid shape:

  • Large eigenvalue → the robot can move fast in that direction
  • Small eigenvalue → the robot struggles in that direction
  • Zero eigenvalue → singularity — motion is impossible in that direction

The condition number κ=σ1/σ2\kappa = \sigma_1 / \sigma_2 measures isotropy. When κ=1\kappa = 1, the ellipsoid is a circle (uniform capability). As κ\kappa \to \infty, the robot approaches a singularity.

Yoshikawa’s Manipulability Measure

A single scalar summarizing the robot’s overall dexterity:

w=det(JJT)=σ1σ2σmw = \sqrt{\det(J J^T)} = \sigma_1 \cdot \sigma_2 \cdots \sigma_m

Optimal Configuration Robotics Application

For a 2R arm with L1=2,L2=1.5L_1 = 2, L_2 = 1.5:

  • At θ2=90°\theta_2 = 90°: w=2×1.5×sin(90°)=3.0w = 2 \times 1.5 \times \sin(90°) = 3.0 (maximum)
  • At θ2=45°\theta_2 = 45°: w=2×1.5×sin(45°)2.12w = 2 \times 1.5 \times \sin(45°) \approx 2.12
  • At θ2=10°\theta_2 = 10°: w=2×1.5×sin(10°)0.52w = 2 \times 1.5 \times \sin(10°) \approx 0.52 (poor)
  • At θ2=0°\theta_2 = 0°: w=0w = 0 (singular)

The best configuration is the right-angle elbow (θ2=90°\theta_2 = 90°), where the manipulability ellipsoid is closest to a circle. You can verify this with the interactive visualization below.

The 6-DOF Jacobian

For a general 6-DOF arm, the Jacobian is a 6×6 matrix mapping 6 joint velocities to the 6-dimensional end-effector velocity (3 linear + 3 angular):

[vω]=J(q)q˙\begin{bmatrix} \mathbf{v} \\ \boldsymbol{\omega} \end{bmatrix} = J(\mathbf{q}) \dot{\mathbf{q}}

where v=[x˙,y˙,z˙]T\mathbf{v} = [\dot{x}, \dot{y}, \dot{z}]^T is linear velocity and ω=[ωx,ωy,ωz]T\boldsymbol{\omega} = [\omega_x, \omega_y, \omega_z]^T is angular velocity. Each column of JJ has two parts:

Ji=[Jv,iJω,i]\mathbf{J}_i = \begin{bmatrix} \mathbf{J}_{v,i} \\ \mathbf{J}_{\omega,i} \end{bmatrix}

For revolute joint ii, these are computed from the forward kinematics:

Jv,i=z^i1×(pnpi1),Jω,i=z^i1\mathbf{J}_{v,i} = \hat{z}_{i-1} \times (\mathbf{p}_n - \mathbf{p}_{i-1}), \quad \mathbf{J}_{\omega,i} = \hat{z}_{i-1}

where z^i1\hat{z}_{i-1} is the rotation axis of joint ii and pi1\mathbf{p}_{i-1} is the origin of frame {i1}\{i-1\}. The linear velocity contribution is the cross product of the rotation axis with the vector from the joint to the end-effector — this is the formula for the velocity of a point on a rotating body.

Resolved-Rate Motion Control

The Jacobian enables a powerful control strategy: instead of planning in joint space, plan a desired end-effector velocity x˙d\dot{\mathbf{x}}_d and compute the required joint velocities:

q˙=J1(q)x˙d\dot{\mathbf{q}} = J^{-1}(\mathbf{q}) \dot{\mathbf{x}}_d

This is resolved-rate control. In practice, we use the pseudoinverse J+J^+ for robustness:

q˙=J+(q)x˙d\dot{\mathbf{q}} = J^+(\mathbf{q}) \dot{\mathbf{x}}_d

Near singularities, the damped least-squares (DLS) inverse is preferred:

q˙=JT(JJT+λ2I)1x˙d\dot{\mathbf{q}} = J^T (J J^T + \lambda^2 I)^{-1} \dot{\mathbf{x}}_d

where λ\lambda is a damping factor that trades off tracking accuracy for numerical stability. This connects directly to the matrix inverse and condition number concepts from Module 2.

Static Force Analysis

The Jacobian also relates joint torques τ\boldsymbol{\tau} to end-effector forces f\mathbf{f} through the principle of virtual work:

τ=JTf\boldsymbol{\tau} = J^T \mathbf{f}

The transpose of the Jacobian maps task-space forces to joint-space torques. This duality between velocity and force is a fundamental result of Lagrangian mechanics.

Interactive Visualization

Explore the Jacobian for a 2-link planar arm. Adjust joint angles and velocities to see how the Jacobian maps joint motion to end-effector velocity. The manipulability ellipsoid shows the robot’s directional capability at each configuration.

Controls

Configuration

-3.1415926535897933.141592653589793
-3.1415926535897933.141592653589793

Joint Velocities

-22
-22

Jacobian J(θ)

[-2.86-1.45]
[1.03-0.39]

Analysis

det(J) = 2.598
w (manipulability) = 2.598
σ₁ = 3.298σ₂ = 0.788
condition # = 4.2
v_ee = (-2.86, 1.03)
|v_ee| = 3.041

Try this: Set "Right Angle" for a well-conditioned configuration (round ellipsoid). Then click "Singular" (θ₂ → 0) and watch the ellipsoid collapse to a line — the robot loses the ability to move radially. Try different joint velocity inputs to see how the Jacobian maps them to end-effector velocity.

Practice Problems

  1. For a 2R arm with L1=L2=1L_1 = L_2 = 1, compute the Jacobian at θ1=0,θ2=90°\theta_1 = 0, \theta_2 = 90°. What is det(J)\det(J)?

  2. At the configuration from Problem 1, if θ˙1=1\dot\theta_1 = 1 rad/s and θ˙2=1\dot\theta_2 = -1 rad/s, what is the end-effector velocity?

  3. Find all singular configurations for a 2R arm. Describe geometrically what happens at each.

  4. A 2R arm has L1=3,L2=2L_1 = 3, L_2 = 2. At what value of θ2\theta_2 is the manipulability measure ww maximized? What is wmaxw_{\max}?

  5. For the 6-DOF Jacobian column formula Jv,i=z^i1×(pnpi1)\mathbf{J}_{v,i} = \hat{z}_{i-1} \times (\mathbf{p}_n - \mathbf{p}_{i-1}), explain why this gives the correct linear velocity contribution from joint ii.

Answers
  1. At θ1=0,θ2=90°\theta_1 = 0, \theta_2 = 90°: s1=0,c1=1,s12=1,c12=0s_1 = 0, c_1 = 1, s_{12} = 1, c_{12} = 0. J=[0111+00]=[1110]J = \begin{bmatrix} -0 - 1 & -1 \\ 1 + 0 & 0 \end{bmatrix} = \begin{bmatrix} -1 & -1 \\ 1 & 0 \end{bmatrix}. det(J)=(1)(0)(1)(1)=1=L1L2sin(90°)\det(J) = (-1)(0) - (-1)(1) = 1 = L_1 L_2 \sin(90°).

  2. x˙=J[11]=[1+11+0]=[01]\dot{\mathbf{x}} = J \begin{bmatrix} 1 \\ -1 \end{bmatrix} = \begin{bmatrix} -1+1 \\ 1+0 \end{bmatrix} = \begin{bmatrix} 0 \\ 1 \end{bmatrix} m/s. The end-effector moves straight up.

  3. Singular when sinθ2=0\sin\theta_2 = 0, i.e., θ2=0\theta_2 = 0 (arm fully extended — cannot move radially inward/outward) or θ2=π\theta_2 = \pi (arm fully folded — same issue, also the end-effector is at a distance of L1L2|L_1 - L_2| from the base).

  4. w=L1L2sinθ2=6sinθ2w = L_1 L_2 |\sin\theta_2| = 6|\sin\theta_2|. Maximized at θ2=±90°\theta_2 = \pm 90° with wmax=6w_{\max} = 6.

  5. Joint ii rotates frame {i1}\{i-1\} about z^i1\hat{z}_{i-1}. The end-effector is at distance pnpi1\|\mathbf{p}_n - \mathbf{p}_{i-1}\| from the joint. The velocity of a point at distance r\mathbf{r} from a rotation axis ω^\hat{\omega} rotating at rate θ˙\dot\theta is v=ω^×rθ˙\mathbf{v} = \hat{\omega} \times \mathbf{r} \cdot \dot\theta. With ω^=z^i1\hat{\omega} = \hat{z}_{i-1} and r=pnpi1\mathbf{r} = \mathbf{p}_n - \mathbf{p}_{i-1}, this is exactly Jv,iθ˙i\mathbf{J}_{v,i} \cdot \dot\theta_i.

Key Takeaways

  1. The Jacobian J(q)J(\mathbf{q}) maps joint velocities to end-effector velocities: x˙=Jq˙\dot{\mathbf{x}} = J \dot{\mathbf{q}}
  2. Each Jacobian entry is a partial derivative: Jij=xi/qjJ_{ij} = \partial x_i / \partial q_j
  3. Singularities occur when det(J)=0\det(J) = 0 — some end-effector motions become impossible
  4. The manipulability ellipsoid (from the eigenvalues of JJTJ J^T) visualizes directional capability
  5. The Jacobian transpose maps end-effector forces to joint torques: τ=JTf\boldsymbol{\tau} = J^T \mathbf{f}
  6. Resolved-rate control uses J1J^{-1} (or J+J^+) to compute joint velocities for a desired task-space motion

Next Steps

The final lesson brings these tools to bear on path planning — using potential fields, gradients, and trajectory interpolation to move robots through cluttered environments.