fixed slight bug in ridge() mpi remainder calculation portion