acemd.minimizer module#
- acemd.minimizer.bracket_and_golden_section_search(context, initpos, search_dir, u)#
Bracket and golden section search algorithm.
- Parameters:
context (Context) – OpenMM context object
initpos (np.ndarray) – Initial position
search_dir (np.ndarray) – Search direction
u (float) – Should be initialized to be potential for pos, returns potential for min energy pos
- acemd.minimizer.get_energy_forces(context: Context, positions: ndarray, getForces=True)#
Calculate the potential energy and forces of the system. It takes as input positions in Angstrom and returns the potential energy in kcal/mol and forces in kcal/mol/Angstrom.
- Parameters:
context (Context) – OpenMM context object
positions (np.ndarray) – Positions of the atoms in Angstrom
- Returns:
ene (float) – Potential energy of the system in kcal/mol
forces (np.ndarray) – Forces on the atoms in kcal/mol/Angstrom
- acemd.minimizer.update_pos(oldpos, a, s)#