Coordinate Frames and Kinematics
Base, world, tool and user frames, the tool center point, forward and inverse kinematics, the wrist, configurations and singularities.
Frames
A robot works in coordinate frames: a set of axes with an origin and an orientation. Everything the robot does is a statement about one frame relative to another.
| Frame | Attached to | Used for |
|---|---|---|
| Base frame | The robot base | The reference for the joint-based kinematics; fixed by the manufacturer |
| World frame | The cell (a fixed point on the floor) | A common reference for several robots and devices |
| Tool frame | The tool; origin at the tool center point (TCP) | Moving the tip, not the flange; tool orientation |
| User or work-object frame | A fixture, pallet, conveyor or part | Teaching points relative to the work, so they survive the fixture moving |
| Flange frame | The wrist mounting face | The origin of the tool frame offset |
| Camera frame | A camera | Vision guidance (see Vision, Calibration and Accuracy) |
Worked example: where is the part, in each frame?
- The fixture frame sits at (780, 90) mm in the world frame, turned 20°. A part is taught at (120, 70) mm in the fixture frame.
- In the world frame the point is x = 780 + 120 cos 20° − 70 sin 20° = 868.8, y = 90 + 120 sin 20° + 70 cos 20° = 196.8 mm.
- The robot base is at (250, 150) in the world frame, not turned, so in the base frame the point is (618.8, 46.8) mm, 621 mm from the base axis.
- If the fixture is bumped by 6 mm in x, re-measure the one fixture frame and every point taught in it moves by the same 6 mm in the world. Had all the points been taught in the world or base frame, each would have to be taught again.
- Each step is a rotation followed by a translation; in matrix form a 4 × 4 homogeneous transform T. Chains of frames multiply: Tbase→part = Tbase→world × Tworld→fixture × Tfixture→part.
The tool center point
The TCP is the point that does the work: the fingertips of the gripper, the wire tip of a welding torch, the face of the suction cup. The controller knows only where the flange is; the TCP offset tells it where the tool is relative to the flange. With the wrong TCP the tool tip swings through an arc whenever the robot reorients, instead of staying put.
Worked example: finding the TCP by touching one point
- Touch the same fixed point from several orientations of the flange (a pointed tool against a fixed tip, or a laser against a mark). The point is fixed, so for each pose the flange position p and the angle θ satisfy p + R(θ) t = P, where t is the unknown tool offset.
- Pose 1: flange at (471.8, 301.2) with θ = 20°. Pose 2: flange at (557.3, 420.9) with θ = -50°.
- Subtracting the two equations gives (R1 − R2) t = p2 − p1, a 2 × 2 system whose solution is t = (120.0, -45.0) mm (the true offset used to generate the poses was (120, -45)).
- Check with a third pose (θ = 95°): p + R t = (600.0, 300.0), which lands on the touch point (600, 300). Real controllers use four or more poses in 3D and a least-squares fit, and report the residual.
- What an error does: a TCP wrong by 15 mm makes the tip move by 2 × 15 × sin(90° ÷ 2) = 21.2 mm when the tool is rotated by 90° about the flange. Re-measure the TCP after any crash, tool change or finger replacement.
- Set the TCP, the payload (mass and center of gravity) and the tool frame together: they belong to the same tool definition (see Payload, Inertia, Speed and Cycle Time).
- One tool, one number: for a gripper with several picking points, define a TCP for each, or one TCP and fixed offsets in the program.
- Check by rotating: reorient the tool in jog mode about the TCP: the tip should stay on a fixed point.
Describing orientation
A position is three numbers; an orientation also needs three, but there is no single way to write them down, and the manufacturers differ. That is a common source of confusion when moving data between systems.
| Convention | Used by (typically) | Notes |
|---|---|---|
| Quaternion (q1, q2, q3, q4) | ABB, ROS, many simulators | Four numbers, no singularities; hard to read |
| Euler angles (for example W, P, R or A, B, C) | FANUC (W, P, R), KUKA (A, B, C) | Three rotations in a stated order; singular at ±90° of the middle angle |
| Rotation vector (axis times angle) | Universal Robots | Three numbers; the length is the angle in radians |
| Rotation matrix (3 × 3) | Textbooks and libraries | Nine numbers, unambiguous; used inside controllers |
Worked example: turning the tool 90° about z
- As a rotation matrix: rows (0, -1, 0), (1, 0, 0), (0, 0, 1). As a quaternion (w, x, y, z) = (cos 45°, 0, 0, sin 45°) = (0.707, 0, 0, 0.707). As a rotation vector: (0, 0, 1.571) rad.
- The same physical rotation looks completely different in each. Always state the convention and the units (degrees or radians) when exchanging poses, and check one known pose before trusting a transfer.
Forward kinematics
Forward kinematics turns joint angles into the tool pose. For two links in a plane (the horizontal axes of a SCARA, or a side view of an arm) with lengths L1 and L2:
x = L1 cos θ1 + L2 cos(θ1 + θ2) y = L1 sin θ1 + L2 sin(θ1 + θ2)
For a six-axis arm the same idea is applied joint by joint, multiplying a transform for each link; the Denavit–Hartenberg (DH) convention is the standard way to tabulate link lengths, offsets and twists so that this can be automated (see Robotics Tools for code).
Inverse kinematics
Inverse kinematics (IK) goes the other way: given a target pose, find the joint angles. It is what the controller must solve for every point on a path. For the two-link arm:
cos θ2 = (x² + y² − L1² − L2²) ÷ (2 L1 L2) θ1 = atan2(y, x) − atan2(L2 sin θ2, L1 + L2 cos θ2)
The target is reachable only if its distance from the base lies between |L1 − L2| and L1 + L2. There are normally two solutions (θ2 positive or negative): the right-hand and left-hand elbow.
Worked example: L₁ = 400 mm, L₂ = 350 mm, target (500, 300)
- Distance = √(500² + 300²) = 583.1 mm; the reachable range is 50 to 750 mm, so the target is inside.
- cos θ2 = (340 000 − 282 500) ÷ (2 × 400 × 350) = 0.2054, so θ2 = ±78.15°.
- Elbow right: θ1 = -5.01°, θ2 = 78.15°. Elbow left: θ1 = 66.94°, θ2 = -78.15°.
- Check by forward kinematics: both give (500.00, 300.00) and (500.00, 300.00).
Six axes and the wrist
A six-axis arm splits the problem. The first three joints (waist, shoulder, elbow) place the wrist center; the last three (the wrist) orient the tool. Most industrial arms have a spherical wrist, where the three wrist axes meet at a point, which lets the position and orientation problems be solved separately in closed form (no iteration).
- Up to 8 solutions for one pose: two for the shoulder (left or right of the base axis), two for the elbow (up or down) and two for the wrist (flipped or not): 2 × 2 × 2 = 8. Joint limits remove some.
- The controller picks the solution nearest to the current joint angles (or the one the configuration flags select), so a point taught in one configuration is reached in that configuration.
- A seventh axis (a track, a rotary table or a seven-joint arm) gives a redundant degree of freedom: more solutions, and a way to avoid singularities and obstacles.
- Offset wrists (common on collaborative robots) have no closed-form solution; the controller solves them numerically. This is why a pose can occasionally be reported as unreachable although it looks fine.
Singularities
At a singularity the robot loses the ability to move the tool in some direction, however fast the joints turn, and the opposite happens too: to move the tool at a steady speed in the singular direction needs ever faster joints. The mathematics is the Jacobian J that links joint speeds to tool speed; where its determinant is zero, the arm is singular. For the two-link arm det J = L1 L2 sin θ2.
| Elbow angle θ₂ | Tool distance from the base | det J | Fraction of the maximum |
|---|---|---|---|
| 5° | 749 mm | 12 × 10³ mm² | 9 % |
| 20° | 739 mm | 48 × 10³ mm² | 34 % |
| 45° | 693 mm | 99 × 10³ mm² | 71 % |
| 90° | 532 mm | 140 × 10³ mm² | 100 % |
| 135° | 291 mm | 99 × 10³ mm² | 71 % |
Worked example: a radial move at 500 mm/s
- Moving the tool outward along a line through the base at 500 mm/s, the elbow must turn at up to 1 229°/s in the last 100 mm before full reach, and without limit as it reaches 750 mm.
- With a joint speed limit of 300°/s, the move is no longer possible at 500 mm/s beyond about 728 mm: the controller slows the tool (or stops with a fault) so that the joints stay within their limits.
- The same happens near the base (folded arm) at about 72 mm or less, and in the wrist when two axes line up (axis 4 and axis 6 are collinear when axis 5 is near 0°).
| Singularity | Where it occurs | Avoid by |
|---|---|---|
| Elbow (extension) | Arm fully straight or fully folded | Keeping working points inside 30 to 85 % of the reach |
| Shoulder | Wrist center on the waist axis | Not working directly above or below the base |
| Wrist | Axis 5 near 0° (axes 4 and 6 aligned) | Tilting the tool by a few degrees, or changing the approach |
- Joint moves pass through singularities without trouble; linear moves are the ones that fail (see Motion, Paths and Programming).
- If a linear move slows or faults near a point, change the tool orientation slightly, use a joint move through the zone, or move the part.
- Some controllers offer wrist-singularity handling that lets the tool orientation drift to keep position: check what the option does before using it for welding or dispensing.
Configurations and turns
- Configuration flags select among the IK solutions (arm left or right, elbow up or down, wrist flipped or not). The controller keeps the flags of the point it moves from unless told otherwise, so a path that needs to change configuration needs a joint move through a safe region.
- Axis turns. Some axes can turn more than 360°; the same angle can be 10°, 370° or −350°. A taught point stores which, and a move to it may unwind the wrist by almost a full turn: watch for a “long way round” move near people or obstacles.
- Joint limits (software and hardware) bound each axis; a pose reachable in one configuration can be impossible in another. Check reachability of every taught point in simulation (see Robotics Tools).
- Teach with the same configuration you will run: a point taught with the elbow up and called with the elbow down is a different, possibly impossible, pose.
Related
- Industrial Robotics: the overview of this guide.
- Motion, Paths and Programming: joint, linear and circular moves and the paths they follow.
- Vision, Calibration and Accuracy: camera and robot frames and calibration.
- Robotics Tools: forward and inverse kinematics in code.
FAQ
What is the TCP?
The tool center point: the point of the tool that does the work, defined as an offset from the flange. Programs move the TCP, so it must be measured correctly or the tool will swing when the robot reorients.
Why does the robot say “position unreachable”?
The point is outside the envelope, the tool orientation cannot be reached from the current configuration, the point is in a dead zone near the base, or a joint limit blocks the solution. Check the distance to the base and try the other configuration.
Why does a linear move slow down or stop?
Near a singularity (straight or folded arm, aligned wrist axes) a straight-line move needs very high joint speeds. The controller limits them, so the tool slows or the robot faults. Change the pose, the path or the tool orientation.
What is the difference between world, base and user frames?
The base frame is fixed to the robot, the world frame to the cell, and user frames to fixtures or parts. Teaching points in a user frame lets you move the fixture by re-measuring one frame.
References
- Craig, J. J., Introduction to Robotics: Mechanics and Control, Pearson; Spong, M., Hutchinson, S. and Vidyasagar, M., Robot Modeling and Control, Wiley.
- Siciliano, B. and others, Robotics: Modeling, Planning and Control, Springer; ISO 9787 (robot coordinate systems and motion nomenclatures).
- Robot manufacturers’ programming manuals for the exact frame, configuration and orientation conventions.
Last reviewed: October 2026. Link lengths, offsets and speeds are illustrative: use the manufacturer’s kinematic data.
