Here we introduce several hooks that improove calculation speed.

1) Using GUESS=MOREAD and other «continuators» to fast continue broken calculation.

2) Using delocalized coordinates and Z-matrix to improove geometry optimization convergency.

3) Preoptimization with pure basis set and theory level.

## Restart GAMESS run

Several types of calculations can be restart. At first, we can use previously calculated wavefunctions as a first approximation for SCF procedure. So we should go into OUTPUT-file and find lines like these:

``` TOTAL NUMBER OF SHELLS = 74
TOTAL NUMBER OF BASIS FUNCTIONS = 269
NUMBER OF ELECTRONS = 130
CHARGE OF MOLECULE = -3
STATE MULTIPLICITY = 1
```

Now you know that your system contains 74 shells. Then go to the PUNCH file and find the latest \$VEC group:

``` \$VEC
1  1 9.96242274E-01 1.40682667E-02-2.17905093E-06 3.78722946E-05 9.40060421E-06
1  2-2.78947620E-02 4.55160705E-06-7.87348757E-05-1.95445329E-05 7.96878327E-03
1  3 1.05104589E-05-1.87329222E-04-4.68646531E-05 1.86244431E-04 3.11302931E-06
...
69 51 2.13592066E+00-2.39107069E-01 6.76959357E-02 2.98433320E-01-5.70259935E-01
69 52 9.05972890E-02 7.40186440E-03 1.27145022E-02-5.17797308E-01-5.31307542E-01
69 53-4.67744067E-01-1.75641321E-02-5.09476733E-02 3.16446772E-02 1.84275386E-01
69 54-2.26933776E-01 1.24876769E-01 9.76844513E-02-9.22205649E-03
\$END
```

Total amount of functions printed in \$VEC should be equal to total number of basis functions (269) but only first 74 have a sense for self-consistent procedure. So we can copy all the \$VEC group into our input and write the following:

```\$guess guess=moread norb=74 \$end
\$vec
...
\$end
```

That’s all. This calculation will be started from precalculated wavefunctions. Often it keeps much computational time and sometimes it is only way to reach SCF convergency.

If we want to calculate triplet state of our molecule and singlet state have been already computed we can use singlet-state wavefunction as an guess for triplet run. But in UHF/ROHF run \$vec contains alpha- and beta- part of the wavefunction. So we copy the contents of singlet \$vec and paste it twise into \$vec group of UHF guess. Visually:

```\$vec
SINGLET_STRING_1
SINGLET_STRING_2
SINGLET_STRING_3
SINGLET_STRING_4
SINGLET_STRING_1
SINGLET_STRING_2
SINGLET_STRING_3
SINGLET_STRING_4
\$end
```

If your HESSIAN computation was stopped you can open IRC-file and copy \$VIB group from start to the bottom of file. Copy it all to your hessian input, put \$end to the end of \$vib group and start this input again.

## Using Z-matrix

The simpliest way to generate Z-matrix is to use babel:

```\$ babel -ixyz ether.xyz -ogzmat gzmat
```

The Gaussian-type Z-matrix will be generated it will be in the following format:

```Ethyl radical

0  2
C
C  1  r2
H  1  r3  2  a3
H  1  r4  2  a4  3  d4
H  2  r5  1  a5  3  d5
H  2  r6  1  a6  3  d6
H  2  r7  1  a7  3  d7
Variables:
r2= 1.4587
r3= 1.0814
a3= 120.92
r4= 1.0807
a4= 121.99
d4= 180.03
r5= 1.0971
a5= 112.83
d5= 179.87
r6= 1.0976
a6= 110.22
d6= 300.35
r7= 1.0976
a7= 110.26
d7=  59.36
```

Format the matrix according to following instructions:

1. Make «Variables:» string empty
2. Remove «=» symbols (keep spaces instead)
3. First line should be comment, second — symmetry.
4. Check your result according to the template:
```! whole group
\$data
C1
C
C  1  r2
H  1  r3  2  a3
H  1  r4  2  a4  3  d4
H  2  r5  1  a5  3  d5
H  2  r6  1  a6  3  d6
H  2  r7  1  a7  3  d7

r2 1.4587
r3 1.0814
a3 120.92
r4 1.0807
a4 121.99
d4 180.03
r5 1.0971
a5 112.83
d5 179.87
r6 1.0976
a6 110.22
d6 300.35
r7 1.0976
a7 110.26
d7  59.36
\$end
```

To make optimization algorithm work in internal coordinates — put NZVAR=3N-6 in \$CONTRL group and form \$ZMAT group as following:

``` \$zmat izmat(1)=
1, 2, 1
1, 3, 1,
1, 4, 1,
1, 5, 2,
1, 6, 2,
1, 7, 2,
2, 3, 1, 2,
2, 4, 1, 2,
2, 5, 2, 1,
2, 6, 2, 1,
2, 7, 2, 1,
3, 4, 1, 2, 3,
3, 5, 2, 1, 3,
3, 6, 2, 1, 3,
3, 7, 2, 1, 3
\$end
```

The first number means 1 for bond, 2 for angle and 3 for dihedral. This matrix can be built simply from the main Z-matrix. Only this section is really sufficient. Coordinates could be given in cartesian format but if IZMAT fields is fill Firefly will try to use internal coordinates for optimization. Jacobian of transition matrix between cartesian and Z-matrix coordinates should have non-zero determinant. If linear dependency exists in your internals GAMESS says something about it.

## Preoptimization strategies

— under construction —