# Issue of High Potential Energy on Running Minimization

**URL:** <https://gromacs.bioexcel.eu/t/issue-of-high-potential-energy-on-running-minimization/8121>\
**Category:** User discussions\
**Tags:** forcefield, mdp-parameters, mdrun, simulation-setup, energy-minization\
**Created:** [January 24, 2024, 2:31am UTC](https://gromacs.bioexcel.eu/t/issue-of-high-potential-energy-on-running-minimization/8121 "2024-01-24T02:31:53Z")\
**Posts on this page:** 3\
**Page:** 2

<div class="post-metadata">

**Author:** ![mj.rezayani](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/mj.rezayani/32/3918_2.png) [@mj.rezayani](https://gromacs.bioexcel.eu/u/mj.rezayani)\
**Post date:** [August 20, 2024, 11:33am UTC](https://gromacs.bioexcel.eu/t/issue-of-high-potential-energy-on-running-minimization/8121/21 "2024-08-20T11:33:26Z")

</div>

Dear milosz,

I sent the files to your email yesterday.

Thanks

---

<div class="post-metadata">

**Author:** ![milosz.wieczor](https://avatars.discourse-cdn.com/v4/letter/m/b19c9b/32.png) [@milosz.wieczor](https://gromacs.bioexcel.eu/u/milosz.wieczor)\
**Post date:** [August 20, 2024, 12:00pm UTC](https://gromacs.bioexcel.eu/t/issue-of-high-potential-energy-on-running-minimization/8121/22 "2024-08-20T12:00:37Z")

</div>

Got them, I’m just working on some minor details regarding the formatting of OPLS topologies.

---

<div class="post-metadata">

**Author:** ![milosz.wieczor](https://avatars.discourse-cdn.com/v4/letter/m/b19c9b/32.png) [@milosz.wieczor](https://gromacs.bioexcel.eu/u/milosz.wieczor)\
**Post date:** [August 20, 2024, 12:57pm UTC](https://gromacs.bioexcel.eu/t/issue-of-high-potential-energy-on-running-minimization/8121/23 "2024-08-20T12:57:14Z")

</div>

So I did the following test to make sure all your periodic bonds are in place:

```auto
p = gml.Pdb('FER.pdb')

cutoff = 1.8 # in angstroms
pairs = [] # all pairs going through the PBC

for a1 in p.atoms:
  for a2 in p.atoms[a1.serial:]:
    if p._atoms_dist(a1, a2) > min(p.box[:3]) and p._atoms_dist_pbc(a1, a2) < cutoff:
      pairs.append((a1.serial, a2.serial))

t = gml.Top('FER.top', ignore_ifdef=True)
zeo = t.molecules[0]
for atom_pair in pairs:
  print(atom_pair in zeo.bonds)

```

and all return True, which means your topology is formed correctly.

Running a quick minimization with FER.top and FER.pdb also goes well. I do

`gml.calc_gmx_energy('minimized.gro', 'FER.top', terms='all')`

to check the energy contributions, and they come out as

`{'bond': [15956.757812], 'angle': [24865.548828], 'proper-dih.': [3996.352051], 'lj-(sr)': [0.0], 'coulomb-(sr)': [7405572.5], 'potential': [7450391.0], 'box-x': [5.7054], 'box-y': [4.2909], 'box-z': [4.5246], 'volume': [110.768105], 'density': [1751.036743]}`

In short, it all looks more or less fine. Since the topology doesn’t use Coulomb attenuation of 1-4 pairs (fudgeQQ set to 0 and no `[pairs]`, the magnitude of Coulombic repulsion is large, but you should check that against the original parameterization

[Previous page](https://gromacs.bioexcel.eu/t/issue-of-high-potential-energy-on-running-minimization/8121.md?page=1)
