Model nearly implemented.

Rotation matrix only missing.
Fixed GCC errors (>>)
Merged model into master