Example: Restart the SCF

Download RestartSCF.run

This example shows how you can continue with an unfinished calculation. It consists of two runs. After the first run the RUNKF file is saved, and the renamed file is used in the second run. The second run is almost a copy for the first, except for the Restart key. It is also possible to restart from a smaller basis set (provided that the functions are contained in the bigger basis set). Finally you can also restart from a density matrix, but this should be explicitly saved (unlike the orbitals).

# ----------------------------- first run --------------------------

$ADFBIN/band << eor
Title B chain

skip dos

XC
   GGA Becke Perdew
END

UNRESTRICTED

DIIS
   NCycleDamp 0
   DiMix 0.5
   Adaptable false ! Otherwise it converges to a spin-restricted solution
End

Define
   ddd=4.0
   ccc=1.5
End

Lattice
   ddd
End

Atoms
   B 0.0 0.0 0.0
End

BasisDefaults
   BasisType TZ2P
   Core Large
End

END INPUT
eor

mv RUNKF BChain.runkf

# ----------------------------- second run --------------------------

$ADFBIN/band << eor
Title B chain restart

XC
   GGA Becke Perdew
END

UNRESTRICTED

Restart
   File BChain.runkf
   scf
end

Define
   ddd=4.0
   zzz=3
End

Lattice
   ddd
End

Atoms
   B 0.0 0.0 0.0
End

BasisDefaults
   BasisType TZ2P
   Core Large
End

END INPUT
eor

rm RUNKF

# ----------------------------- third run --------------------------

$ADFBIN/band << eor
Title B chain bas=SZ

Save DensityMatrix

skip dos

XC
   GGA Becke Perdew
END

UNRESTRICTED

DIIS
   NCycleDamp 0
   DiMix 0.3
   Adaptable false ! Otherwise it converges to a spin-restricted solution
End

Define
   ddd=4.0
   ccc=1.5
End

Lattice
   ddd
End

Atoms
   B 0.0 0.0 0.0
End

BasisDefaults
   BasisType SZ
   Core Large
End

END INPUT
eor

mv RUNKF BChain.bas=SZ.runkf

# ----------------------------- fourth run --------------------------

$ADFBIN/band << eor
Title B chain restart bas=SZ from density matrix


XC
   GGA Becke Perdew
END

UNRESTRICTED

Restart
   File BChain.bas=SZ.runkf
   scf
   useDensityMatrix true
end

Define
   ddd=4.0
   zzz=3
End

Lattice
   ddd
End

Atoms
   B 0.0 0.0 0.0
End

BasisDefaults
   BasisType SZ
   Core Large
End

END INPUT
eor

rm RUNKF


# ----------------------------- fifth run --------------------------

$ADFBIN/band << eor
Title B chain restart bas=TZ2P from orbitals


XC
   GGA Becke Perdew
END

UNRESTRICTED

Restart
   File BChain.bas=SZ.runkf
   scf
   useDensityMatrix false
end

Define
   ddd=4.0
   zzz=3
End

Lattice
   ddd
End

Atoms
   B 0.0 0.0 0.0
End

BasisDefaults
   BasisType TZ2P
   Core Large
End

END INPUT
eor

rm RUNKF

# ----------------------------- sixth run --------------------------

$ADFBIN/band << eor
Title B chain restart bas=TZ2P from density matrix (bas=SZ)

XC
   GGA Becke Perdew
END

UNRESTRICTED

Restart
   File BChain.bas=SZ.runkf
   scf
   useDensityMatrix true
end

Define
   ddd=4.0
   zzz=3
End

Lattice
   ddd
End

Atoms
   B 0.0 0.0 0.0
End

BasisDefaults
   BasisType TZ2P
   Core Large
End

END INPUT
eor

rm RUNKF