modified mpi calculation