Added some analysis functions from sicopolis.