Stress State Analysis Python Script

General Mohr's Circle for 3D Stress State

General Mohr's Circle for 3D Stress State

Have you ever had a stress state and wanted to simply get the principal stresses without finding a web applet to do it for you? Or maybe you want to know what the deviatoric part of the stress is without finding and using a copy of MATLAB or Mathematica to do the matrix operations for you? This script was written to help answer those questions in as little time as possible with an intuitive command line input syntax.

This script was written in Python (www.python.org) and makes use of the NumPy module (www.numpy.scipy.org). Python is a fairly platform independent programming language with more and more programs being dependent on it on all platforms. The NumPy module adds significant scientific computation power to the language by adding N-dimensional matrix support, matrix operations, LAPACK functions (matrix inverse, eigenvalue and eigenvector decompositions, etc.), among other things.

You can download the script here.

Continue reading

Tutorial: Rotation

A REALLY BIG (long download time) tutorial on how to describe rotation. Topics include coordinate transformations, tensor transformations, converting an axis and angle of rotation into a rotation tensor, Euler angles, quaternions, and generating a uniformly random rotation tensor. This document also discusses the common numerical problem of “mixing” rotations in such a way that the mixed rotation is physically reasonable. The pages in the document that deal with random rotations contain some complicated figures, so don’t worry if your pdf reader pauses for a while on those pages. As a matter of fact, watching the pdf viewer render the figures is like an informative movie because it draws the random dots in the same order as I computed them. By watching the rendering, you can see the nonuniform clustering quite clearly.] (Last posted here 020509, but a formal publication is anticipated)

You may download the rest of the document here.