Professional Documents
Culture Documents
Truss Analysis: The Stiffness Method
Truss Analysis: The Stiffness Method
Truss Analysis: The Stiffness Method
Dorian Depriester1
1
MSMP laboratory (EA 7350), École Nationale Supérieure d’Arts et
Métiers, 2 cours des Arts et Métiers, 13617 Aix-en-Provence, France
November 1, 2020
uA = A A
uB = B B
The length of the beam in its deformed state, denoted ` below, is just the Euclidean
distance from A to B. It comes:
`2 = kABk2
= kAA + A B + B Bk2
= k`0 k + uB − uA k2
1
ey uB
B0
FB
`0
FA
k
uA ex
A0
Figure 1: Representation of slender beam with ends at A0 and B0 in its reference state
(no load).
where `0 is the initial length of the beam and k is the unit orientation vector of the
beam. The law of cosine gives:
Let ∆` be the length variation of the beam, so that ∆` = ` − `0 . Eq. (1) leads to:
q
∆` = `20 + kuB − uA k2 + 2`0 k · (uB − uA ) − `0 (2)
s
2
kuB − uA k k · (uB − uA )
= `0 1 + +2 − 1 (3)
`0 `0
Under the small strain assumption, it is assumed that all the displacements are small
compared to the characteristic lengths of the problem. Thus:
kuB − uA k
1
`0
Under this assumption, (3) can be linearised using the Taylor’s expansion of the square
root function1 , that is:
s
kuB − uA k 2
k · (uB − uA ) k · (uB − uA )
1+ +2 ≈1+
`0 `0 `0
leading to:
∆` ≈ k · (uB − uA ) (4)
1
√ x
As a reminder: 1+x=1+ 2
+ ox→0 (x).
2
Let uAx , uAy , uBx , and uBy be the components of uA and uB in a given basis (ex , ey ),
so that:
uA = uAx ex + uAy ey
uB = uBx ex + uBy ey
k = kx ex + ky ey
FA = −FB = −T k (7)
Let FAx , FAy , FBx , and FBy be the components of FA and FB so that:
FBy uBy
3
where K e is the so-called elementary stiffness matrix, defined as follows:
2
−kx2 −kx ky
kx kx ky
ES kx ky ky2 −kx ky −ky2
Ke = 2
(9)
`0 −kx −kx ky kx2 kx ky
−kx ky −ky2 kx ky ky2
2 Stiffness of a truss
In the context of the nodal method, a truss is considered as an assembly of slender
beams. If the truss is composed of n nodes, the 2D problem has 2n degrees of freedom
(dof). In this case, the overall stiffness matrix is of size 2n × 2n. According to the
superposition principle, it can be assumed that the overall stiffness matrix is just the
sum of all elementary stiffness matrices. Nevertheless, those elementary matrices must
be written in a global reference frame and a special attention should be paid about the
indices of each component of the matrix, with respect to the pattern used for numbering
the nodes.
2.1 Example
As an example, consider the truss composed of three beams with equal length `, as
illustrated in Figure 2. The elementary stiffness matrices of beams AB, AC and BC
2
That is: (u ⊗ v)ij = ui vj .
4
C
` `
A ` B
can be computed from (9), taking into account their respective orientations, that is:
1 0 −1 0
ES 0 0 0 0
KAB = (11a)
` −1 0 1 0
0 0 0 0
√ √
−1
√ − 3
√1 3
ES 1 3 3
√ − 3 √ −3
KAC = (11b)
` 4 −1
√ − 3 √1 3
− 3 −3 3 3
√ √
− 3 √ −1
√1 3
ES 1 − 3 √3 3 −3
√
KBC = (11c)
` 4 √ −1 3 1
√ − 3
3 −3 − 3 3
All those matrices can be assembled, taking into account their connectivity (i.e. to which
nodes each beam is connected), leading to the following matrix system:
FAx uAx
FAy uAy
FBx uBx
FBy = K uBy
FCx uCx
FCy uCy
with: √ √
−1 − 3
1 +√14 0 + 43 −1 0 4
√ 4
− 3 −3
0 + 43 0 + 43 0 0√
4 √4
1 +√14 0 − 43 1 3
−1
ES 0 −
K= √4 4
−3
`
0 0√ 0 − 43 + 34
0√ 4
3
√ 4 √
−1 − 3 −1 3 1 1 3 3
+ 4 − 4
4 4 √4 4 √4 4
√ √
3 −3 3 −3 3 3 3 3
− 4 4 4 4 4 − 4 4 + 4
5
For the sake of clarity, all the components of K in the previous equation are coloured
with respect to the colours of elements in Figure 2 and those of the elementary matrices
(11c) as well, evidencing the “superposition” of stiffness contributions. As a conclusion,
the stiffness matrix of the truss presented in Figure 2 is:
√ √
−1 − 3
3
5
4 4 −1 0 4 4
√3 3
√
− 3 −3
4 4 0 0
√ 4 √4
−
−1 5 3 −1 3
ES 4
0 4
√ 4 √4 4
K= − 3 3 3 −3
` 0
0√ 4 4 4 4
−1 − 3 −1 √
3 1
4
√ 4 √4 4 2 0
− 3 −3 3 −3 3
4 4 4 4 0 2
2.2 Programming
In 2D, the x component of the i-th node is written at the (2i − 1) -th row of the overall
stiffness matrix whereas the y component is written at the 2i -th row. Algorithm 1 gives
the pseudo-code one can use for computing the stiffness matrix of a truss, given the
coordinates of the nodes and the list of beams (where each beam is defined as a pair of
node indices).
3 3D trusses
All the considerations above slightly change if the truss is 3D (i.e. if the nodes coordinates
are defined in 3D). Indeed, in the orthogonal basis (ex , ey , ez ), Eq. (10) for the elementary
stiffness still applies with:
kx
ky
kz
t=
−kx
−ky
−kz
and
k = kx ex + ky ey + kz ez
In a 3D truss with n nodes, the problem has 3n dof. Thus, the x component of the i-th
node is written at the (3i − 2) -th row of the overall stiffness matrix, the y component
is written at the (3i − 1) -th row and the z component is written at the 3i -th row.
4 Conclusion
In this paper, the mechanical behaviour of a single beam, subjected to tensile load only
along its axis, has been formalized as a matrix system involving the nodal displacements
of the beam and the applied forces at those nodes. This elementary system has been
6
Algorithm 1 Pseudo-code for computing the stiffness matrix of a truss. Ei and Si
denote the Young’s modulus and the cross section of the i-th beam, respectively.
dof ← 2 × Number of nodes
P ← List of nodes coordinates
K ← dof × dof matrix of zeros . Initialize the stiffness matrix
for i = 1, ..., nbr. of beams do
[p, q] ← beami . The i-th beam is between the p and q -th nodes
A ← Pp
B ← Pq
` ← kABk
k ← AB/`
t
t ← kx ky −kx −ky
K e ← Ei`Si t ⊗ t . Elementary stiffness matrix
for j = 1, ..., 4 do . Loop over the rows of K e
if j ≤ 2 then
r ← 2p − 2 + j . j relates to A
else
r ← 2q − 2 + j . j relates to B
end if
for k = 1, ..., 4 do . Loop over the columns of K e
if k ≤ 2 then
s ← 2p − 2 + k . k relates to A
else
s ← 2q − 2 + k . k relates to B
end if
Krs ← Krs + Kjk e . Increment K
end for
end for
end for
7
used to model the mechanical behaviour of trusses, that is systems composed of multiple
beams. Finally, an algorithm has been proposed to numerically compute the stiffness
matrices of trusses.