Finish the implementation of PRM1 model. Needs tests