hleaps commit

changes with X and R matrix, reformatting code and removing ssmodx