Copied over the math functions from MOOCulus
Merge branch 'master' of github.com:kisonecat/mooculus-twitter