Element Stiffness Matrix
The element stiffness matrix is the heart of FEA. It relates nodal forces to nodal displacements within a single element — essentially a multi-dimensional version of the spring equation $F = kx$.
In this lesson, we'll derive the stiffness matrix from first principles and build physical intuition for what each entry means.
The Spring Analogy
Before diving into matrices, let's recall the simple spring:
175+ hours of industry projects & 12 IIT faculty sessions
Master CATIA, NX, LS-DYNA, HyperMesh and more
$$F = k \cdot \delta$$
Where:
- $F$ = force applied to spring
- $k$ = spring stiffness (N/m)
- $\delta$ = displacement (extension)
A spring with higher $k$ requires more force to achieve the same displacement — it's "stiffer."
Srinithin now works at Xitadel as Design Engineer
Mechanical engineering graduate turned automotive designer
Two Springs in Series
For two springs connected end-to-end with a shared node:
| Node | Forces |
|---|---|
| Node 1 | $F_1 = k_1(u_1 - u_2)$ |
| Node 2 | $F_2 = k_1(u_2 - u_1) + k_2(u_2 - u_3)$ |
| Node 3 | $F_3 = k_2(u_3 - u_2)$ |
In matrix form:
$$\begin{bmatrix} F_1 \\ F_2 \\ F_3 \end{bmatrix} = \begin{bmatrix} k_1 & -k_1 & 0 \\ -k_1 & k_1+k_2 & -k_2 \\ 0 & -k_2 & k_2 \end{bmatrix} \begin{bmatrix} u_1 \\ u_2 \\ u_3 \end{bmatrix}$$
Ranjith switched from IT to core automotive industry
His inspiring career transition story with video
This is exactly what FEA does — but for continuous structures instead of discrete springs!
From Weak Form to Stiffness Matrix
Recall the weak form for a 1D bar:
$$\int_0^L EA\frac{du}{dx}\frac{dv}{dx} \, dx = \int_0^L v \cdot f \, dx + v(L) \cdot F_L$$
Now we apply the Galerkin method:
- Approximate $u(x) = \sum_j N_j(x) u_j$
- Choose $v(x) = N_i(x)$
Substituting:
$$\int_0^L EA \frac{d}{dx}\left(\sum_j N_j u_j\right) \frac{dN_i}{dx} \, dx = \int_0^L N_i \cdot f \, dx + N_i(L) \cdot F_L$$
Since $u_j$ are constants (nodal values), we can pull them out:
$$\sum_j \left[\int_0^L EA \frac{dN_j}{dx} \frac{dN_i}{dx} \, dx\right] u_j = \int_0^L N_i \cdot f \, dx + N_i(L) \cdot F_L$$
This is the matrix equation:
$$[K]\{u\} = \{F\}$$
Where:
$$K_{ij} = \int_0^L EA \frac{dN_i}{dx} \frac{dN_j}{dx} \, dx$$
Deriving [K] for a 2-Node Bar Element
Consider a bar element with:
- Length $L$
- Constant $EA$ (uniform cross-section and material)
- Nodes at $x = 0$ and $x = L$
Shape Functions
$$N_1(x) = 1 - \frac{x}{L}, \quad N_2(x) = \frac{x}{L}$$
Shape Function Derivatives
$$\frac{dN_1}{dx} = -\frac{1}{L}, \quad \frac{dN_2}{dx} = \frac{1}{L}$$
Computing Stiffness Entries
$K_{11}$:$$K_{11} = \int_0^L EA \left(-\frac{1}{L}\right)\left(-\frac{1}{L}\right) dx = \frac{EA}{L^2} \int_0^L dx = \frac{EA}{L^2} \cdot L = \frac{EA}{L}$$
$K_{12} = K_{21}$:$$K_{12} = \int_0^L EA \left(-\frac{1}{L}\right)\left(\frac{1}{L}\right) dx = -\frac{EA}{L^2} \cdot L = -\frac{EA}{L}$$
$K_{22}$:$$K_{22} = \int_0^L EA \left(\frac{1}{L}\right)\left(\frac{1}{L}\right) dx = \frac{EA}{L^2} \cdot L = \frac{EA}{L}$$
The Element Stiffness Matrix
$$[K_e] = \frac{EA}{L} \begin{bmatrix} 1 & -1 \\ -1 & 1 \end{bmatrix}$$
This is the element stiffness matrix for a 2-node bar element!
Physical Interpretation
Each entry $K_{ij}$ has a clear physical meaning:
$K_{ij}$ = Force at node $i$ due to unit displacement at node $j$ (with all other displacements = 0)
For the 2-node bar:
| Entry | Meaning |
|---|---|
| $K_{11} = +EA/L$ | Push node 1 right by 1 → Reaction force at node 1 pointing left |
| $K_{12} = -EA/L$ | Push node 2 right by 1 → Force at node 1 pointing right (bar pulls) |
| $K_{21} = -EA/L$ | Push node 1 right by 1 → Force at node 2 pointing right (bar pushes) |
| $K_{22} = +EA/L$ | Push node 2 right by 1 → Reaction force at node 2 pointing left |
Key Properties
- Symmetric: $K_{ij} = K_{ji}$ — Maxwell-Betti reciprocal theorem
- Positive diagonal: $K_{ii} > 0$ — Positive stiffness in direction of DOF
- Row/column sum = 0: Rigid body motion produces no internal forces
The General Formula
For any element, the stiffness matrix is: