Finished 2CXM fitting code and made some changes for speed