Skip to content

Kinematics

Conceptual

Kinematics is the branch of robotics that describes how parts of a robot move in space (the geometry of motion), without considering the forces (such as torque or inertia) that cause the motion. It provides the mathematical foundation for computing where an end-effector will be given joint angles (forward kinematics) and for determining what joint angles are needed to reach a desired pose (inverse kinematics).

Prerequisites

Forward vs Inverse Kinematics

Forward Kinematics (FK)

Given the joint angles/positions, compute where the end-effector is in space.

Joint Angles → [FK] → End-Effector Position
θ₁, θ₂, θ₃ → → (x, y, z, roll, pitch, yaw)

Example: If a 2-link arm has joints at 45° and 30°, where is the gripper?

Inverse Kinematics (IK)

Given a desired end-effector position, compute the required joint angles.

End-Effector Position → [IK] → Joint Angles
(x, y, z, orientation) → → θ₁, θ₂, θ₃, ...

Example: To reach a cup at position (0.5, 0.3, 0.2), what should the joint angles be?

The Kinematic Chain

Robots are modeled as a series of links (rigid bodies) connected by joints:

Base → Joint₁ → Link₁ → Joint₂ → Link₂ → ... → End-Effector

Each joint adds degrees of freedom:

  • Revolute joint: 1 DOF (rotation)
  • Prismatic joint: 1 DOF (linear sliding)
  • Spherical joint: 3 DOF (ball-and-socket)

Denavit-Hartenberg (DH) Parameters

The standard way to describe robot kinematics uses four parameters per joint:

ParameterSymbolDescription
Link lengthaᵢDistance along xᵢ
Link twistαᵢAngle about xᵢ
Link offsetdᵢDistance along zᵢ₋₁
Joint angleθᵢAngle about zᵢ₋₁

Code Example

Using Python with NumPy for a simple 2-link planar arm:

import numpy as np
def forward_kinematics_2link(theta1, theta2, L1, L2):
"""
Compute end-effector position for a 2-link planar arm.
Args:
theta1: First joint angle (radians)
theta2: Second joint angle (radians)
L1: Length of first link
L2: Length of second link
Returns:
(x, y) position of end-effector
"""
# Position of joint 2
x1 = L1 * np.cos(theta1)
y1 = L1 * np.sin(theta1)
# Position of end-effector
x2 = x1 + L2 * np.cos(theta1 + theta2)
y2 = y1 + L2 * np.sin(theta1 + theta2)
return x2, y2
# Example: 45° and 30° with unit links
x, y = forward_kinematics_2link(
np.radians(45),
np.radians(30),
L1=1.0,
L2=1.0
)
print(f"End-effector at: ({x:.3f}, {y:.3f})")
# Output: End-effector at: (0.259, 1.966)

Learn More

Sources