Saved

Press the star next to a tool's name to save it.

All my tools

Stiffness Matrix Calculator

Use this stiffness matrix calculator to build the element stiffness matrix of a bar, truss or beam element from E, the length, the area or I, and the angle.

Restored your last values ·

GPa
m
m²
°
m⁴

Choose a bar or truss element or a beam element. Enter Young's modulus, the length and the area (bar) or second moment of area (beam). For a bar you can add its angle. You get the element stiffness matrix.

Everything is worked out in your browser. Nothing you type is sent anywhere.

–

–

Choose the element type and fill in the boxes, then press Calculate.

See full result

A stiffness matrix calculator builds the element stiffness matrix used in the direct stiffness method and in finite element analysis. Choose a bar or truss element, or a beam element, enter the material and the section, and it returns the matrix that links the end forces to the end movements.

How to use the stiffness matrix calculator

  1. Choose a bar or truss or a beam element.
  2. Enter Young's modulus and the length.
  3. Enter the area and the angle (bar) or the second moment of area (beam).
  4. Press Calculate.

What an element stiffness matrix is

An element stiffness matrix links the forces at the ends of a structural element to the movements of those ends. Each entry is the force needed at one degree of freedom to produce a unit movement at another. The direct stiffness method on Wikipedia assembles such matrices for all the elements of a structure, then adds the support conditions to solve for the movements [1]. This tool builds the matrix for one element at a time.

The bar element

For a bar carrying only axial force, the axial stiffness is k = EA ÷ L, with E Young's modulus, A the cross-section area and L the length [2]. For example, a 1 m steel bar of 0.2 m² with E = 200 GPa has k = 4 × 10¹⁰ N/m. The tool shows this value first, and you can enter the same numbers to check it.

The truss element in global axes

A truss member inclined at an angle φ to the global x-axis has a 4 by 4 matrix: EA ÷ L times a pattern of c², cs and s², with c = cos φ and s = sin φ, for the movements x₁, y₁, x₂ and y₂ [1]. Wikipedia writes it with the same terms and defines s and c this way [1]. The tool prints each row, and entries that are zero by symmetry, such as at 90 degrees, are shown as 0.

A truss example

For the 4 × 10¹⁰ N/m bar at 30 degrees, c = 0.866 and s = 0.5. The first row is 3 × 10¹⁰, 1.7321 × 10¹⁰, −3 × 10¹⁰ and −1.7321 × 10¹⁰ N/m, and the second row begins 1.7321 × 10¹⁰ and 1 × 10¹⁰. This is a worked example of the formula above. The matrix is symmetric, as every element stiffness matrix is.

The beam element

A beam element with constant E and I has a 4 by 4 matrix for the degrees of freedom deflection u₁, rotation θ₁, deflection u₂ and rotation θ₂. Its entries are 12EI ÷ L³, 6EI ÷ L², 4EI ÷ L and 2EI ÷ L with the signs shown in the IISc lecture notes [3]. Wikipedia gives only a generic frame matrix without these terms [1].

A beam example

Take E = 200 GPa, I = 1 × 10⁻⁴ m⁴ and L = 2 m. Then EI = 2 × 10⁷ N·m², so 12EI ÷ L³ = 3 × 10⁷ N/m, 6EI ÷ L² = 3 × 10⁷ N, 4EI ÷ L = 4 × 10⁷ N·m and 2EI ÷ L = 2 × 10⁷ N·m. The first row is 3 × 10⁷, 3 × 10⁷, −3 × 10⁷ and 3 × 10⁷. This example is our own, worked from those formulas [3].

Units

The tool uses SI units: gigapascals for E, metres for L, square metres for A and metres to the fourth for I. Entries have different units: EA ÷ L and 12EI ÷ L³ are in newtons per metre, 6EI ÷ L² is in newtons, and 4EI ÷ L and 2EI ÷ L are in newton metres. If your section data is in centimetres or millimetres, convert it first, remembering that I scales with the fourth power of a length.

Why the matrix is singular

An element matrix on its own is singular: it has no inverse, because a free element can move as a rigid body without any force. Wikipedia says that if a structure is not properly restrained, a force makes it move rigidly, so support conditions must be added before the system can be solved [1]. This tool therefore stops at the element matrix.

Assumptions

The bar matrix assumes small displacements and axial force only. The beam matrix assumes a uniform E and I along the element, and a full frame element, which also carries axial force, needs a larger matrix [3]. The frame element, which combines the two with an area, is not included here. Neither shear deformation nor rotation of the beam axis is modelled.

Using the result

Use the matrix to check a hand assembly in a course, to compare element sizes, or to see how the stiffness changes with length. Doubling L cuts a bar stiffness in half, but it cuts the beam entries by factors of 8, 4 or 2, depending on the term. For a real structure, use full analysis software and a qualified engineer, and use this tool only to understand the building blocks.

Degrees of freedom and sign conventions

Each row and column of the matrix belongs to one degree of freedom, an end movement that can be a deflection or a rotation. For the bar, the order is the x and y movements of the first end, then the x and y movements of the second end. For the beam, it is deflection then rotation at each end. A positive force goes with a positive movement in the same direction. Keep this order in mind when you assemble several elements by hand, so that each entry is added to the correct place in the global matrix [1].

Common mistakes

  • Entering the section area in cm² or mm². The tool expects square metres.
  • Using the wrong angle reference. φ is measured from the global x-axis.
  • Mixing I and A. A is for bars, I is for beams.
  • Trying to invert the element matrix. It is singular until supports are added.

What next

Use this often? Add Stiffness Ma to your Home screen.

Frequently asked questions

What is a stiffness matrix calculator?

A tool that builds the element stiffness matrix of a bar, truss or beam element from its material and section.

What is the stiffness of a bar element?

k = EA ÷ L, the modulus times the area divided by the length.

What does the truss matrix contain?

EA ÷ L times a pattern of c², cs and s², where c and s are the cosine and sine of the angle.

What are the beam matrix terms?

12EI ÷ L³, 6EI ÷ L², 4EI ÷ L and 2EI ÷ L, arranged for deflection and rotation at both ends.

Why is the element matrix singular?

A free element can move rigidly, so supports must be added before solving.

What went wrong?

We only receive the reason you pick, never what you typed into the tool.

Thanks for your feedback.

More Physics & Science Tools