Skip to content
Snippets Groups Projects
Commit 036647c1 authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

correct sign of virial tally in fix smd. issue reported by Dinesh SD on lammps-users

parent 03a7d1cd
No related branches found
No related tags found
No related merge requests found
......@@ -270,12 +270,12 @@ void FixSMD::smd_tether()
ftotal[2] -= fz*massfrac;
if (evflag) {
domain->unmap(x[i],image[i],unwrap);
v[0] = fx*massfrac*unwrap[0];
v[1] = fy*massfrac*unwrap[1];
v[2] = fz*massfrac*unwrap[2];
v[3] = fx*massfrac*unwrap[1];
v[4] = fx*massfrac*unwrap[2];
v[5] = fy*massfrac*unwrap[2];
v[0] = -fx*massfrac*unwrap[0];
v[1] = -fy*massfrac*unwrap[1];
v[2] = -fz*massfrac*unwrap[2];
v[3] = -fx*massfrac*unwrap[1];
v[4] = -fx*massfrac*unwrap[2];
v[5] = -fy*massfrac*unwrap[2];
v_tally(i, v);
}
}
......@@ -291,12 +291,12 @@ void FixSMD::smd_tether()
ftotal[2] -= fz*massfrac;
if (evflag) {
domain->unmap(x[i],image[i],unwrap);
v[0] = fx*massfrac*unwrap[0];
v[1] = fy*massfrac*unwrap[1];
v[2] = fz*massfrac*unwrap[2];
v[3] = fx*massfrac*unwrap[1];
v[4] = fx*massfrac*unwrap[2];
v[5] = fy*massfrac*unwrap[2];
v[0] = -fx*massfrac*unwrap[0];
v[1] = -fy*massfrac*unwrap[1];
v[2] = -fz*massfrac*unwrap[2];
v[3] = -fx*massfrac*unwrap[1];
v[4] = -fx*massfrac*unwrap[2];
v[5] = -fy*massfrac*unwrap[2];
v_tally(i, v);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment