TrussDesigner

Interactive 2-D truss modeling and analysis implemented in MATLAB. The code computes truss member forces by assembling a global equilibrium matrix from joint force balance equations and solving it directly for unknown member and support forces. Build, edit and evaluate trusses visually.

View repository Watch demo Published June 1, 2020

Project overview

TrussDesigner is a compact MATLAB toolset for creating, editing and analysing planar trusses. It exposes operations to add/remove/move joints and members, computes axial forces for every member, and provides a cost / specification checker so you can examine compliance and estimate cost while iterating on geometry.

What it does

  • Interactive visual construction of 2-D trusses (graphical figures).
  • Static analysis: solve member axial forces for statically determinate truss configurations.
  • Specification checking (dimensions, member stress limits, cost estimates).
  • Utilities: add/remove/move joints & members, print/export design state (saved as Design.mat).

Why it’s useful

Rapid prototyping of truss layouts while simultaneously seeing the mechanical consequences of geometric changes reduces iteration time. The built-in cost/load reporting lets designers trade material and geometry for structural performance.

Demo

Quick walkthrough to demonstrate the workflow and example results.

How to run

Steps to open and use the project in MATLAB:

# 1. clone the repository (or download the ZIP)
git clone https://github.com/aarwitz/TrussDesigner.git
cd TrussDesigner

# 2. open MATLAB, add the project folder to path, then run:
addpath(genpath('path/to/TrussDesigner'))   % replace with your path
main()                                      % starts the interactive interface
help()                                      % shows quick usage instructions

The project is implemented as a collection of .m functions. Running main() launches the interactive workflow; call help() in MATLAB for usage notes present in the repository.

File highlights

  • main.m — entry point and top-level UI loop.
  • design.m — routines that manage the design data structure.
  • calc_forces.m — computes axial forces for members given joint loads/supports.
  • check_specs.m — verifies dimensions, stresses, and cost against user specs.
  • graphics.m, print_design.m — visualization and export utilities.
  • Design.mat — example saved design used by the demo scripts.

Notes & limitations

  • Designed for planar, statically determinate trusses — results for indeterminate structures are not supported.
  • Material models are simplified: axial-only members, linear elastic behaviour assumed for reporting.
  • No GUI beyond MATLAB figures (i.e., not a compiled app). MATLAB with plotting support is required to use the interactive visuals.