This is Prof. Peter Corke's code for simulating robotics. Original code was in Matlab as provided here: http://petercorke.com/Robotics_Toolbox.html
He also created a python port of it which is still incomplete. This repository is that python port, which was originally available here: code.google.com/p/robotics-toolbox-python