From owner-chemistry@ccl.net Mon May 23 17:43:01 2022 From: "Andrew DeYoung andrewdaviddeyoung . gmail.com" To: CCL Subject: CCL:G: Maximum number of cycles in Gaussian Message-Id: <-54708-220523174151-8470-G8SRFDp3OW84fMlx4WX11g{}server.ccl.net> X-Original-From: Andrew DeYoung Content-Type: multipart/alternative; boundary="000000000000dcce2005dfb4b4c9" Date: Mon, 23 May 2022 17:41:33 -0400 MIME-Version: 1.0 Sent to CCL by: Andrew DeYoung [andrewdaviddeyoung,gmail.com] --000000000000dcce2005dfb4b4c9 Content-Type: text/plain; charset="UTF-8" Hi, I'm running Gaussian 16. Could someone please help me understand how "number of steps" and MaxCycles work in Gaussian? I have a molecule whose geometry I want to optimize to a local minimum, at the B3LYP/6-31G(d,p) level. I tried this method section in my input: # Opt(MaxCycles=300) B3LYP/6-31G(d,p) In the documentation for the Opt keyword ( https://gaussian.com/opt/?tabid=1#Opt_keyword__MaxCycles_option ), it says that "MaxCycles=N sets the maximum number of optimization steps to N. The default is the maximum of 20 and twice the number of redundant internal coordinates in use (for the default procedure) or twice the number of variables to be optimized (for other procedures)." I'm not sure what it means by "redundant internal coordinates." I did not explicitly specify redundant coordinates (as I think one might do for a Scan calculation). My Z-matrix has 31 lines (31 atoms). On the other hand, my variables section contains 87 lines: 30 bonds (B1-B30), 29 bond angles (A1-A29), and 28 dihedral angles (D1-D28). When I run my optimization, Gaussian terminates after a few hours with a Link 9999 error; the end of the log file reads, "Error termination request processed by link 9999." I think this usually means the optimization has failed to converge, and if I scroll up a bit in the log file, I see that is the case. In the final "GradGrad..." section, it reads: Optimization stopped. -- Number of steps exceeded, NStep= 186 -- Flag reset to prevent archiving. Why specifically did optimization stop after 186 steps -- what am I missing here? Are "number of steps" and MaxCycles the same? If so, why didn't optimization continue until NStep=300 was reached or until the calculation converged? If not, how are they different? I was able to reach convergence by running a new optimization -- with the last geometry of the previous run as the starting configuration -- but in the future, how can I increase the maximum number of allowed steps? (By the way, if I remember correctly, the default number of cycles is 128 if MaxCycles is not specified. Also, I believe the notation used in older versions of Gaussian was, for example, 'OptCyc=300' but I believe it's now 'Opt(MaxCyc=300)' for Gaussian 16. See, for example, https://gaussian.com/obsolete/ I think that 'MaxCyc' is just an allowed abbreviation of 'MaxCycles'.) Thank you very much for your time! Best, Andrew Andrew DeYoung, PhD Department of Chemistry Carnegie Mellon University --000000000000dcce2005dfb4b4c9 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,

I'm running Gaussian= 16.=C2=A0 Could=20 someone please help me understand how "number of steps" and MaxCy= cles=20 work in Gaussian?=C2=A0 I have a molecule whose geometry I want to optimize= =20 to a local minimum, at the B3LYP/6-31G(d,p) level.=C2=A0 I tried this metho= d=20 section in my input:

# Opt(MaxCycles=3D300) B3LYP/= 6-31G(d,p)

