Commit a65e2a5d authored by Pierre de Buyl's avatar Pierre de Buyl
Browse files

Use x-axis along the particle's quaternion.

This change allows the fix to work in 2D as well.
parent 00ef854d
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -40,8 +40,8 @@ which the force is added depends on the mode.
For mode = velocity, the active force acts along the velocity vector of each atom. This can
be interpreted as a velocity-dependent friction, such as proposed by "(Erdmann)"_#Erdmann.

For mode = quaternion the force is along the axis obtained by rotating the z-axis along the
atom's quaternion. In other words, the force is along the z-axis in the atom's body
For mode = quaternion the force is along the axis obtained by rotating the x-axis along the
atom's quaternion. In other words, the force is along the x-axis in the atom's body
frame. This mode requires all atoms in the group to have a quaternion, so atom_style should
either be ellipsoid or body.  In combination with Langevin thermostat for translation and
rotation in the overdamped regime, the quaternion mode corresponds to the active Brownian
+1 −1
Original line number Diff line number Diff line
@@ -188,7 +188,7 @@ void FixPropelSelf::post_force_quaternion(int /* vflag */ )
        continue;
      }
      
      double f_act[3] = { 0.0, 0.0, 1.0 };
      double f_act[3] = { 1.0, 0.0, 0.0 };
      double f_rot[3];

      double *quat  = bonus[ellipsoid[i]].quat;