Minimization: Stopping criterion = quadratic factors are zero

Dear LAMMPS users,

I’m trying to perform energy minimization in my script, but every time I run it the simulation terminates due to the stopping criterion in the minimize command. The log-file tells me that:

Minimization stats:
Stopping criterion = quadratic factors are zero
Energy initial, next-to-last, final =
9419113.80415 -164409395.353 -143346881.879
Force two-norm initial, final = 155148 1.04476e+007
Force max component initial, final = 31424.4 4.00727e+006
Final line search alpha, max atom move = 5.37875e-022 2.15541e-015
Iterations, force evaluations = 280 326

I use a class2 force field to define bonds between the atoms and I set the parameter values using the script lines below.

bond_style class2
bond_coeff 1 class2 2.9 170.5 -50.5 -10.8

I believe this is in correspondence with the implementation requested by the LAMMPS documentation, so I have no clue what went wrong. I also used the write_coeff command to check what force field coefficients LAMMPS uses, but LAMMPS terminates the simulation before writing the class2 bond coefficients in the file.

Do you have any clue on how to solve this issue?

Kind regards,

Tim

Dear LAMMPS users,

I'm trying to perform energy minimization in my script, but every time I run
it the simulation terminates due to the stopping criterion in the minimize
command. The log-file tells me that:

Minimization stats:
  Stopping criterion = quadratic factors are zero
  Energy initial, next-to-last, final =
         9419113.80415 -164409395.353 -143346881.879
  Force two-norm initial, final = 155148 1.04476e+007
  Force max component initial, final = 31424.4 4.00727e+006
  Final line search alpha, max atom move = 5.37875e-022 2.15541e-015
  Iterations, force evaluations = 280 326

I use a class2 force field to define bonds between the atoms and I set the
parameter values using the script lines below.

bond_style class2
bond_coeff 1 class2 2.9 170.5 -50.5 -10.8

I believe this is in correspondence with the implementation requested by the

no, it is not.

LAMMPS documentation, so I have no clue what went wrong. I also used the
write_coeff command to check what force field coefficients LAMMPS uses, but
LAMMPS terminates the simulation before writing the class2 bond coefficients
in the file.

Do you have any clue on how to solve this issue?

no. there is not enough information here. but the fact that your
minimization leads to larger forces indicates, that there is something
*very* wrong with your force field input.

axel.

Sorry, I forgot to mention that I use several bond types in my script, so the actual script is given below. Is the implementation for class2 still incorrect in that case? I interpret the implementation in the LAMMPS documentation as “bond_coeff bondID r0 K2 K3 K4”.

bond_style hybrid morse harmonic class2

bond_coeff 1 morse 443.07 1.154 2.86

bond_coeff 2 harmonic 317.34 2.94

bond_coeff 3 class2 2.9 170.5 -50.5 -10.8

bond_coeff 4 harmonic 2.795 7.04

bond_coeff 5 harmonic 3.326 4.67

bond_coeff 6 harmonic 3.471 5.89

For the non-bonded potentials I use a soft potential (pair_style soft) with A increasing in time from 0 to 100. This script is given below.

pair_style soft 0.1667

pair_coeff * * 0.0

variable prefactor equal ramp(0,100)

fix 1 all adapt 1 pair soft a * * v_prefactor

The script for the minimization step looks like this.

minimize 0.0 1.0e-6 1000 50000

I hope this gives a clearer view on the issue? I checked the LAMMPS documentation several times to see if I did something wrong and I also checked the LAMMPS mailing lists, but I can’t find what it is.

I appreciate your help.

Kind regards,

Tim

Sorry, I forgot to mention that I use several bond types in my script, so
the actual script is given below. Is the implementation for class2 still
incorrect in that case? I interpret the implementation in the LAMMPS

no, for bond style hybrid the syntax is correct.

documentation as "bond_coeff bondID r0 K2 K3 K4".

bond_style hybrid morse harmonic class2

bond_coeff 1 morse 443.07 1.154 2.86

bond_coeff 2 harmonic 317.34 2.94

bond_coeff 3 class2 2.9 170.5 -50.5 -10.8

bond_coeff 4 harmonic 2.795 7.04

bond_coeff 5 harmonic 3.326 4.67

bond_coeff 6 harmonic 3.471 5.89

For the non-bonded potentials I use a soft potential (pair_style soft) with
A increasing in time from 0 to 100. This script is given below.

pair_style soft 0.1667

pair_coeff * * 0.0

variable prefactor equal ramp(0,100)

fix 1 all adapt 1 pair soft a * * v_prefactor

The script for the minimization step looks like this.

minimize 0.0 1.0e-6 1000 50000

I hope this gives a clearer view on the issue? I checked the LAMMPS
documentation several times to see if I did something wrong and I also
checked the LAMMPS mailing lists, but I can't find what it is.

i already voiced my suspicion in my previous e-mail. nothing stated
here changes that.
you either have wrong parameters, wrong settings or a bad topology or
a combination of those.

also, mix-and-matching different force fields in such a massive way,
is not likely to give good results, even if you resolve the more
fundamental issues.

axel.

Hi Tim,

When I minimize small molecules (e.g. flexible water) in case they are too close to each other (bad topology?), I use a stiff bond and angle coefficients first. Then, I switch back to correct bond and angle coefficients and do another minimization. I am not sure if this is your case. If so, you may want to try something similar. However, Alex’s suggestion is good, you should always check your input file for parameters, topology etc.

Regards,
Pengyu

I just realized that I have spelled Axel’s name wrong. Sorry about this mistake.

Regards,
Pengyu

I just realized that I have spelled Axel's name wrong. Sorry about this
mistake.

don't worry about it. you are in good company. about 1/3rd of the
people replying here or contacting me directly, mix up alex and axel.
i am so used to it that i rarely notice it anymore.

sadly, the proportion of people that do post too vague or
insufficiently documented or misleading or off-topic questions is a
munch larger. and that is significantly more upsetting than people
confusing a somewhat obscure first name with the short form of a much
more common first name.

cheers,
     axel.