added master back and implemented MPI reduce for tallies