What can move

Counting and measuring mobility

Grübler's criterion counts links and joints and never asks how long anything is. The rank of the constraint Jacobian measures the lengths and never asks what a joint is. Two calculations with no inputs in common, producing one number — which is the only arrangement under which agreement is evidence.

Assumes What decides whether it moves.

There are two ways to find out how many degrees of freedom a mechanism has, and the interesting thing about them is how little they have in common.

One counts links and joints. It works on a sketch, needs no dimensions, and gives the same answer for every four-bar ever built regardless of the four lengths.

The other takes the constraint equations, differentiates them, and measures the rank of the resulting matrix. It needs every dimension, knows nothing about what a link is, and would give a different answer for a four-bar whose lengths happened to be degenerate.

Neither can be derived from the other, which is exactly why both are computed here.

Mobility, counted and measured. Grübler's criterion counts links and joints and knows nothing about the dimensions; the rank of the constraint Jacobian measures the dimensions and knows nothing about the topology. They agree for four of these five. The parallelogram with a redundant third bar is the exception: the formula declares it a structure with zero degrees of freedom, and it moves. The formula is the one that is wrong, because it cannot see that the third bar's constraint equations are already implied by the other two.
Fig. 1 Five mechanisms put through both routes. The triangulated frame, the four-bar, the slider-crank and Peaucellier’s cell all agree. The parallelogram with a redundant third bar does not — Grübler makes it a structure and the Jacobian makes it a mechanism — and it moves, which settles it.
Mobility, counted and measured. Grübler's criterion counts links and joints and knows nothing about the dimensions; the rank of the constraint Jacobian measures the dimensions and knows nothing about the topology. They agree for four of these five. The parallelogram with a redundant third bar is the exception: the formula declares it a structure with zero degrees of freedom, and it moves. The formula is the one that is wrong, because it cannot see that the third bar's constraint equations are already implied by the other two.
Fig. 2 The same two routes on a second set of lengths. Nothing about the arithmetic changes with the numbers, which is the point of running it twice: the count reads the topology and the rank reads the configuration, and they agree here for the same reason they agree above.

The counting route

Grübler’s criterion is M=3(n1)2j1j2M = 3(n-1) - 2j_1 - j_2: three freedoms per link, less three for bolting one to the frame, less two for every joint that permits one relative motion and one for every joint that permits two.

Its virtue is that it is a statement about topology. Change every length in a four-bar and the answer stays 1. That makes it the right tool at the point in a design where the dimensions do not exist yet, and it is why mechanism synthesis begins with it.

Its inputs, however, are not facts. They are modelling decisions, and the formula is silent about which decision is right.

How many links is a rigid coupler carrying three pins? One. Written as two distance constraints between three points it looks like two bars pinned together, and gives a different count. Both descriptions produce the same motion.

How many joints is a pin where three links meet? Two, not one. Three links pinned coaxially can rotate independently of each other, and the rule is that a joint connecting k links counts as k − 1. Missing this is the commonest arithmetic error in the subject.

What kind of joint is a roller in a slot? One-freedom if it rolls without slipping, two-freedom if it can also slide. The drawing is identical.

Because of all that, the topology on this site is declared by each mechanism rather than inferred from its constraint list. An earlier version inferred it, and gave a slider-crank −2 degrees of freedom — a number no mechanism has, produced by counting a slider block as no link at all.

The measuring route

The solve that positions a mechanism writes every constraint as an expression that must equal zero, and forms the matrix of partial derivatives of those expressions with respect to the free coordinates. That is the constraint Jacobian, and it is needed for Newton–Raphson whether or not anyone is interested in mobility.

Its rank is the number of linearly independent constraints — how many freedoms are genuinely removed, as opposed to how many equations were written. Mobility is then the number of free coordinates minus the rank.

For the four-bar: four free coordinates, three independent constraints once the input is replaced by the link it stands for, so mobility 1. The number came out of arithmetic on a matrix of derivatives, with nothing anywhere in the calculation that knows what a bar is.

The independence is the point. There is no path by which an error in the topology count could propagate into the rank measurement, or the reverse.

Where the two must be made to line up

One subtlety needs stating, because getting it wrong makes the comparison meaningless in a way that looks like a discovery.

The driving input is a constraint too — it pins the crank pin to a particular angle — so a mechanism with its input applied has mobility 0 by construction. To compare against Grübler, which describes the mechanism without its input, the driving constraint has to be removed.

