Merge pull request #4108 from MightyHelper/develop

Allow compute spin for groups other than `all`
This commit is contained in:
Axel Kohlmeyer
2024-03-30 09:12:43 -04:00
committed by GitHub

View File

@ -215,9 +215,8 @@ void ComputeSpin::compute_vector()
tempnum += tx*tx+ty*ty+tz*tz;
tempdenom += sp[i][0]*fm[i][0]+fm[i][1]*sp[i][1]+sp[i][2]*fm[i][2];
countsp++;
}
} else error->all(FLERR,"Compute compute/spin requires atom/spin style");
}
else error->all(FLERR,"Compute compute/spin requires atom/spin style");
}
MPI_Allreduce(mag,magtot,4,MPI_DOUBLE,MPI_SUM,world);