adjoint in mpi not working