Definition
Inverse kinematics (IK) is the problem of computing the joint angles (or joint positions) that place a robot's end-effector at a desired pose — a combination of position (x, y, z) and orientation (roll, pitch, yaw) in Cartesian space. It is the mathematical inverse of forward kinematics, which maps known joint values to end-effector pose. Every time a robot reaches for an object, tracks a path, or follows a Cartesian waypoint, an IK solver runs behind the scenes to convert the spatial target into motor commands the robot can execute.
For a 6-DOF manipulator, IK typically yields a finite set of discrete solutions (up to 16 for a general 6R arm). For redundant robots with 7 or more DOF — such as the Franka Emika Panda or KUKA iiwa — infinitely many joint configurations can achieve the same end-effector pose. This redundancy is both a blessing and a curse: it provides freedom to optimize secondary objectives like joint-limit avoidance, singularity avoidance, or obstacle clearance, but it also makes the solution space vastly more complex.
IK is one of the oldest and most studied problems in robotics, yet it remains central to modern systems. Even in the era of learned transformer policies, IK is used whenever a system needs to convert Cartesian commands into joint commands, for example when a teleoperation device outputs hand poses that must be mapped to robot joint angles.
How It Works
Analytical (closed-form) IK derives exact joint-angle solutions using trigonometric identities specific to the robot's kinematic structure. It is extremely fast (microseconds) and deterministic, but only feasible when the kinematic chain has particular geometric properties — most commonly a spherical wrist (last three joint axes intersecting at a point). Classical industrial robots (e.g., ABB IRB, FANUC LR Mate) are specifically designed with spherical wrists to enable analytical IK. The tool IKFast, part of OpenRAVE, automatically generates closed-form C++ IK solvers for any robot whose structure permits one, producing code that runs in under 5 microseconds per query.
Numerical (iterative) IK treats the problem as nonlinear optimization. The most common family of methods uses the Jacobian matrix J, which linearly maps small joint-angle changes to small end-effector displacements. The basic Jacobian pseudo-inverse method iterates: Δq = J+ · Δx, where Δx is the Cartesian error. This converges quickly near the solution but can fail near singularities where J loses rank. Damped Least Squares (DLS), also called the Levenberg-Marquardt method, adds a damping term (λ) that trades off tracking accuracy for numerical stability near singularities: Δq = JT(JJT + λI)-1 · Δx.
Optimization-based IK formulates the problem as a constrained nonlinear program, minimizing a cost function (e.g., distance from a seed configuration) subject to the kinematic constraint and inequality constraints (joint limits, collision avoidance). Solvers like TRAC-IK run a Jacobian-based solver and a sequential quadratic programming (SQP) solver in parallel, returning whichever succeeds first. This dual approach achieves significantly higher success rates than either method alone, particularly near joint limits and singularities.
Singularities
A singularity is a joint configuration where the Jacobian matrix loses rank, meaning the end-effector loses one or more degrees of freedom of motion. At a singularity, certain Cartesian velocities require infinite joint velocities, which is physically impossible. Common singularities include:
- Wrist singularity — Two wrist axes align, collapsing a degree of freedom. This is the most frequently encountered singularity in 6-DOF arms.
- Shoulder singularity — The end-effector aligns with the base axis, typically when the arm is fully extended or retracted.
- Elbow singularity — The arm is fully extended, making it impossible to move the end-effector along the arm's length.
Avoiding singularities in practice involves monitoring the manipulability index (det(JJT)), using DLS near low-manipulability regions, or designing task trajectories that steer clear of singular configurations. For redundant robots, the null-space motion can be optimized to continuously maximize manipulability while tracking the desired end-effector path.
Libraries and Tools
- IKFast (OpenRAVE) — Generates analytical C++ IK solvers. Extremely fast but limited to robots with compatible geometry. Widely used in industrial settings.
- TRAC-IK — Drop-in replacement for KDL's numerical IK in ROS/ROS2. Runs Jacobian + SQP in parallel; achieves 95-99% success rates where KDL reaches only 50-60% near limits.
- KDL (Orocos) — The default IK solver in ROS MoveIt. Jacobian pseudo-inverse with joint limit clamping. Simple but limited near singularities and joint limits.
- MoveIt 2 — The standard ROS2 motion planning framework. Supports pluggable IK solvers (KDL, TRAC-IK, IKFast, custom) and manages the full planning-to-execution pipeline.
- Drake (MIT/TRI) — High-performance C++ robotics library with optimization-based IK supporting arbitrary constraints. Particularly strong for whole-body control formulations.
- PyBullet / MuJoCo — Physics simulators that include built-in IK solvers suitable for simulation-based policy training and sim-to-real pipelines.
Comparison: Analytical vs Numerical IK
Analytical IK is preferred when available because it is orders of magnitude faster (microseconds vs. milliseconds), deterministic, and returns all solutions. However, it requires the kinematic structure to have the right geometry, and adding constraints (collision avoidance, joint-limit preferences) requires post-processing rather than integration into the solver. Numerical IK is general-purpose: it works for any kinematic chain and naturally incorporates arbitrary constraints, but it is iterative (may fail to converge), slower, and depends on the initial seed configuration. In practice, teams often use analytical IK for the primary solve and numerical methods for secondary objectives or when the analytical solver returns no valid solution.
IK and Modern Robot Learning
The rise of imitation learning and end-to-end policies has changed IK's role in the robotics stack. Policies like ACT and Diffusion Policy that operate in joint space bypass IK entirely — the neural network directly outputs joint angles from camera images. This avoids singularity issues and IK failure modes but sacrifices the geometric interpretability of Cartesian control.
However, IK remains essential for: (1) teleoperation systems that map human hand poses to robot joint angles for demonstration collection, (2) task-space policies that predict Cartesian waypoints and rely on IK for execution, (3) safety wrappers that verify Cartesian safety constraints before converting to joint commands, and (4) hybrid systems where a high-level planner outputs Cartesian goals and a low-level controller uses IK for execution.
Practical Requirements
Accuracy: For pick-and-place tasks, IK accuracy of 1-2mm position error and 1-2 degree orientation error is typically sufficient. For precision assembly (peg-in-hole, connector insertion), sub-millimeter accuracy is needed, often requiring force-feedback correction on top of IK.
Speed: Real-time control loops at 500-1000 Hz require IK solutions in under 1ms. Analytical solvers easily meet this. Numerical solvers like TRAC-IK typically converge in 0.5-5ms, which is sufficient for most manipulation but may be tight for high-frequency servo loops.
URDF model: All IK solvers require an accurate kinematic model of the robot, typically provided as a URDF (Unified Robot Description Format) file. Errors in link lengths, joint offsets, or DH parameters directly translate to end-effector positioning errors.
IK Configuration at SVRC
SVRC configures IK solvers for every robot in its fleet, optimized for each platform's kinematic structure and typical tasks:
- OpenArm 101 — Uses TRAC-IK with custom joint weight biases that favor elbow-up configurations for tabletop manipulation. The URDF has been kinematically calibrated to sub-millimeter accuracy using least-squares optimization against motion capture ground truth.
- DK1 — IKFast analytical solver generated from the DK1's spherical-wrist geometry, providing sub-5-microsecond solutions. Falls back to TRAC-IK for edge cases near joint limits.
- ALOHA bimanual — Dual TRAC-IK instances with coupled seed management that prevents left-right arm collisions. The IK configuration biases both arms toward outward-elbow postures to maximize shared workspace clearance.
- Unitree G1 — Optimization-based IK via Drake for whole-body inverse kinematics that jointly solves arm and torso joint angles while maintaining balance constraints.
All IK configurations are version-controlled and tested against reference pose datasets. Teams using SVRC hardware receive pre-tuned IK setups as part of the data services engagement.
See Also
- Data Services — Pre-configured IK solvers and kinematic calibration for SVRC robots
- Hardware Catalog — URDF models and kinematic specifications for all platforms
- Robot Leasing — Access OpenArm 101, DK1, and Unitree G1 with calibrated IK
- Data Platform — Teleoperation IK pipelines for demonstration collection
Key Papers
- Craig, J. (2005). Introduction to Robotics: Mechanics and Control. The standard textbook treatment of forward and inverse kinematics, Jacobians, and singularities.
- Beeson, P. & Ames, B. (2015). "TRAC-IK: An Open-Source Library for Improved Solving of Generic Inverse Kinematics." IEEE Humanoids 2015. Introduces the dual-solver approach that dramatically improves IK success rates.
- Diankov, R. (2010). "Automated Construction of Robotic Manipulation Programs." PhD Thesis, CMU. Introduces IKFast, the analytical IK generator used across the ROS ecosystem.
- Wampler, C. (1986). "Manipulator Inverse Kinematic Solutions Based on Vector Formulations and Damped Least-Squares Methods." IEEE Transactions on Systems, Man, and Cybernetics. Foundational work on DLS for robust numerical IK.
Related Terms
- Joint Space — The configuration space IK maps into
- Motion Planning — Finds collision-free paths that often rely on IK at each waypoint
- Workspace Analysis — Characterizes the set of reachable poses where IK has solutions
- Whole-Body Control — Extends IK to full-body optimization for humanoids and mobile manipulators
- Safety Constraints — Limits on joint velocities and workspace boundaries that constrain IK solutions
Apply This at SVRC
Silicon Valley Robotics Center uses IK solvers across its entire robot fleet — from ALOHA bimanual stations running TRAC-IK to industrial cells with IKFast-generated solvers. Our data services team handles kinematic calibration, URDF tuning, and IK solver selection so your manipulation pipelines work reliably from day one.