Changing Axes: Local to Global
A beam and the column under it meet at a corner and share a joint. Whatever that joint does, both members feel it — but the beam's "along itself" is the column's "across itself", so their two stiffness matrices are talking about different directions and cannot simply be added. Both have to be re-expressed in one set of axes first: the structure's global X and Y.
Rotating a member into global axes is one line — k = Tᵀ k̄ T — and it is the only place the geometry of a frame enters the stiffness of its members.
Direction cosines
A member from joint i at (xi, yi) to joint j at (xj, yj) needs two numbers to say which way it points:
with L = √[(xj − xi)² + (yj − yi)²]. Note what this does not need: trigonometry. The coordinates give c and s directly, and a program never has to compute an angle — which also means it never has to worry about which quadrant the angle is in.
| A beam, i to the left of j | c = 1, s = 0. Local axes and global axes agree, and the transformation does nothing. |
|---|---|
| A column, i at the base | c = 0, s = 1. Local "along" is global Y, local "across" is global X. |
| A brace up to the right at 30° | c = 0.866, s = 0.500. |
| The same member drawn j to i | c and s both change sign. The matrix that comes out is identical — a member does not care which end you called i. |
The transformation matrix
Displacements rotate like vectors. A joint displacement written in global axes, (uX, uY), seen from the member is
Rotations do not rotate at all: a rotation about z is the same number in either set of axes, since both share that axis. Stack that for the two ends and the 6×6 transformation is
| c | s | 0 | 0 | 0 | 0 |
| −s | c | 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 0 | 0 | 0 |
| 0 | 0 | 0 | c | s | 0 |
| 0 | 0 | 0 | −s | c | 0 |
| 0 | 0 | 0 | 0 | 0 | 1 |
Two 2×2 rotations and two 1s, and nothing else. So ū = T u converts global end displacements into local ones, and f̄ = T f does the same for end forces.
Why the answer is TᵀkT
The derivation is three substitutions and worth doing once, because it explains the transpose that everyone remembers and nobody can justify.
Start from what the member knows: f̄ = k̄ ū. Substitute the two conversions above:
Multiply from the left by T−1:
And T is orthogonal — its rows are unit vectors at right angles to each other, because that is what a rotation is — so T−1 = Tᵀ. Hence
The transpose is not a convention; it is the inverse of a rotation being its own transpose. It is also what keeps the global matrix symmetric: if k̄ is symmetric then so is Tᵀk̄T, for any T at all.
What comes out
Multiplied out, the global axial-only part of the member (a truss bar) is the familiar
| c² | cs | −c² | −cs |
| cs | s² | −cs | −s² |
| −c² | −cs | c² | cs |
| −cs | −s² | cs | s² |
Read the corner term: a bar at angle θ resists movement along global X with only EAcos²θ/L. A nearly vertical brace is nearly useless against horizontal load, which is the algebra agreeing with intuition. The full 6×6 frame version is the same operation with the bending terms carried through; it is dense rather than sparse, and there is no reason to write it out by hand — this is what the multiplication is for.
A worked rotation
A column, 4 m tall, from (0, 0) to (0, 4): c = 0, s = 1. Its axial stiffness EA/L, which acted along local x̄, now appears in the global Y rows; its sway stiffness 12EI/L³, which acted across the member, now appears in the global X rows. Nothing changed physically — the same column, the same numbers, described from a different direction. A frame is exactly this, done once per member.
Two practical notes
- The rotation runs both ways. After the structure is solved, the joint displacements come back in global axes and the member wants them local, so ū = T u is used again to recover member end forces. Both directions of the same matrix, no new work.
- Nothing here needs the load. The transformation depends only on geometry, so it is computed once per member and reused for every load case and every combination.
Next: the equations have room for loads at joints only. What happens to a uniformly distributed load sitting in the middle of a beam?