In the documentation for the Opt keywor= d ( https://gaussian.com/opt/?tabid=3D1#Opt_keyword__MaxCycles_option ), it says that "MaxCycles=3DN sets the maximum number of optimizatio= n=20 steps to N. The default is the maximum of 20 and twice the number of=20 redundant internal coordinates in use (for the default procedure) or=20 twice the number of variables to be optimized (for other procedures)."=

I'm not sure what it means by "redundant internal coordinates."=C2= =A0 I did not=20 explicitly specify redundant coordinates (as I think one might do for a=20 Scan calculation).=C2=A0 My Z-matrix has 31 lines (31 atoms).=C2=A0 On the = other=20 hand, my variables section contains 87 lines: 30 bonds (B1-B30), 29 bond angles (A1-A29), and 28 dihedral angles (D1-D28).

When I run my optimization, Gaussian terminates after a few hours with a=20 Link 9999 error; the end of the log file reads, "Error termination=20 request processed by link 9999."=C2=A0 I think this usually means the= =20 optimization has failed to converge, and if I scroll up a bit in the log file, I see that is the case.=C2=A0 In the final "GradGrad..." s= ection, it=20 reads:

Optimization stopped.
=C2=A0 =C2=A0 -- Numbe= r of steps exceeded, =C2=A0NStep=3D 186
=C2=A0 =C2=A0 -- Flag reset to p= revent archiving.

Why specifically did optimization stop after 186 steps -- what am I missing here?=C2=A0 Are "number of steps" and MaxCycles the same?=C2=A0 = If so, why didn't optimization continue until NStep=3D300 was reached or until the=20 calculation converged?=C2=A0 If not, how are they different?
=
I was able to reach convergence by running a new optimization -- with the last geometry of the previous run as the starting configuration -- but=20 in the future, how can I increase the maximum number of allowed steps?

(By the way, if I remember correctly, the default number of cycles is 128=20 if MaxCycles is not specified.=C2=A0 Also, I believe the notation used in= =20 older versions of Gaussian was, for example, 'OptCyc=3D300' but I b= elieve=20 it's now 'Opt(MaxCyc=3D300)' for Gaussian 16.=C2=A0 See, for ex= ample, https://gaussian.com/obso= lete/=C2=A0 I think that 'MaxCyc' is just an allowed abbreviati= on of=20 'MaxCycles'.)

Thank you very much for your= time!

Best,
Andrew

=
Andrew DeYoung, PhD
Department of Chemistry
Carneg= ie Mellon University
--000000000000dcce2005dfb4b4c9-- From owner-chemistry@ccl.net Mon May 23 23:16:00 2022 From: "Cory Pye Cory.Pye() smu.ca" To: CCL Subject: CCL:G: Maximum number of cycles in Gaussian Message-Id: <-54709-220523213130-14387-y0Y1f4tZsaR/CSgE6Z+ZoQ.:.server.ccl.net> X-Original-From: Cory Pye Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_YT1PR01MB28733DADED4D21348986B7CCF8D79YT1PR01MB2873CANP_" Date: Tue, 24 May 2022 01:31:12 +0000 MIME-Version: 1.0 Sent to CCL by: Cory Pye [Cory.Pye- -smu.ca] --_000_YT1PR01MB28733DADED4D21348986B7CCF8D79YT1PR01MB2873CANP_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hello Andrew, The default optimization coordinates are redundant internal coordinates. Yo= u didn't explicitly specify a coordinate system for the optimization, so th= ese were used. The older z-matrix coordinates I believe can still be used f= or optimization by specifying Opt=3Dz-matrix if you prefer to work with the= se (I do). They help with symmetry if done right. Your Z-matrix has 31 atoms, for a total of 87 coordinates to be optimized. = Your "space" is of dimension s*31-6 =3D 87, once you project out the cente= r of mass (3) and overall rotational (3) coordinates. Since NStep =3D186, that must mean that the number of redundant internal co= ordinates used was 93 (the 87 + six extra ones). What is PROBABLY happenin= g is, if MaxCycles > 186, then it ignores it, but without looking at the so= urce code, I don't know. Upon looking at your input, I think the best thing that you can do to impro= ve your convergence is simply to add CalcFC to the Opt Keyword. It will tak= e a bit of time at the beginning to start optimizing as it calculates the f= orce constants, but then it usually converges quickly if you have a good gu= ess. I have put some other tips for optimization on my webpage "Gaussian Error M= essages" which should still be on the computecanada website (formerly at A= CENet). https://docs.alliancecan.ca/wiki/Gaussian_error_messages -Cory > From: owner-chemistry+cpye=3D=3Dap.smu.ca[a]ccl.net On Behalf Of Andrew DeYoung andrewdaviddeyoung . gmai= l.com Sent: Monday, May 23, 2022 6:42 PM To: Pye, Cory C Subject: CCL:G: Maximum number of cycles in Gaussian Hi, I'm running Gaussian 16. Could someone please help me understand how "numb= er of steps" and MaxCycles work in Gaussian? I have a molecule whose geome= try I want to optimize to a local minimum, at the B3LYP/6-31G(d,p) level. = I tried this method section in my input: # Opt(MaxCycles=3D300) B3LYP/6-31G(d,p) In the documentation for the Opt keyword ( https://gaussian.com/opt/?tabid= =3D1#Opt_keyword__MaxCycles_option ), it says that "MaxCycles=3DN sets the ma= ximum number of optimization steps to N. The default is the maximum of 20 a= nd twice the number of redundant internal coordinates in use (for the defau= lt procedure) or twice the number of variables to be optimized (for other p= rocedures)." I'm not sure what it means by "redundant internal coordinates." I did not = explicitly specify redundant coordinates (as I think one might do for a Sca= n calculation). My Z-matrix has 31 lines (31 atoms). On the other hand, m= y variables section contains 87 lines: 30 bonds (B1-B30), 29 bond angles (A= 1-A29), and 28 dihedral angles (D1-D28). When I run my optimization, Gaussian terminates after a few hours with a Li= nk 9999 error; the end of the log file reads, "Error termination request pr= ocessed by link 9999." I think this usually means the optimization has fai= led to converge, and if I scroll up a bit in the log file, I see that is th= e case. In the final "GradGrad..." section, it reads: Optimization stopped. -- Number of steps exceeded, NStep=3D 186 -- Flag reset to prevent archiving. Why specifically did optimization stop after 186 steps -- what am I missing= here? Are "number of steps" and MaxCycles the same? If so, why didn't op= timization continue until NStep=3D300 was reached or until the calculation = converged? If not, how are they different? I was able to reach convergence by running a new optimization -- with the l= ast geometry of the previous run as the starting configuration -- but in th= e future, how can I increase the maximum number of allowed steps? (By the way, if I remember correctly, the default number of cycles is 128 i= f MaxCycles is not specified. Also, I believe the notation used in older v= ersions of Gaussian was, for example, 'OptCyc=3D300' but I believe it's now= 'Opt(MaxCyc=3D300)' for Gaussian 16. See, for example, https://gaussian.c= om/obsolete/ I think that 'MaxCyc' is just a= n allowed abbreviation of 'MaxCycles'.) Thank you very much for your time! Best, Andrew Andrew DeYoung, PhD Department of Chemistry Carnegie Mellon University --_000_YT1PR01MB28733DADED4D21348986B7CCF8D79YT1PR01MB2873CANP_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Hello Andrew,

 

The default optimization coordinates are redundan= t internal coordinates. You didn’t explicitly specify a coordinat= e system for the optimization, so these were used. The older z-matrix coord= inates I believe can still be used for optimization by specifying Opt=3Dz-matrix if you prefer to work with these (I do). They= help with symmetry if done right.

 

Your Z-matrix has 31 atoms, for a total of 87 coordi= nates to be optimized. Your “space” is of dimension s*31-6 =3D&= nbsp; 87, once you project out the center of mass (3) and overall rotationa= l (3) coordinates.

 

Since NStep =3D186, that must mean that the number o= f redundant internal coordinates used was  93 (the 87 + six extra ones= ). What is PROBABLY happening is, if MaxCycles > 186, then it ignores it= , but without looking at the source code, I don’t know.

 

Upon looking at your input, I think the best thing t= hat you can do to improve your convergence is simply to add CalcFC to the O= pt Keyword. It will take a bit of time at the beginning to start optimizing= as it calculates the force constants, but then it usually converges quickly if you have a good guess.=

 

I have put some other tips for optimization on my we= bpage “Gaussian Error Messages”  which should still be on = the computecanada website (formerly at ACENet).

 

https://docs.alliancecan.ca/wiki/Gaussian_error_messages

 

-Cory

 

From: owner-chemistry+cpye=3D=3Dap.smu.ca[a]ccl.net <owner-chemistry= +cpye=3D=3Dap.smu.ca[a]ccl.net> On Behalf Of Andrew DeYoung andrewdaviddeyoung . gmail.com
Sent: Monday, May 23, 2022 6:42 PM
To: Pye, Cory C <cpye[a]ap.smu.ca>
Subject: CCL:G: Maximum number of cycles in Gaussian

 

Hi,

 

I'm running Gaussian 16.  Could someone please = help me understand how "number of steps" and MaxCycles work in Ga= ussian?  I have a molecule whose geometry I want to optimize to a loca= l minimum, at the B3LYP/6-31G(d,p) level.  I tried this method section in my input:

 

# Opt(MaxCycles=3D300) B3LYP/6-31G(d,p)

 

In the documentation for the Opt keyword ( https://gaussian.com/opt/?tabid=3D1#Opt_keyword__MaxCycles_option ), it= says that "MaxCycles=3DN sets the maximum number of optimization step= s to N. The default is the maximum of 20 and twice the number of redundant = internal coordinates in use (for the default procedure) or twice the number of variables to be optimized (for other pro= cedures)."

 

I'm not sure what it means by "redundant intern= al coordinates."  I did not explicitly specify redundant coordina= tes (as I think one might do for a Scan calculation).  My Z-matrix has= 31 lines (31 atoms).  On the other hand, my variables section contains 87 lines: 30 bonds (B1-B30), 29 bond angles (A1-A29), and= 28 dihedral angles (D1-D28).

 

When I run my optimization, Gaussian terminates afte= r a few hours with a Link 9999 error; the end of the log file reads, "= Error termination request processed by link 9999."  I think this = usually means the optimization has failed to converge, and if I scroll up a bit in the log file, I see that is the case.  In= the final "GradGrad..." section, it reads:

 

Optimization stopped.

    -- Number of steps exceeded,  NSt= ep=3D 186
    -- Flag reset to prevent archiving.

 

Why specifically did optimization stop after 186 ste= ps -- what am I missing here?  Are "number of steps" and Max= Cycles the same?  If so, why didn't optimization continue until NStep= =3D300 was reached or until the calculation converged?  If not, how are they different?

 

I was able to reach convergence by running a new opt= imization -- with the last geometry of the previous run as the starting con= figuration -- but in the future, how can I increase the maximum number of a= llowed steps?

 

(By the way, if I remember correctly, the default nu= mber of cycles is 128 if MaxCycles is not specified.  Also, I believe = the notation used in older versions of Gaussian was, for example, 'OptCyc= =3D300' but I believe it's now 'Opt(MaxCyc=3D300)' for Gaussian 16.  See, for example, https://gaussian.com/obsolete/  I think that 'MaxCyc' is just an a= llowed abbreviation of 'MaxCycles'.)

 

Thank you very much for your time!

 

Best,

Andrew

 

Andrew DeYoung, PhD

Department of Chemistry

Carnegie Mellon University

--_000_YT1PR01MB28733DADED4D21348986B7CCF8D79YT1PR01MB2873CANP_--