Removing it is not the same as deleting it. A crank constraint fixes a joint’s position, which encodes the input angle and the link; deleting it removes the link as well. That gave a four-bar two degrees of freedom instead of one, and the disagreement looked exactly like Grübler being wrong when it was the measurement that was. The fix is to substitute the bar the crank stands for.

That kind of error is the reason to be suspicious of a disagreement before celebrating it.

Rank is a decision about zero

In exact arithmetic, rank is the number of nonzero pivots after elimination. In floating point nothing is exactly zero, so rank needs a threshold, and a threshold is a choice.

This site uses a relative one — scaled by the largest entry — and reports how close the decision was. The gap is the ratio between the smallest accepted pivot and the largest rejected one. A gap in the millions means the rank is unambiguous. A gap near one means the matrix is nearly singular and the answer depends on where the line was drawn.

The second case is not a numerical embarrassment to be tuned away. It is what a mechanism looks like at a singular configuration, and reporting the gap is how a figure can say whether it was near one rather than pretending the question does not arise.

The angles this crank cannot reach. A non-Grashof four-bar — non-Grashof (triple rocker) — asked for all 360 input angles. It assembled at 273 of them. The dial on the left marks the reachable arcs in green and the refused ones in red; the refusals are not a numerical failure but the mechanism's dead centres, where the crank and coupler line up and the linkage physically stops. Nothing about the four lengths had to be inspected to find them: the solver was asked, and declined.
Fig. 3 Singular configurations located by asking rather than by algebra: a non-Grashof four-bar was requested at all 360 input angles and assembled at 273. The red arcs are where the constraints cannot be satisfied — the dead centres — and no closed form for them was needed.

What each route can see

Laying it out plainly is the most useful thing in this essay.

Grübler Jacobian
needs dimensions no yes
needs the topology classified yes no
sees redundant constraints no yes
works before the design exists yes no
depends on a tolerance no yes
gives one answer for a whole family yes no

Neither column is better. The formula is the right tool early and the measurement is the right tool once there is something to measure, and the cases where they part company are the ones worth knowing about.

The disagreement, and what it means

There is exactly one row of the audit where the two differ, and the pattern generalises: Grübler is wrong precisely when a constraint is redundant because of the dimensions.

Three bars between two frames, all parallel and all the same length, is the standard example. Any two of them fix the motion completely; the third writes down constraint equations that are already implied. Grübler counts the third bar’s joints and subtracts for them, and arrives at zero. The Jacobian finds that its rows are linear combinations of rows already present, does not count them twice, and arrives at one.

Three parallel bars, and a formula that says this cannot moveFive links and six pin joints, so Grübler's criterion gives 3(5−1) − 2(6) = 0 and calls it a structure. The Jacobian has rank 5 against 6 free coordinates, so it measures one degree of freedom — and the sweep assembles 59 of 60 positions, which settles the matter. The third bar removes no freedom because its constraint is already implied by the other two, and a formula that counts joints cannot notice that they happen to be parallel. Mechanisms of exactly this kind carry drafting machines, anglepoise lamps and locomotive coupling rods, where the redundant bar is there for load sharing and for keeping the linkage out of its change point.the redundant oneGrübler: 3(5−1) − 2(6) = 0Jacobian: 6 − rank 5 = 1
Fig. 4 The mechanism in question, moving. Five links, six pins, Grübler zero — and 59 of 60 sampled input angles assemble. The single refusal is at the change point, where the parallelogram can flip to an anti-parallelogram and nothing in the geometry chooses.

The mechanisms in this family are not curiosities. They are common, useful, and built on purpose, and the redundancy is usually there for stiffness or for load sharing rather than by mistake.

What this does not settle

Mobility is a count, and a count is not a guarantee.

A mobility of one does not mean the mechanism can move from where it is. A non-Grashof four-bar has mobility 1 and cannot turn through a full revolution; it rocks between dead centres. Mobility is a statement about the constraints at a configuration, and the range of motion is a different question, answered by sweeping.

It does not mean the mechanism can be assembled at all. Four bars whose longest exceeds the sum of the other three has mobility 1 by the count and no configurations whatever. The solver’s answer to that is to refuse every position, which is the correct one.

It says nothing about how well the mechanism works. The transmission angle is where that question lives, and it depends on the dimensions in a way that mobility does not.

