sarkas.potentials.force_pm.mesh_point_shift
sarkas.potentials.force_pm.mesh_point_shift#
- sarkas.potentials.force_pm.mesh_point_shift(cao)[source]#
Calculate the required shift based on the parity of the charge assignment orders.
- Parameters
cao (numpy.ndarray) – Charge assignment order per direction.
- Returns
mid (numpy.ndarray) – Midpoint shift if cao is even, otherwise no shift.
pshift (numpy.ndarray) – Shift to the closest mesh point.