# Degrees of freedom (mechanics)
The **degrees of freedom** of a mechanical system is the number of independent parameters needed to fix its configuration completely: the count of numbers a designer must specify, and no fewer, before every point of the system has a definite position. A single point free to move in space has three degrees of freedom, one per coordinate axis; a [[Rigid_body|rigid body]] free in three-dimensional space has six, three of translation and three of rotation, while a rigid body confined to a plane has three, two of translation and one of rotation.[^dofcount] The same count governs everything mechanical that moves — a single hinge, a [[Robot_kinematics|robot arm]], or a whole [[Linkage_(mechanical)|linkage]] built from many rigid links pinned together — and it is the first question an engineer asks of any of them: not how it moves, but how many independent ways it can.
When several rigid links are connected by joints into a [[Kinematic_chain|kinematic chain]], the degrees of freedom of the whole assembly — its mobility — is not simply the sum of the parts, because every joint removes freedoms as fast as every added link supplies them. The framework microsim *Degrees of freedom: count the links and joints, get the motors* builds eight such planar mechanisms one at a time, from a single pinned link to a six-bar linkage, and counts the mobility of each with the Chebychev–Grübler–Kutzbach formula so the reader sees directly why a triangle of three pinned bars cannot move at all, a four-bar needs exactly one motor, and a five-bar needs two.
## Motion planning
Counting degrees of freedom is how a designer decides, before building anything, how many actuators a mechanism needs and how many independent commands a controller must issue. A point confined to a line has one degree of freedom and needs one number — a distance along the line — to fix its position; a point free on a plane needs two; a point free in space needs three.[^dofcount] A rigid body carries orientation as well as position, so a flat body sliding and turning on a plane, such as a car's chassis treated as a single rigid shape, has three degrees of freedom rather than two, and a body free in three-dimensional space has six: three coordinates for a reference point and three angles for its attitude.[^dof199] Wikitube's [[Configuration_space_(physics)|configuration space]] article develops the same count as the dimension of the space of every pose the body can take.
In robotics the count is the first design decision. A [[Serial_manipulator|serial manipulator]]'s joints each contribute one degree of freedom to its chain, so a chain of six revolute joints gives its end effector all six degrees of freedom a rigid body can have — three positions and three orientations — the minimum needed to place a tool at any reachable point in any attitude.[^dof194] Some manipulators carry a seventh joint precisely so the arm has one more freedom than its task needs; the extra freedom, called redundancy, lets the arm change its elbow's position without moving the tool at all, useful for reaching around an obstacle without losing the target. A [[Parallel_manipulator|parallel manipulator]] such as a Stewart platform reaches the same six freedoms a different way, closing several short chains onto one moving platform rather than extending a single long one — which is exactly why counting mobility correctly, the subject of the next section, matters as much for a closed chain as for an open one.
## Mechanical systems
A mechanism is a kinematic chain built to have exactly the mobility its job needs, and the number that says whether it has enough — or too much, or too little — comes from counting its links and joints, not from watching it move. Two ingredients decide the count: how many one-freedom or two-freedom joints, called [[Kinematic_pair|kinematic pairs]], connect the links, and how many independent loops those joints close.
### Kinematic pairs
A joint that lets its two links move relative to each other in exactly one way — turn about a shared axis, or slide along one — is a lower pair, and there are six of them: the [[Revolute_joint|revolute]] and the [[Prismatic_joint|prismatic]] pair each remove five of a free rigid body's six freedoms and leave one; the screw pair couples a turn to a proportional slide and likewise leaves one; the cylindrical pair leaves two, a turn and a slide along the same axis; the spherical pair, a ball joint, leaves three rotations; and the flat or planar pair leaves three, two slides and a turn.[^pairs199] A joint that leaves more than one freedom without falling into that six-member list — a gear tooth pressed against another, a cam against its follower, one part rolling on another — is a higher pair; higher pairs have no single standard classification of their own, only the shared property that each leaves more than one freedom.[^pairs200]
### The mobility formula
For a planar mechanism, one whose links all move in parallel planes, the mobility works out to
`M = 3(L − 1) − 2J − H`
where L counts the links, with the fixed frame itself counted as one of them; J counts the lower pairs, each of which removes two of a link's three planar freedoms; and H counts the higher pairs, each of which removes only one.[^mobform] The rule is the Chebychev–Grübler–Kutzbach criterion carried into the plane; a spatial mechanism replaces the leading 3 with 6 and adjusts each joint's freedom count for three dimensions instead of two. The sim's own on-screen readout labels the same two joint counts J1 (one-freedom pairs: pins and sliders) and J2 (two-freedom pairs: gear teeth, cam contact) rather than J and H, but the quantities and the formula they enter are identical to the ones above.[^linkspec2]
Three regimes follow directly from the sign of M. Three links pinned into a rigid triangle — the ground counted as one of the three — have L = 3 and J = 3, so M = 3(3 − 1) − 2(3) − 0 = 0: nothing can move, and the assembly is a structure rather than a mechanism. Add a fourth link and a fourth pin to open the triangle into a four-bar linkage and M rises to 3(4 − 1) − 2(4) − 0 = 1: exactly one motor, turning exactly one link, fixes the position of every other link in the loop — the case the [[Four-bar_linkage|four-bar linkage]] itself is built on. A five-bar mechanism, one link and one pin further still, needs two independent motors (M = 2) because a single input leaves the loop with one more freedom than it can resolve; a six-bar Watt linkage returns to M = 1 by hanging a second closed loop off a shared three-way link rather than opening the chain further. Removing freedom instead of adding it is just as informative: a single rigid bar pinned to the ground at both of its ends is over-constrained, with M = 3(2 − 1) − 2(2) − 0 = −1, a negative mobility that flags a redundant constraint rather than a mechanism with something left to drive.[^mobregime]
*Try: step the sim's mechanism selector from the locked triangle to the four-bar to the five-bar and watch the mobility readout climb from 0 to 1 to 2 as each added link and pin changes the count; then turn input 1 on the four-bar and watch its single gold crank fix the coupler and the rocker with no choice left to either one.*
## See also
- [[Chebychev–Grübler–Kutzbach_criterion]]
- [[Kinematic_pair]]
- [[Kinematic_chain]]
- [[Linkage_(mechanical)]]
- [[Configuration_space_(physics)]]
- [[Four-bar_linkage]]
- [[Robot_kinematics]]
## References
[^dofcount]: Standard rigid-body kinematics: a free point in three-dimensional space has three degrees of freedom and a free rigid body has six (three translations, three rotations); planar motion reduces these to two and three respectively. *Standard* (statics/dynamics textbook form; not page-pinned for this run).
[^dof199]: Jensen, David. *Introduction to Mechanical Design and Manufacturing* (2024). Portal Book 109, p. 199: a free rigid body in space has six degrees of freedom (three translations, three rotations); planar motion allows two translations and one rotation.
[^dof194]: Jensen, David. *Introduction to Mechanical Design and Manufacturing* (2024). Portal Book 109, p. 194: a robot arm may need "up to six" degrees of freedom to place its end effector arbitrarily.
[^pairs199]: Jensen, David. *Introduction to Mechanical Design and Manufacturing* (2024). Portal Book 109, p. 199: the six lower pairs — revolute, prismatic, screw, cylindrical, spherical, flat — and the freedoms each leaves.
[^pairs200]: Jensen, David. *Introduction to Mechanical Design and Manufacturing* (2024). Portal Book 109, p. 200: higher pairs (gear teeth, cam and follower, rolling contact) described as joints allowing more than one degree of freedom, with no equally standard classification of their own.
[^mobform]: Jensen, David. *Introduction to Mechanical Design and Manufacturing* (2024). Portal Book 109, pp. 200–201 ("12_design_mfg" sub-manual §2.1): mobility defined as the number of independent inputs needed to fix the configuration of every link, and the Chebychev–Grübler–Kutzbach formula M = 3(L − 1) − 2J − H read off the book's own worked four-bar example. The book's own equation graphic was lost in source-text extraction; the form above is recovered from that example and should be checked against the original PDF page before being quoted as the book's own typeset formula.
[^mobregime]: Jensen, David. *Introduction to Mechanical Design and Manufacturing* (2024). Portal Book 109, p. 201: the three regimes (M = 0 a structure, M = 1 driven by exactly one motor, M > 1 needing extra actuators or a forcing element such as a spring) and the worked four-bar (M = 1) and slider-crank (M = 1, p. 193) examples. The triangle, five-bar, six-bar Watt and over-constrained-bar figures are this article's own derivations from the same formula, checked against the sim's own mechanism list and code.
[^linkspec2]: Robotics portal sim spec `specs/sims/Degrees_of_freedom_(mechanics).json`, framework module `design.linkage`: `mobility(L, J1, J2)` computes the identical Chebychev–Grübler–Kutzbach count for each of the sim's eight mechanisms (single link, two-bar, locked triangle, four-bar, five-bar, slider-crank, six-bar Watt, and a bar over-constrained on two ground pins); poses come from `design.linkage.fourBar`, `design.linkage.sliderCrank` and `robot.kin.fkPlanar`. Nothing in the sim is ILLUSTRATIVE; link lengths are drawing choices and do not affect the count.
**Microsim — three.js (Wikitube framework):** *Degrees of freedom (mechanics)*
<!-- ROBSIM:Degrees_of_freedom_(mechanics) -->
*Built from `MICROSIM_GUIDE/specs/sims/Degrees_of_freedom_(mechanics).json`; part of the [[PORTAL_Robotics|Robotics portal]] spine (section ROB3, "Degrees of freedom and mobility"). Pending the robotics set's production deploy — see the portal's work list.*
## Wikipedia : Wikitube
**Strict pair:** [Wikipedia](https://en.wikipedia.org/wiki/Degrees_of_freedom_(mechanics)) : [Wikitube](https://en.wikitube.io/wiki/Degrees_of_freedom_(mechanics)) - skeleton pinned to revision 1373262301 (2026-09-23).
<!-- hub tags: GENERATIVE; Centers_of_Excellence; PORTAL_Robotics section ROB3 -->