Matrix Structural AnalysisIntroduction and contextMatrix structural analysis expresses the equilibrium, compatibility, and constitutive behavior of a structure in a systematic algebraic form. Instead of solving each member equilibrium equation independently, the method represents nodal displacements and forces as vectors and relates them through a global stiffness matrix. This makes it suitable for hand analysis of small structures and for computer-based analysis of large trusses, beams, and frames. The central relationship is [K]{u} = {P} where [K] is the assembled global stiffness matrix, {u} is the vector of unknown nodal displacements and rotations, and {P} is the vector of applied nodal loads and moments. The equation assumes linear elastic behavior, small displacements, idealized member connectivity, and correctly specified boundary conditions. Matrix methods are fundamental to structural-analysis software, finite-element procedures, building information modelling, and digital construction workflows. Their professional value lies not only in obtaining numerical results but also in making modelling assumptions explicit and providing a traceable route from loads to member forces. Learning objectivesAfter studying this chapter, the reader should be able to: - Explain degrees of freedom, stiffness, flexibility, equilibrium, and compatibility in matrix form.
- Formulate local stiffness matrices for axial truss members and bending members.
- Construct transformation matrices for members that are not aligned with global axes.
- Assemble a global stiffness matrix and global nodal load vector.
- Apply restraints and solve the reduced system of equations.
- Recover member deformations, end forces, reactions, and bending moments.
- Identify modelling errors, singular systems, and limitations of linear matrix analysis.
1. Fundamental concepts1.1 Degrees of freedom and coordinatesA degree of freedom (DOF) is an independent displacement component required to describe the structural configuration. A two-dimensional truss joint normally has two translational DOFs, ux and uy. A two-dimensional frame joint has three DOFs: horizontal translation u, vertical translation v, and rotation θ. A nodal displacement vector may therefore be written as {u} = [u₁, v₁, θ₁, u₂, v₂, θ₂, …]ᵀ The corresponding nodal force vector contains forces and moments in the same order: {P} = [H₁, V₁, M₁, H₂, V₂, M₂, …]ᵀ The ordering must remain consistent throughout formulation, assembly, solution, and force recovery. 1.2 Stiffness and flexibilityStiffness measures the force required to produce a unit displacement while all other relevant displacements are held according to the model. For a single spring, P = ku where P is force, u is displacement, and k is stiffness with units of force per length. The matrix equivalent is {P} = [K]{u}. The flexibility matrix [F], when it exists, satisfies {u} = [F]{P} and is the inverse of [K]: [F] = [K]-1. In large structural systems, stiffness formulation is generally preferred because compatibility and restraints are handled directly. 1.3 Equilibrium, compatibility, and constitutive behaviorMatrix structural analysis combines three requirements: - Equilibrium: applied loads and internal member forces balance at every node.
- Compatibility: connected members share compatible nodal displacements.
- Constitutive behavior: member forces are related to deformations through material and section properties.
For a prismatic, linearly elastic axial member, the constitutive relation is based on N = AEΔ/L, where N is axial force, A is area, E is Young’s modulus, Δ is axial extension, and L is member length. The units are consistent when E is force per area, A is area, and L and Δ are lengths. 2. Local stiffness matricesA local coordinate system is attached to each member. The local x-axis normally follows the member from its near end i to its far end j. Local matrices are derived from member behavior before the member is positioned in the global structure. 2.1 Two-dimensional truss memberA truss member carries axial force only. Its local displacement vector is {uˡ} = [uᵢˡ, uⱼˡ]ᵀ and its local force vector is {pˡ} = [Nᵢ, Nⱼ]ᵀ. The local stiffness matrix is [kˡ] = (AE/L) [ 1 -1 -1 1 ] The matrix is symmetric. Its rows and columns correspond to the local axial displacements at ends i and j. The member force is N = (AE/L)(uⱼˡ − uᵢˡ) with tension taken as positive under the stated displacement convention. 2.2 Two-dimensional beam elementFor a beam element whose local axis is horizontal, the nodal DOFs are vertical displacement and rotation at each end: {uˡ} = [vᵢ, θᵢ, vⱼ, θⱼ]ᵀ For constant E and I, Euler–Bernoulli beam theory gives [kˡ] = (EI/L³) [ 12 6L -12 6L 6L 4L² -6L 2L² -12 -6L 12 -6L 6L 2L² -6L 4L² ] Here I is the second moment of area. The element neglects shear deformation and is appropriate when the beam is sufficiently slender. A Timoshenko formulation is preferable for deep beams or members where shear flexibility is significant. The local end-force vector is {pˡ} = [Vᵢ, Mᵢ, Vⱼ, Mⱼ]ᵀ = [kˡ]{uˡ} when no member-distributed loading has been converted to equivalent nodal loads. Sign conventions for shear and moment must be declared because different texts use different positive directions. 2.3 Two-dimensional frame elementA planar frame element combines axial and flexural behavior. Its local DOF vector is {uˡ} = [uᵢ, vᵢ, θᵢ, uⱼ, vⱼ, θⱼ]ᵀ The local stiffness matrix is [kˡ] = [ AE/L 0 0 -AE/L 0 0 0 12EI/L³ 6EI/L² 0 -12EI/L³ 6EI/L² 0 6EI/L² 4EI/L 0 -6EI/L² 2EI/L -AE/L 0 0 AE/L 0 0 0 -12EI/L³ -6EI/L² 0 12EI/L³ -6EI/L² 0 6EI/L² 2EI/L 0 -6EI/L² 4EI/L ] This is valid for a prismatic, linearly elastic Euler–Bernoulli member undergoing small planar displacements. Coupling terms arise because nodal rotations and translations produce bending, while axial translations produce axial force. 3. Coordinate transformationLocal element matrices must be transformed when the member is inclined relative to the global axes. Let c = cos θ = (xⱼ − xᵢ)/L, s = sin θ = (yⱼ − yᵢ)/L where θ is the member angle measured counter-clockwise from the global x-axis, and L = √((xⱼ−xᵢ)² + (yⱼ−yᵢ)²). For a two-dimensional truss, the local-to-global displacement relationship is {uˡ} = [T]{uᵍ} with [T] = [ c s 0 0 0 0 c s ] when the global element displacement vector is {uᵍ} = [uᵢ, vᵢ, uⱼ, vⱼ]ᵀ. The transformed global element stiffness matrix is [kᵍ] = [T]ᵀ[kˡ][T] which expands to [kᵍ] = (AE/L) [ c² cs -c² -cs cs s² -cs -s² -c² -cs c² cs -cs -s² cs s² ] The dimensions are force per length, as required for a translational stiffness matrix. For a two-dimensional frame, the transformation matrix is commonly written as [T] = [ 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 ] The first two rows transform global translations into local axial and transverse translations; rotations about the perpendicular axis are unchanged in a planar model. The same congruence transformation, [kᵍ] = [T]ᵀ[kˡ][T], applies. 4. Assembly of the global systemEach element has an element connectivity list identifying where its local DOFs appear in the global DOF vector. For example, a frame element connecting nodes i and j may map its six local DOFs to global positions [3i−2, 3i−1, 3i, 3j−2, 3j−1, 3j]. Assembly adds each element stiffness coefficient to the corresponding global positions: Kᵍab = ∑ₑ kᵍab(e) where the summation includes all elements contributing to global DOF positions a and b. Assembly is additive because several members can resist a displacement at the same node. The global load vector includes applied nodal forces and moments. Member loads must be converted into equivalent consistent nodal loads. If a load is applied directly between nodes but is omitted from the nodal vector, the analysis will not represent the actual loading. For a uniform transverse load w on a beam element of length L, one common local fixed-end load vector, using a particular sign convention, is proportional to wL/2 at each shear component and wL²/12 at each end moment. The exact signs depend on the selected positive shear, moment, and load directions. Therefore, load-vector signs must be derived consistently from virtual work or a declared element convention rather than copied without checking. 5. Boundary conditions and solutionA structure is stable only when sufficient independent restraints prevent rigid-body motion and the stiffness matrix is nonsingular after boundary conditions are applied. Partition the DOFs into restrained r and free f sets: [ Kff Kfr ] [ uf ] = [ Pf ] [ Krf Krr ] [ ur ] [ Pr ] If prescribed restrained displacements are zero, {ur} = {0}, the equations for unknown displacements reduce to [Kff]{uf} = {Pf} After solving for {uf}, reactions at restrained DOFs are recovered from {Rr} = [Krf]{uf} − {Pr} for zero prescribed displacements. More generally, when {ur} is nonzero, {Pr} = [Krf]{uf} + [Krr]{ur} subject to the adopted sign convention. A practical solution should use a reliable linear solver such as Cholesky factorization for a symmetric positive-definite reduced matrix, or an appropriate pivoted solver when the matrix is not positive definite. Directly computing [K]-1 is generally inefficient and can amplify numerical error; solving the equations is preferred. 6. Worked example: inclined two-dimensional truss memberConsider a steel truss member connecting node i at (0, 0) m to node j at (3, 4) m. Let A = 600 mm², E = 200 GPa, and use global displacements {uᵍ} = [0.001, 0.002, 0, 0]ᵀ m The member length is L = 5 m, with c = 3/5 = 0.6 and s = 4/5 = 0.8. Convert the area: A = 600 × 10⁻⁶ m². Thus AE/L = (200 × 10⁹)(600 × 10⁻⁶)/5 = 24 × 10⁶ N/m The local axial displacements are uᵢˡ = cuᵢ + svᵢ = (0.6)(0.001) + (0.8)(0.002) = 0.0022 m and uⱼˡ = 0. Therefore, N = (AE/L)(uⱼˡ − uᵢˡ) = (24 × 10⁶)(−0.0022) = −52.8 kN The negative sign indicates compression under the stated tension-positive convention. The example illustrates that a global displacement does not directly equal the member extension; only its projection along the member axis contributes to axial deformation. 7. Worked example: one-dimensional spring assemblyAlthough simple, a spring system demonstrates assembly clearly. Two springs connect three nodes in a line. Spring 1 connects nodes 1 and 2 with stiffness k₁, and spring 2 connects nodes 2 and 3 with stiffness k₂. Each spring contributes [ke] = [ kₑ −kₑ −kₑ kₑ ] For global DOF order [u₁, u₂, u₃], assembly gives [K] = [ k₁ −k₁ 0 −k₁ k₁+k₂ −k₂ 0 −k₂ k₂ ] If node 1 is fixed, node 3 carries a known force, and node 2 is free, the fixed DOF is removed or prescribed before solving. The middle diagonal term k₁ + k₂ demonstrates that stiffness contributions from all connected elements accumulate at a node. 8. Member-force recoverySolving for nodal displacements is not the final engineering result. For each element: - Extract its global nodal displacement vector from the complete solution.
- Transform it to local coordinates: {uˡ} = [T]{uᵍ}.
- Calculate local end forces: {pˡ} = [kˡ]{uˡ} − {p⁰}, where {p⁰} represents equivalent effects of member loads under the adopted sign convention.
- Interpret axial forces, shears, and moments using the declared signs.
For a truss member, the axial force is sufficient for design checks. For a frame member, end forces may be used to construct shear-force and bending-moment diagrams. Internal force diagrams must also include distributed loads acting between nodes; nodal end forces alone do not replace the complete member diagram. Equilibrium provides an important verification. At every free node, the sum of applied and member forces should be approximately zero. Small discrepancies may arise from rounding, but substantial imbalance indicates a formulation, sign, connectivity, or coding error. 9. Illustrative case: matrix analysis of a small portal frameBackgroundThis illustrative case concerns a single-storey steel portal frame with two columns and a beam. The frame is modelled as three planar frame elements connected at rigid joints. The bases are fixed, and a horizontal service load is applied at the beam level. ProblemThe engineer must determine lateral displacement, support reactions, and member end moments. The frame has different axial and flexural stiffnesses in the columns and beam, so hand superposition is inconvenient. Analysis and approachEach joint is assigned three DOFs: horizontal translation, vertical translation, and rotation. For each member, the 6 × 6 local frame matrix is formed using its A, E, I, and L. Member orientations determine c and s. The transformed matrices are assembled into the global matrix according to the joint connectivity. The six base DOFs are restrained. The lateral load and any gravity loads are placed in the global nodal load vector. The reduced system is solved for the free joint translations and rotations. Member forces are then recovered in local axes, and the reactions are calculated from the restrained rows of the original global system. Outcome and engineering interpretationThe lateral displacement identifies serviceability performance, while column and beam end moments identify critical design actions. If the reduced matrix is singular, likely causes include an unrestrained rigid-body mode, a disconnected member, or an incorrect DOF map. If the frame is excessively flexible, the engineer should check member properties, releases, units, and whether second-order effects are important. Learning pointsThe case demonstrates that matrix analysis is a modelling process, not merely a matrix calculation. Accurate geometry, connectivity, material properties, loading, releases, restraints, and sign conventions are all necessary. Results should be checked against global equilibrium, expected deformation patterns, and approximate engineering calculations. 10. Modelling assumptions and limitationsThe basic formulations in this chapter generally assume: - linear elastic material behavior;
- small displacements and rotations;
- idealized joints and member centerlines;
- prismatic members unless properties are varied by formulation;
- Euler–Bernoulli bending, with negligible shear deformation;
- loads represented accurately by nodal or consistent equivalent loads;
- valid support conditions and no unintended mechanisms.
For steel or reinforced-concrete structures approaching yielding, stiffness degradation, cracking, plastic hinges, contact, geometric nonlinearity, or buckling, a linear analysis may be inadequate. Geometric stiffness matrices and iterative nonlinear procedures may then be required. Construction-stage analysis may also require changing stiffness, supports, and loads over time rather than applying all actions to the completed structure. 11. Digital implementation and professional practiceA robust implementation stores nodes, elements, properties, restraints, loads, and DOF maps as separate data structures. The essential computational sequence is: - Read and validate geometry and properties.
- Number global DOFs.
- Create each local stiffness matrix.
- Create the transformation matrix.
- Transform and assemble the element matrix.
- Assemble nodal and equivalent member-load vectors.
- Apply restraints and prescribed displacements.
- Solve the reduced equations.
- Recover reactions and member forces.
- Report results and perform equilibrium and plausibility checks.
Automated tools and AI-assisted coding can help generate input files, detect unusual results, or compare alternative models. They cannot replace engineering judgement about idealization, load paths, code requirements, or whether an output is physically credible. A professionally responsible workflow retains model versioning, units, assumptions, solver settings, and review records. Common best practices include using one internally consistent unit system, checking matrix symmetry, reporting condition numbers or warnings for ill-conditioning, testing a simple benchmark problem, and independently checking reactions and key member forces. A model that produces numerical results is not necessarily a valid structural model. Chapter SummaryMatrix structural analysis represents structural behavior through the relationship [K]{u} = {P}. Local stiffness matrices describe axial, bending, or combined frame behavior. Transformation matrices transfer local member behavior to global coordinates, while assembly combines all element contributions at shared global DOFs. Boundary conditions remove or prescribe restrained displacements, allowing the free displacement vector to be solved. Reactions and member forces are recovered afterward from the original system and local element equations. The method depends on equilibrium, compatibility, constitutive behavior, correct units, reliable connectivity, and realistic assumptions. It is especially powerful for computer-based analysis of trusses, beams, and frames, but results must be verified through equilibrium, deformation patterns, and engineering judgement. Nonlinear behavior, shear deformation, instability, and construction-stage effects require more advanced formulations. Key TermsDegree of freedom: An independent displacement or rotation used to describe a structural configuration. Global coordinate system: The common reference system used for the complete structure. Local coordinate system: A coordinate system attached to an individual member. Stiffness: Force or moment required per unit displacement or rotation. Flexibility: Displacement or rotation produced per unit force or moment. Local stiffness matrix: Matrix relating member-end forces to member-end deformations in local axes. Global stiffness matrix: Matrix relating all structural nodal forces to all structural nodal displacements. Transformation matrix: Matrix that converts local element quantities to or from global coordinates. Assembly: Addition of element matrices and vectors into the global system. Connectivity: Identification of the nodes and global DOFs associated with an element. Nodal load vector: Vector of externally applied forces and moments at structural nodes. Equivalent nodal load: Nodal representation of a load applied along a member. Boundary condition: A prescribed displacement, rotation, force, or support restraint. Reaction: Force or moment developed at a restrained DOF. Rigid-body mode: Motion that occurs without member deformation and produces a singular stiffness system. Member-force recovery: Calculation of local axial forces, shears, and moments from solved displacements. Euler–Bernoulli beam theory: Beam theory that neglects transverse shear deformation. Singular matrix: A matrix that cannot be uniquely inverted, often indicating instability or inadequate restraints. Consistent units: A unit system in which all dimensions in the governing equations are compatible. Review QuestionsShort Answer Questions- What is a degree of freedom in matrix structural analysis?
- Why must a member stiffness matrix be transformed for an inclined element?
- State the global stiffness relationship used in linear analysis.
- What physical condition is commonly indicated by a singular reduced stiffness matrix?
- Why are member forces recovered in local coordinates?
Long Answer Questions- Explain how equilibrium, compatibility, and constitutive behavior are combined in the stiffness method.
- Derive the two-dimensional truss member stiffness matrix in local coordinates and explain each term.
- Describe the assembly process from element matrices to the global stiffness matrix.
- Explain how boundary conditions are applied and how support reactions are recovered.
- Compare the assumptions and applications of Euler–Bernoulli beam and planar frame elements.
Analytical / Application Questions- A truss member has length 4 m, area 400 mm², and E = 200 GPa. Its axial extension is 1.5 mm. Calculate the axial force and identify whether it is tensile or compressive.
- A two-dimensional frame model produces a singular reduced matrix. Develop a systematic diagnostic procedure using geometry, restraints, connectivity, releases, and units.
- Design a matrix-analysis workflow for a portal frame carrying gravity and lateral loads. Specify the data required, the solution sequence, and at least four independent validation checks.
Multiple Choice Questions with AnswersQuestion 1In the linear stiffness equation [K]{u} = {P}, what does {u} represent? A. The vector of nodal displacements and rotations B. The vector of member stresses C. The vector of support reactions only D. The vector of material properties Correct Answer: A. The vector of nodal displacements and rotations Question 2For a two-dimensional truss member, which behavior is represented by the local stiffness matrix? A. Axial deformation only B. Torsional deformation only C. Shear deformation only D. Plastic hinge rotation only Correct Answer: A. Axial deformation only Question 3The transformed element stiffness matrix is obtained from which expression? A. [kᵍ] = [T][kˡ]| B. [kᵍ] = [T]ᵀ[kˡ][T] C. [kᵍ] = [kˡ][T]ᵀ[T] D. [kᵍ] = [T]-1[kˡ] Correct Answer: B. [kᵍ] = [T]ᵀ[kˡ][T] Question 4For a truss member from (0, 0) to (3, 4), what is the direction cosine c? A. 0.4 B. 0.6 C. 0.75 D. 0.8 Correct Answer: B. 0.6 Question 5Which quantity is normally added to the global stiffness matrix during assembly? A. Each element's transformed stiffness contribution B. Only the largest element stiffness C. Only support reactions D. The inverse of each element matrix Correct Answer: A. Each element's transformed stiffness contribution Question 6A singular reduced stiffness matrix most commonly suggests which problem? A. The structure has an unrestrained mechanism or rigid-body mode B. The material modulus is always too large C. The load vector contains no entries D. All element matrices are necessarily asymmetric Correct Answer: A. The structure has an unrestrained mechanism or rigid-body mode Question 7For a two-dimensional frame node, how many usual degrees of freedom are assigned? A. One B. Two C. Three D. Six Correct Answer: C. Three Question 8For a truss member with A = 600 mm², E = 200 GPa, L = 5 m, what is AE/L? A. 2.4 kN/m B. 24 kN/m C. 2.4 MN/m D. 24 MN/m Correct Answer: D. 24 MN/m Question 9After solving nodal displacements, what is the correct first step in recovering a member's local forces? A. Delete the restrained DOFs from the member B. Extract the member's global displacement vector and transform it locally C. Invert the global load vector D. Replace the member length with its area Correct Answer: B. Extract the member's global displacement vector and transform it locally Question 10Which theory neglects transverse shear deformation in the beam element presented? A. Timoshenko beam theory B. Euler–Bernoulli beam theory C. Plastic-flow theory D. Rigid-body theory Correct Answer: B. Euler–Bernoulli beam theory
|