OpenSeesPy List Comprehensions

OpenSees was always meant to be an API and you can use various helper functions like ops.eleResponse() and ops.nodeDisp() to get selected response quantities. You will find, however, that the values returned by these commands are not always congruent with what you want. In many cases, Python list comprehensions give an easy one-liner for morphing … Continue reading OpenSeesPy List Comprehensions

The Basic Natural Kernel in a Corotating Frame of Reference

Frame elements in OpenSees are formulated in a basic, or natural, system that removes rigid body displacement modes from the element displacement field, leaving only the deformational modes. The basic forces that correspond to the deformational modes depend on the element force-deformation relationship while the remaining local forces are found from rigid body equilibrium. The … Continue reading The Basic Natural Kernel in a Corotating Frame of Reference

Unrolling the Four Node Quad

The FourNodeQuad was one of the first, if not the first, solid elements in OpenSees. Despite the element's mediocre implementation, the coding style was copied by others into subsequent solid element implementations. Fortunately, before that copying happened, I revised the implementation to be more computationally efficient--and I was kind enough to leave the original author's … Continue reading Unrolling the Four Node Quad

Un-MATLAB Your OpenSees

Many people develop their OpenSees elements and materials in MATLAB, then port to C++. To support this transition, OpenSees implements easy matrix-vector algebra by overloading the +, -, *, and ^ operators for the Matrix and Vector classes. The overloaded operators are self-explanatory, except for ^, which is "transpose times" or inner product. C = … Continue reading Un-MATLAB Your OpenSees

An OpenSeesSPecial Request

Due to sendSelf and recvSelf implementation neglect, OpenSeesSP is broken. I want it to work. Not for OpenSees Cloud, we'll do fine without OpenSeesSP. Instead, it's for everyone out there who wants to run a large model locally without encountering stubborn errors or jumping through hoops to use OpenSeesMP. So, I have a small request--even … Continue reading An OpenSeesSPecial Request

Parametric Oscillator

I sometimes ask collaborators for post ideas. At the end of our meeting this week, Prof. Mark Denavit suggested modeling a parametric oscillator in OpenSees and referred me to the following video. OK, if you didn't watch the video, the response of a parametric oscillator is modified by some frequency-dependent parameter of the system. … Continue reading Parametric Oscillator

Main Street, OpenSees

Every C++ executable has a main() function and OpenSees.exe, the standalone Tcl executable, is no exception. You can find the main() function in SRC/tcl/tclAppInit.cpp, where nothing much happens besides calling g3TclMain(), which is defined in SRC/tcl/tclMain.cpp, home of more familiar content like the banner and copyright statement. Prior to the conveniences provided by scripting languages--running … Continue reading Main Street, OpenSees

A Nod to Backward Compatibility

I didn't want to do it, but I imagined an OpenSees user somewhere out there converting OpenSees Tcl scripts to OpenSeesPy--either manually line by line or using a converter script--and ending up with lines of code that look something like this: ops.section('Fiber',5) ops.patch(...) ops.layer(...) # tag I J secI lpI secJ lpJ E A I … Continue reading A Nod to Backward Compatibility