Three bars and four bars. On the left, two bars to a common point: three links, three joints, and Grübler gives 3(3−1) − 2(3) = 0. The Jacobian agrees — two free coordinates, rank 2, nothing left over — and the shape cannot change without a bar changing length. On the right, one more bar and one more joint gives mobility 1, and the whole of this site follows from that difference. The triangle is why bridges are triangulated and the quadrilateral is why machines are not.
Fig. 5 Where the whole distinction starts: three links and three joints on the left, four and four on the right. One bar apart, and it is the difference between a bridge and a machine.
Three parallel bars, and a formula that says this cannot moveFive links and six pin joints, so Grübler's criterion gives 3(5−1) − 2(6) = 0 and calls it a structure. The Jacobian has rank 5 against 6 free coordinates, so it measures one degree of freedom — and the sweep assembles 59 of 60 positions, which settles the matter. The third bar removes no freedom because its constraint is already implied by the other two, and a formula that counts joints cannot notice that they happen to be parallel. Mechanisms of exactly this kind carry drafting machines, anglepoise lamps and locomotive coupling rods, where the redundant bar is there for load sharing and for keeping the linkage out of its change point.the redundant oneGrübler: 3(5−1) − 2(6) = 0Jacobian: 6 − rank 5 = 1
Fig. 6 The disagreement at a different position of the same linkage. The count returns nought wherever it is asked; the rank returns one at every angle the mechanism actually reaches, which is what makes the rank a measurement and the count a prediction.

The general shape of the habit

Two independent routes to one number is not a technique specific to mobility. It is the pattern this whole site is built on, because it is the only arrangement in which agreement is evidence rather than repetition.

The same shape appears in Grashof’s condition predicted and then swept, in a gear’s ratio derived from the base radii and tested on the drawn flank, and in an epicyclic ratio computed two ways. In every case one route knows the formula and the other knows the object, and the interesting output is not the agreement but the occasional failure of it.

The joints the count has to be told about

Every mobility count begins by classifying the joints, and that classification is where most errors enter — before any arithmetic happens.

In the plane a pin removes two freedoms and a slide removes two, so the two are interchangeable as far as the count goes and completely different as far as the mechanism goes. A rolling contact without slipping removes two. A contact that can slip removes one. A pin-in-slot removes one.

The one-freedom-removed joints are the higher pairs, and the arithmetic treats them differently — which is why Grübler’s criterion has two terms rather than one, and why a cam-and-follower has to be counted as a higher pair unless the roller is modelled explicitly, in which case it becomes two lower pairs and an extra link and the count comes out the same.

That last equivalence is a good check on whether a count has been done honestly. The same physical mechanism modelled two ways must give the same mobility, and if it does not, one of the two models has a joint misclassified.

The trap is that classification is a modelling decision and not an observation. A gear mesh is a higher pair if the teeth are ignored and something else entirely if they are not. A pin with clearance is a pin at the accuracy of this analysis and two freedoms at the accuracy of a vibration analysis. What the count reports depends on what the counter decided the machine was, which the rank test does too — but the rank test at least reports its decision as a matrix that can be inspected.

Why the crank is substituted rather than removed

The count implemented here has a detail worth stating, because getting it wrong produced a wrong answer that looked plausible.

A crank in this library is a constraint that fixes both the length of a link and its angle: it drives the mechanism. For a mobility count the driving part must be set aside — mobility is the number of inputs the mechanism needs, so counting it with an input already applied answers a different question.

The first implementation removed the crank constraint entirely. That deleted the link as well as the drive, and a four-bar with one link missing reported two degrees of freedom, which is the right answer to the wrong mechanism.

The fix is to substitute a plain bar for the crank: keep the length constraint, drop the angle constraint. The link is still there, the drive is not, and the four-bar reports one.

That is the kind of error that is invisible in a count and visible in a figure, and this site had it the other way round — the figures were right and the count was wrong — which is why both routes exist. Two methods that agree are evidence; one method is a claim. The same reasoning caught a reversed velocity solution and a circular gear test, and it is the only habit on this site that has caught bugs in every subject it has been applied to.

When the count is the right tool

Most of this essay argues for the measured route, so it is worth stating plainly where counting wins, because it usually does.

Design sketching. Grübler’s criterion is arithmetic on two integers and can be done on a napkin. A proposed mechanism that counts to zero when one degree of freedom was wanted has a problem worth finding before any coordinates exist, and the count finds it in seconds.

Topology search. Enumerating candidate mechanisms — how many links, arranged how — is a combinatorial problem in which each candidate must be screened cheaply. The count screens; the rank test would require choosing dimensions for every candidate, which is the expensive part of the design.

