MuJoCo Simulator¶
The MuJoCo system is a general purpose dynamics physics engine which can be used to simulate robots. It includes both C and Python bindings for programmatically describing and controlling rigid-body models.
Overall, it is less interactive that Webots, as it includes a GUI but the primary interaction is via script editing. The design is more geared toward automatic optimization and design exploration. It includes some support for flexible objects and tendons.
We will not be widely using MuJoCo in this course, but it could be an advanced simulation solution for particular projects.
Tensegrity Structure Solutions¶
The follow examples use the elastic tendon model to numerically solve for equilibrium configurations of tensegrity structures.
The actual simulation models are .xml files generated by Python scripts. The MuJoCo system uses the XML to define a model which is then run as a dynamic simulation to converge on an equilibrium. There are no actuators or control scripts.
The source files for the following can be viewed in the Python/mujoco folder.
Octohedron¶
The octohedron example is based on Figure 10 from the 1976 Anthony Pugh book An introduction to tensegrity [17]. The model is defined by a set of three rigid struts connected by twelve elastic tendons. The initial pose is approximately correct so the dynamic model will converge on a stable configuration in which tendon, structural, and gravity forces balance.
The simulation model in octohedron.xml is generated by the script octohedron.py using the file octohedron_template.xml as input.
Sun River¶
The Sun River example is based on a 1967 work by Kenneth Snelson which appears in his 2013 book Kenneth Snelson: Art and Ideas [22].
The model is defined by a set of four rigid struts connected by fourteen elastic tendons. The initial pose is approximately correct so the dynamic model will converge on a stable configuration in which tendon, structural, and gravity forces balance.
The simulation model in sunriver.xml is generated by the script sunriver.py using the file sunriver_template.xml as input.