This repository contains Python codes for analyzing and optimizing various trusses using OpenSeesPy for structural analysis. The repository includes structural models of several benchmark trusses from existing literature, with objective functions defined for stress or frequency-based optimization.
- 10 bar planar truss with frequency constraint
- 18 bar planar truss with stress constraint
- 37 bar planar truss with frequency constraint
- 72 bar space truss with frequency constraint
- 200 bar space truss with frequency constraint
Each code file includes the following
- A
validate()function that runs analysis for a given set of parameters and returns stress or frequency outputs along with a visualization of the model. - An
objective_function()that can be used to perform optimization for the corresponding truss structure.
An example of how to use the codes for optimization is provided in the optimization_example folder along with a convergence curve using an optimization algorithm.
The current files can be easily modified to define and analyze other truss structures by updating node coordinates, element connectivity, and constraints.