Communication. “A four-bar has one degree of freedom” is a true and useful thing to say, and saying “the constraint Jacobian has rank seven at every configuration sampled, with a singular-value gap of six orders” is not an improvement for most purposes.

The count’s weakness is precisely bounded: it assumes the constraints are independent, which is true for a mechanism whose dimensions are in general position and often false for one whose dimensions were chosen. So the practical rule is to count first, and to measure when the mechanism has parallel links, equal lengths, symmetry or concurrency — that is, whenever the design has put dimensions in special position on purpose.

Measuring also answers questions the count cannot pose at all. Where does the mobility change? What direction is the extra freedom? Is this configuration near a singularity? Those are the questions that matter once a mechanism exists, and they are all readings of a Jacobian at a configuration rather than of a formula about a family.

One machine, two counts, one measurement. Grübler's criterion applied to the same stack twice. Call the rollers what they are — pins in slots, two freedoms each — and the count is 1 at every height, which is what the machine has. Draw them as slider blocks that cannot turn, which is how a slider is drawn in every textbook, and the count is −1: a structure, at every height, for a machine that is holding a car up. The right-hand column is the rank of the constraint Jacobian, which knows nothing about either drawing.
Fig. 7 The same two routes on a machine in every warehouse. A scissor lift’s mobility is 1, measured, at every stack height — and Grübler gives 1 or −1 for it depending on whether the roller under it is called a pin in a slot or a slider block. The formula is right; the description was wrong, which is a different failure from the one this essay is about.

The same two routes, one dimension up

The pairing of a formula with a measurement is not specific to the plane, and the expansion of this site put the same argument into space, where it behaves far worse.

Kutzbach’s criterion counts six freedoms per body and five constraints per revolute joint, so a single closed loop needs seven joints before it moves at all. The measurement is the rank of the loop’s screw system — the same matrix the spatial solver forms to take its Newton step, exactly as the Jacobian here is the same matrix the planar solve uses.

The two disagree for four of the five loops the spatial field examines, and three of those four are mechanisms in daily use. That is not a different situation from the one this essay describes; it is this situation with the special geometries that cause it made much easier to arrange. Parallel axes, intersecting axes and axes meeting a common perpendicular are all ways for constraints to repeat themselves, and space has room for all three where the plane has only the first.

There is a second refinement the same phase added, and it is about the input rather than the geometry. Grübler’s formula has a 2 in it for lower pairs and a 1 for higher pairs, and those coefficients are counts of equations rather than conventions — so miscounting a cam contact as a pin is an error in the description of the mechanism rather than in the mechanism, and it produces a wrong answer that the Jacobian is entirely unmoved by. Those are two different failure modes and this essay’s second route catches both, for different reasons.

What a count cannot see about a contact

There is one thing the count is silent about that neither the formula nor the rank measures, and a later field of this site is built on it.

A higher pair — a contact along a line rather than a pin — removes one of a planar body’s three freedoms, and that is the entry in the table. What the entry does not record is that a contact can only push. A pin transmits both ways; a tooth resting on a face does not, and every irreversible mechanism on this site gets its irreversibility from that one fact.

Given that the count can be wrong and the rank cannot, it is fair to ask what the count is still for, and the answer is a matter of when rather than of accuracy. The rank needs dimensions. It is computed from a Jacobian, a Jacobian is evaluated at a configuration, and a configuration needs lengths — so the rank is unavailable at exactly the stage where a designer has a topology and nothing else. The count needs no dimensions at all, which is its whole virtue: it reads a graph, and a graph exists before any length is chosen. So the two instruments belong to two stages rather than competing at one. The count is the instrument of type synthesis — enumerate chains, discard the ones whose arithmetic cannot give the wanted mobility, and hand a shortlist forward — and the rank is the instrument of analysis, available the moment dimensions exist and strictly better from then on. Read that way the count’s failures stop being embarrassing: it is answering a question at a stage where nothing else can answer anything, and the correct response to its answer is to check it later rather than to distrust it now.

What this makes readable

Essays that name this one as a prerequisite.

About the same objects

Not linked from either essay — found by the objects both name.

What links here

The 8 of 86 essays linking to this one that name the most of the same objects.

The objects this essay names

Each one links to every other essay that touches it.

ConstraintDegrees of freedomGrashof's conditionGrübler's criterionHigher pairJacobianMobilityRankRatioRedundancyTolerance