UPDATE: We ran this same test, where we set 5 separate harmonic dihedrals, and saw that indeed, as Mike showed, the system took the dihedral potential that we implemented. We then took this syntax to our simulations, in both HOOMD 1.3.3 and 2.0.0 and unfortunately, saw the same things that we did before--that there seems to be some problem with implementing dihedrals when the system is integrated.
We then ran some additional tests, and found some unexpected results, which I will try to clearly convey:
First we took a four bead system with a single dihedral and added bonds and angles to it, such that the beads started in the lowest energy state of all three potentials.
At this point, if we run Mike's test, we see the same energy as he, since the bond and angle potentials are at their 0 point......no issues yet.
Next, we ran the nvt integrator at dt=0.0001 and kT=0.05 (what we understand to be ~20K in our units), dumped an xml file for the atom positions (which had not moved due to their existence in the minimum of the potential and a low kT value) and ran the same cycle through the dihedral angles to check the system energy. Strangely, despite the particles not moving, the energy began to change drastically with increasing simulation length. I have included the hoomd script (simlengthtest.py), final xml file (atoms10000000.xml), and plot of energies for the final state in simulations of increasing length (energy_by_simlength.png).
Any ideas as to what might be causing this? It certainly seems that HOOMD does not like the combination of dihedral potentials with integrators. Indeed, if we run this same system sans dihedrals, the system energy remains zero throughout when we cycle through the angles, as the particles are in the expected minima of the bond and angle potentials.