Psm function

N-state partitioned survival model