Ab Initio Molecular Dynamicperso.ens-lyon.fr/paul.fleurat-lessard/Tuto_CPMD/Atosim_RFCT... ·...

Preview:

Citation preview

Ab Initio Molecular DynamicPaul Fleurat-Lessard

AtoSim Master / RFCT

Ab Initio Molecular Dynamic – p.1/67

Summary

I. Introduction

II. Classical Molecular Dynamic

III. Ab Initio Molecular Dynamic (AIMD)

1 - Which one ?

2 - Car-Parinello !

IV. Application : Free Energy Calculations

V. Conclusions

Ab Initio Molecular Dynamic – p.2/67

Introduction

Goal :Compute statistical averages, as in Monte Carlo.Sample phase space⇒ Macroscopic properties

Tool :Time evolution of the system.

Ab Initio Molecular Dynamic – p.3/67

Microscopic becomes Macroscopic

Trajectories sampling phase space

Amacro = 〈A〉 =

∫ ∫A exp(−βE)d−→ri d

−→pi∫ ∫

exp(−βE)d−→ri d−→pi

Ab Initio Molecular Dynamic – p.4/67

Microscopic becomes Macroscopic

Trajectories sampling phase space

Ergodic hypothesis verified :

Amacro = 〈A〉 = limT→∞

AT = limT→∞

1

T

∫ T

0

A(t)dt

Ab Initio Molecular Dynamic – p.4/67

Microscopic becomes Macroscopic

Trajectories sampling phase spaceErgodic hypothesis verified :

Amacro = 〈A〉 = limT→∞

AT = limT→∞

1

T

∫ T

0

A(t)dt

True only if :System at equilibriumSimulation time T much larger than caracteristictimes of the system.

Ab Initio Molecular Dynamic – p.4/67

Short History of MD

Simulations using balls (hard and soft)Computer Simulations

Super-computer MANIAC (Los Alamos in 1952)Monte Carlo : Metropolis, Rosenbluth, Rosenbluth,Teller, and Teller (1953)MD Hard Sphere : Alder and Wainwright (1957)MD with actual movement equations : Rahman(Argonne 1964)

Ab Initio Molecular DynamicEhrenfest 1927 : First approach.C. Leforestier 1978 : Born-OppenheimerCar and Parrinello (Sissa 1985)

Ab Initio Molecular Dynamic – p.5/67

Computer simulations

Four steps :InitializationPropagationEquilibrationAnalysis

Propagation : All schemes based on numerical solution

miri = −∇iV ({−→ri })

Which V ?Empirical : classical force fieldsQuantum : semi-empirical, ab initio and DFT

How to obtain V ?

Ab Initio Molecular Dynamic – p.6/67

Computer simulations

Four steps :InitializationPropagationEquilibrationAnalysis

Propagation : All schemes based on numerical solution

miri = −∇iV ({−→ri })

Which V ?How to obtain V ?

V pre-calculated and tabulated : limited to fewdegrees of freedom, allows quantum nuclei ;V calculated “on the fly” : mostly classical nuclei

Ab Initio Molecular Dynamic – p.6/67

Time scale

V Simulation duration (ps) AtomsForce Fields 100 000 100 000

Semi-empirical 100 1000DFT, HF 10 100post-HF 1 ≈ 10

Ab Initio Molecular Dynamic – p.7/67

Classical Molecular Dynamic

Ab Initio Molecular Dynamic – p.8/67

Equations of motion

Many formalism :Newton

miri = −∇iV ({−→ri })

LagrangeHamilton

Ab Initio Molecular Dynamic – p.9/67

Equations of motion

Many formalism :NewtonLagrange

Lagrangian for a system withn degrees of freedom

L({−→ri } ,{−→

ri

}

) = K({−→ri } ,{−→

ri

}

) − V ({−→ri })

Equation of motion : Euler-Lagrange

d

dt

∂L

∂−→ri

−∂L

∂−→ri

= 0

Impulsion−→pi = ∂L

∂−→ri

, Force−→Fi = ∂L

∂−→ri

Newton is found again :−→pi =

−→Fi

HamiltonAb Initio Molecular Dynamic – p.9/67

Equations of motion

Many formalism :NewtonLagrangeHamilton

Impulsion−→pi used instead of velocity−→ri

Hamiltonian

H({−→ri } , {−→pi }) =3n∑

i=1

qipi − L

= K({−→ri } , {−→pi }) + V ({−→ri })

Ab Initio Molecular Dynamic – p.9/67

Equations of motion

Many formalism :NewtonLagrangeHamilton

Hamiltonian

H({−→ri } , {−→pi }) = K({−→ri } , {−→pi }) + V ({−→ri })

Equations of motion

ri =∂H

∂pipi = −

∂H

∂ri

Ab Initio Molecular Dynamic – p.9/67

Equations of motion

Many formalism :NewtonLagrangeHamilton

Equations of motion

qi =∂H

∂pipi = −

∂H

∂qi

H is constant along the trajectory, interpreted as thetotal energy

dH

dt=∑

i

[∂H

∂riri +

∂H

∂pipi

]

Ab Initio Molecular Dynamic – p.9/67

Equations of motion

Many formalism :NewtonLagrangeHamilton

Equations of motion

qi =∂H

∂pipi = −

∂H

∂qi

H is constant along the trajectory, interpreted as thetotal energy

dH

dt=∑

i

[∂H

∂ri

∂H

∂pi−

∂H

∂pi

∂H

∂qi

]

= 0

Ab Initio Molecular Dynamic – p.9/67

Equations of motion

Many formalism :NewtonLagrangeHamiltonConclusion : all equivalent !

Ab Initio Molecular Dynamic – p.9/67

Working ingredients

Initialization :{−→ri } , {−→pi } at t = 0{−→

r0i

}

: from cristallographic structure, PDB or by

similarity to avoid very repulsive part of thepotential.{−→

p0i

}

: most of the time 0, random or taken from

Maxwell-Bolztman distribution.How to compute V ?Time is discrete, how to choose time step∆t ?

As large as possibleSmaller than characteristic time of the system

Ab Initio Molecular Dynamic – p.10/67

Empirical potentials

Force fields≈ VSEPR extension :Geometries close to a reference :dCC ≈ 1, 54 Å, dCH ≈ 1, 09 Å, α ≈ 109◦4 . . .

Ethane :dCC = 1, 536 Å,

Propane :dCC = 1, 526 Å, α = 112, 4◦,

Butane :d(e)CC = 1, 533 Å, d

(i)CC = 1, 533 Å, α = 112, 8◦.

Energy close the reference energy !

E = E0 + corrections...

Ab Initio Molecular Dynamic – p.11/67

General form of a Force Field

Main contributions :

EMM = Vbonding + Vangle + Vtorsion + Vnb + . . .

Ab Initio Molecular Dynamic – p.12/67

General form of a Force Field

Main contributions :

EMM = Vbonding + Vangle + Vtorsion + Vnb + . . .

Vbonding Bonding energy

Vbonding =1

2

i∈bondings

kr,i(ri − r0i )

2

Ab Initio Molecular Dynamic – p.12/67

General form of a Force Field

Main contributions :

EMM = Vbonding + Vangle + Vtorsion + Vnb + . . .

Vangle Valence angle (bending) modification

Vangle =1

2

i,j∈bondings

kθ,ij(θij − θ0ij)

2

Ab Initio Molecular Dynamic – p.12/67

General form of a Force Field

Main contributions :

EMM = Vbonding + Vangle + Vtorsion + Vnb + . . .

Vtorsion Torsion energy (rocking)

Vtorsion =1

2

i

[V1(1 + cos ϕi)+

V2(1 − cos 2ϕi) + V3(1 + cos 3ϕi)]

Ab Initio Molecular Dynamic – p.12/67

General form of a Force Field

Main contributions :

EMM = Vbonding + Vangle + Vtorsion + Vnb + . . .

Vtorsion Torsion energy

0

0.5

1

1.5

2

2.5

3

-120 0 120

Ene

rgie

ψ (angle HCCH)

Eclipsee

Decalee

E(ψ)

0

1

2

3

4

5

-120 0 120

Ene

rgie

ψ (angle CCCC)

Gauche

Syn

Anti

Butane : V1=1., V2=0., V3=1.

Ab Initio Molecular Dynamic – p.12/67

General form of a Force Field

Main contributions :

EMM = Vbonding + Vangle + Vtorsion + Vnb + . . .

Vnb Non Bonded interactionsVan Der Waals :

VV dW (d) = ǫ∑

i,j∈atomes

(

d0ij

dij

)12

− 2

(

d0ij

dij

)6

Ab Initio Molecular Dynamic – p.12/67

General form of a Force Field

Main contributions :

EMM = Vbonding + Vangle + Vtorsion + Vnb + . . .

Vnb Non Bonded interactionselectrostatic type :

Vel =∑

i,j∈atomes

qiqj

Ddij

H-bonds

Ab Initio Molecular Dynamic – p.12/67

Popular force fields

MM2, MM3 Mainly for organic chemistry.MMFF94 Only for organic chemistre !AMBER, CHARMm Good for biological systemsUFF Universal Force Field. Universaly avoided !ESFF Extensible and Systematic Force Field

Small benchmark :Ab initio MMFF94 MM3 CHARMm AMBER

∆E 0,4 0,4 0,7 0,8 1,1

∆dXH - 0,09 0,5 0,1 0,2

Ab Initio Molecular Dynamic – p.13/67

Propagator

A good propagator must :Be quick and allow for large∆tTime reversibleConserve mechanical energyCompute forces not too frequentlyConserve phase-space volume

Basic idea : Taylor expansion

−→ri (t + ∆t) = −→ri (t) + −→vi (t)∆t +−→ai (t)

2∆t2 + . . .

−→vi (t + ∆t) = −→vi (t) + −→ai (t)∆t +

−→vi (t)

2∆t2 + . . .

Ab Initio Molecular Dynamic – p.14/67

Verlet

General expression :

−→ri (t + ∆t) = −→ri (t) + −→vi (t)∆t +−→ai (t)

2∆t2 + . . .

−→ri (t − ∆t) = −→ri (t) −−→vi (t)∆t +

−→ai (t)

2∆t2 + . . .

thus−→ri (t + ∆t) = 2−→ri (t) −−→ri (t − ∆t) +

−→fi (t)

Mi

∆t2 + O(∆t3)

Store position and forces only

Accuracy in∆t3

Time reversible by construction

Velocities indirectly computed (finite differences) : lessaccurate−→vi = (−→ri (t + ∆t) −−→ri (t − ∆t)) /(2∆t) + O(∆t2)

Higer order term in the propagation formula⇒ numerical noiseAb Initio Molecular Dynamic – p.15/67

Leap-Frog variant

Designed to improve numerical accuracy

−→ri (t + ∆t) = −→ri (t) + −→vi (t +∆t

2)∆t

−→vi (t +∆t

2) = −→vi (t −

∆t

2) + −→ai (t)∆t

−→vi (t) =(−→vi (t + ∆t

2 ) −−→vi (t −∆t2 ))/2 + O(∆t2)

More stable

Ab Initio Molecular Dynamic – p.16/67

Velocity Verlet

Improve velocity accuracy

−→ri (t + ∆t) = −→ri (t) + −→vi (t)∆t +−→ai (t)

2∆t2

−→vi (t + ∆t) = −→vi (t) +−→ai (t) + −→ai (t + ∆t)

2∆t

Velocity accuracy inO(∆t3)Can be seen as a predictor-corrector

Ab Initio Molecular Dynamic – p.17/67

Verlet : Summary

Graphical form :

Velocity verlet often used because :

Simple and efficient, little force computation

Accurate in∆t3

Time reversible, Symplectic (conserve phase space volume)

For realistic time step, Velocity Verlet as good as Gear

predictor-corrector Ab Initio Molecular Dynamic – p.18/67

Constrained Dynamic

Why using constraints : to get larger∆t (frozend(CH)), prevent or force some evolutionPrincipal : Lagrange multiplierConstraint defined byσ ({−→ri }) = 0 , For example :

Distance :σ ({−→ri }) = |−→ri −−→rj | − d0

Difference of two distances :σ ({−→ri }) = |−→ri −

−→rj | − |−→rk −−→rl | − d0

Coordination number :σ ({−→ri }) = ni ({−→ri }) − n0

with ni ({−→ri }) =

j 6=i S(|−→ri −−→rj |) et

S(r) = (1 + exp(κ(r − rc)))−1.

Ab Initio Molecular Dynamic – p.19/67

Constrained Dynamic

Constraint defined byσ ({−→ri }) = 0Extended Lagrangian :

L′({−→ri } , {−→pi }) = L({−→ri } , {−→pi }) −∑

α

λασα ({−→ri })

Equations of motion :

miri = −∂V

∂ri−∑

α

λα∂σα

∂ri

SHAKE : λα tq σα ({−→ri (t + ∆t)}) = 0RATTLE : λα tq σα ({−→ri (t + ∆t)}) = 0

Ab Initio Molecular Dynamic – p.19/67

Which ensembles ?

By default, isolated system⇒ E conserved, i.e. NVEInitialize {−→pi } so thatEtot = Etarget then propagateHow can we obtain other ensembles ?

NVT : E fluctuates

Q(N, V, T ) =1

N !h3N

Z

Πid−→ri d−→pi exp(−βH) = exp (−βF (N, V, T ))

NPT : E and V fluctuate

∆(N, P, T )1

V0N !h3N

Z

Πid−→ri d−→pi exp (−β(H + PV )) = exp (−βG(N, P, T ))

Ab Initio Molecular Dynamic – p.20/67

Canonical ensemble

We know tha⟨∑

kp2

k

2mk

= 32NkBT leading to

T (t) = 23NkB

kpk(t)2

2mk

At equilibrium, Maxwell-Boltzmann distributionInitialize

Velocities from MB distributionOr

−→p0

i =−→0 , then heating using "inversed

annealing" :−→vi (t) → α−→vi (t), α > 1.Equilibrate : homogenizeT, to obtain〈T (t)〉 = T

Ab Initio Molecular Dynamic – p.21/67

Canonical ensemble

We know tha⟨∑

kp2

k

2mk

= 32NkBT leading to

T (t) = 23NkB

kpk(t)2

2mk

At equilibrium, Maxwell-Boltzmann distributionInitializeEquilibrate : homogenizeT, to obtain〈T (t)〉 = T

Rescaling : when|T (t) − T | > ∆T , then−→vi (t) →

−→vi (t)√

TT (t) ⇒ Brutal !

Thermostat : coupling with a thermal bath

Ab Initio Molecular Dynamic – p.21/67

Nosé-Hoover

Extended System : a supplementary variable thatmimics the thermal bathEquations

Ab Initio Molecular Dynamic – p.22/67

Nosé-Hoover

Extended SystemEquations

−→ri =

−→pi

mi

−→pi =

−→Fi − ξ−→pi

ξ =1

Q

(∑

k

p2k

2mk

− gkBT

)

=gkB

Q(T − T )

with g number of degrees of freedom,Q mass of thethermostat

Ab Initio Molecular Dynamic – p.22/67

Nosé-Hoover

EquationsQ regulates the speed of exchanges between the bathand the system

Q too small : large not wanted oscillations, slowconvergenceQ too large : slow exchanges.Q → ∞,microcanonical ensemble !Optimum when resonating with the system, ieQ ≈ gkBT

ω2

Ab Initio Molecular Dynamic – p.22/67

Nosé-Hoover Chains

Nosé-Hoover not always ergodic, response time tooslow

Chain of M thermostats :

−→ri =

−→pi

mi

−→pi =

−→Fi − ξ1

−→pi

ξ1 =1

Q1

(∑

k

p2k

2mk

− gkBT

)

− ξ1ξ2

ξn =1

Qn

(Qn−1ξ

2n−1 − kBT

)− ξnξn+1

˙ξM =1

QM

(QM−1ξ

2n−1 − kBT

)

Ab Initio Molecular Dynamic – p.23/67

Test 1D oscillator

H = p2

2m+ mω2x2

2, f(p) =

√β

2πme−βp2/2m, f(x) =

√βmω2

2πe−βω2x2/2

1 thermostat 3 thermostats 4 thermostats

Ab Initio Molecular Dynamic – p.24/67

Andersen or Hybrid Monte Carlo

Mix DM and Monte Carlo to simulate chocs with thethermal bathAndersen

The velocity of a random particle is withdrawn fromthe MD distribution ;Ergodic by construction, converges to the NVTassociated to the MB distribution ;Many particles can be chosen at onceRe-attribution period not so importantRe-attribution does not kick wafefunction too farfrom BO surface

Hybrid Monte Carlo : all velocities are changed atonce

Ab Initio Molecular Dynamic – p.25/67

Langevin

Still stochastic, but white noise added directly in theequation of motion for all particles

q =pt

m

p = −∇V (q) −ξ

mp +

βdW (t)/dt

with W (t) a gaussian white noisePhysically (mathematically ?) : the most efficient tothermalize, the fastest to convergebut very rare in chemistry, and badly behave in CPMD

Ab Initio Molecular Dynamic – p.26/67

False thermostat : Berendsen

Can be seen as a rescaling, with

α(t + ∆t) =

[

1 +∆t

τ

(T

T (t + ∆t)− 1

)]1/2

=

[

1 +∆t

τT (t + ∆t)(T − T (t + ∆t))

]1/2

T − T (t + ∆t) affectsα and notαVery used in biochemistrybutdo not sample the canonical ensemble !⇒ Use only for equilibration.

Ab Initio Molecular Dynamic – p.27/67

Isobaric-Isotherm ensemble

This is the closest to chemist experimentsVolumebecomes a dynamical variableNo stochastic approachesTwo families :

Isotropic : V change, but not the box shapeHoover, AnderssenAnisotropic :all parameters of the box can changeParrinello-Rahman, Martyna-Tobias-Klein

Ab Initio Molecular Dynamic – p.28/67

Isotropic NPT : Andersen

First approach (1980)Mimic the action of a piston on the box :

Mass QKinetic energyKV = 1

2QV 2

Potential energyVV = PV

Reduced variables :−→s = V −1/3−→r ,−→s = V −1/3−→v

Hamiltonian :HV = K + KV + V + VV

Ab Initio Molecular Dynamic – p.29/67

Isotropic NPT : Andersen

First approach (1980)Mimic the action of a piston on the box

Reduced variables :−→s = V −1/3−→r ,−→s = V −1/3−→v

Hamiltonian :HV = K + KV + V + VV

Equations of motion :

−→s =

−→f

mV 1/3−

2

3

−→s−→V

V

V = (P − P )/Q

with P instantaneous pressureP = 23V (K −W) et

W = −12

i

j>i−→rij

−→fij Internal Virial.

Ab Initio Molecular Dynamic – p.29/67

Isotropic NPT : Andersen

First approach (1980)Mimic the action of a piston on the box

Reduced variables :−→s = V −1/3−→r ,−→s = V −1/3−→v

Hamiltonian :HV = K + KV + V + VV

Equations of motion :

−→s =

−→f

mV 1/3−

2

3

−→s−→V

V

V = (P − P )/Q

In fact, sampling the isobaric-iso-enthalpic ensemble,not so common.

Ab Initio Molecular Dynamic – p.29/67

Isotropic NPT : Hoover

Extended system, similar to the Nosé-Hooverthermostat

−→r = V 1/3−→s

−→si =

−→pi

miV −1/3 −→

pi =−→Fi − (ξ + χ)−→pi

ξ =gkB

Q(T − T )

χ =V

3Vχ =

P(t) − P

τ 2PkBT

with g number of degrees of freedom,Q mass of thethermostat,τP relaxation time of the pressurefluctuations.

Ab Initio Molecular Dynamic – p.30/67

Anisotropic NPT

Parrinello-RahmanIdea : reduced variable−→ri = h

−→si , with

h = [−→a ,−→b ,−→c ] and−→a ,

−→b et−→c cell parameters

We introduceG = hth

P pressure tensor :

Pαβ =1

V

(∑

i

mi ˙riα ˙riβ +∑

i

j

rijαfijβ

)

Hamiltonian

H = K +1

2Q∑

α

β

h2αβ + V + PV

Ab Initio Molecular Dynamic – p.31/67

Anisotropic NPT

Parrinello-RahmanIdea : reduced variable−→ri = h

−→si

We introduceG = hth

Hamiltonian

H = K +1

2Q∑

α

β

h2αβ + V + PV

Equations of motion

m−→s = h−1−→f − mG

−1G−→s

QH = (P − 1P )V(h−1)t

with Q mass of the box Ab Initio Molecular Dynamic – p.31/67

Equilibration

Listening phaseWe check that variables that should be conserved arestable, no drift :

TERMSD : Root Mean square displacementg(r) : pair distribution function

One simple criterion : averages should not depend onthe initial time.

Ab Initio Molecular Dynamic – p.32/67

Analysis

Production phaseCompute the interesting properties :

RMSDStructural parametersg(r)Fluctuations⇒ Cv

Vibrational spectraKinetic constant

Average on a given window, larger than fluctuationtime (see Practical session !)Thermostat, Barostat are perturbing the averages

Ab Initio Molecular Dynamic – p.33/67

Shall we go beyond classical MD

Pros of classical MD :FastGood geometries, vibrations, transport propertiesThermodynamical properties accurate forparameterized systems

ConsParameters!One need to know how atoms are linked :• Chemical reactions cannot be studied by standard

FF• ⇒ ReaxFF, ReBO, LOTF . . .No excited statesNo electronic properties : charge, density, . . .

Ab Initio Molecular Dynamic – p.34/67

Ab Initio Molecular Dynamics

Ab Initio Molecular Dynamic – p.35/67

Which ab initio MD ?

Electron explicitly taken into accountLet us denote by :

Mk, Zk,−→Rk the mass, the charge and the position of

a nucleus−→Rk ou−→vk the velocity of a nucleus−→pk = Mk

−→vk the impulsion of a nucleusme, ri the mass and the position of an electron

Ab Initio Molecular Dynamic – p.36/67

Which ab initio MD ?

Electron explicitly taken into accountWe would like to solve

i~∂φ({−→

Rk

}

, {−→ri } ; t)

∂t= H

({−→Rk

}

, {−→ri })

φ({−→

Rk

}

, {−→ri } ; t)

with

H = −

electrons∑

i

∆i

2︸ ︷︷ ︸

Te

elec.∑

i

nuclei∑

k

Zk

rik

+elec.∑

i

elec.∑

j>i

1

rij

+∑

k

l>k

ZkZl

Rkl

︸ ︷︷ ︸

Vne

noy.∑

k

∆k

2Mk︸ ︷︷ ︸

TNAb Initio Molecular Dynamic – p.36/67

TDSCF approach

Hypothesis :

φ({−→

Rk

}

, {−→ri } ; t)

≈ Ψ ({−→ri } ; t) χ({−→

Rk

}

; t)

exp

[i

~

∫ t

t0

dt′Ee(t′)

]

with the convenient phase factor

Ee(t′) =

∫∏

i

d−→ri

k

d−→Rk

Ψ∗ ({−→ri } ; t) χ∗

({−→Rk

}

; t)

HeΨ ({−→ri } ; t) χ({−→

Rk

}

; t)

Let us writed−→r =

i d−→ri andd

−→R =

k d−→Rk

Ab Initio Molecular Dynamic – p.37/67

TDSCF approach

Hypothesis :

φ({−→

Rk

}

, {−→ri } ; t)

≈ Ψ ({−→ri } ; t) χ({−→

Rk

}

; t)

exp

[i

~

∫ t

t0

dt′Ee(t′)

]

with

Ee(t′) =

d−→r d−→R

Ψ∗ ({−→ri } ; t) χ∗

({−→Rk

}

; t)

HeΨ ({−→ri } ; t) χ({−→

Rk

}

; t)

Ab Initio Molecular Dynamic – p.37/67

TDSCF approach

Hypothesis :

φ({−→

Rk

}

, {−→ri } ; t)

≈ Ψ ({−→ri } ; t) χ({−→

Rk

}

; t)

exp

[i

~

∫ t

t0

dt′Ee(t′)

]

we get(project on< Ψ|, < χ|, used < H > /dt = 0) :

i~∂Ψ

∂t= −

i

1

2∇2

i Ψ +

{∫

d−→Rχ∗

({−→Rk

}

; t)

Vneχ({−→

Rk

}

; t)}

Ψ

i~∂χ

∂t= −

k

1

2Mk

∇2kχ +

{∫

d−→r Ψ∗ ({−→ri } ; t)HeΨ ({−→ri } ; t)

}

χ

Ab Initio Molecular Dynamic – p.37/67

TDSCF approach

Let us write (A,S : real)χ({−→

Rk

}

; t)

= A({−→

Rk

}

; t)

exp[

iS({−→

Rk

}

; t)

/~

]

we get, after separating real and imaginary part :

i~∂Ψ

∂t= −

i

1

2∇2

i Ψ +

{∫

d−→Rχ∗

({−→Rk

}

; t)

Vneχ({−→

Rk

}

; t)}

Ψ

∂S

∂t= −

k

1

2Mk

(∇kS)2 −

d−→r Ψ∗HeΨ +∑

k

1

2Mk

∇2kA

A

∂A

∂t= −

k

1

Mk

(∇kS) (∇kA) −∑

k

1

2Mk

A(∇2

kS)

Ab Initio Molecular Dynamic – p.37/67

Ehrenfest approach

Classical nuclei :~ = 0

∂S

∂t+∑

k

1

2Mk(∇kS)2 +

d−→r Ψ∗HeΨ = 0

Hamilton-Jacobi equation analogy :

∂S

∂t+∑

k

1

2Mk(pk)

2 + Ve = 0

Using−→pk ≡ ∇kS

MkRk(t) = −∇k

d−→r Ψ∗HeΨAb Initio Molecular Dynamic – p.38/67

Ehrenfest approach

Classical nuclei :

|χ({−→

Rk

}

; t)

|2 =∏

k

δ(−→Rk −

−→Rk(t)

)

lim~→0

d−→Rχ∗

({−→Rk

}

; t)−→Rkχ

({−→Rk

}

; t)

=−→Rk(t)

That is

i~∂Ψ

∂t= −

i

∇2i Ψ + VneΨ = HeΨ

Ab Initio Molecular Dynamic – p.39/67

Ehrenfest summary

Wavefunction explicitly propagated, coupled to thenuclei

MkRk(t) = −∇k

d−→r Ψ∗HeΨ

i~∂Ψ

∂t= HeΨ

No electronic minimization, except fort = 0Transitions between electronic states are explicitlydescribed

∆t imposed by electrons dynamicsVery very smallEhrenfest seldom used

Ab Initio Molecular Dynamic – p.40/67

Born-Oppenheimer

Wavefunction is not propagatedTime independent Schrödinger equation is solved for

each{−→

Rk

}

:

MkRk(t) = −∇k minΨ0

〈Ψ0 |He|Ψ0〉

E0Ψ0 = HeΨ0

Electronic minimization at each stepNo more transitions between electronic states

∆t imposed by the nuclei⇒ relatively large

Ab Initio Molecular Dynamic – p.41/67

Born-Oppenheimer : HF, DFT

Simplifications using independent electron methods :HF ou DFT-KSMolecular Orbitals denoted by{ϕi}Energy minimization with orthogonal MO : :

Le = −〈Ψ0 |He|Ψ0〉 +∑

i,j

Λij (〈ϕi |ϕj〉 − δij)

leads to :Heffϕi =

j

Λijϕj

Ab Initio Molecular Dynamic – p.42/67

Born-Oppenheimer : HF, DFT

Simplifications using independent electron methods :HF ou DFT-KSMolecular Orbitals denoted by{ϕi}Energy minimization with orthogonal MO :leads to :

Heffϕi =∑

j

Λijϕj

Diagonal form :Heffϕi = ǫiϕi

Ab Initio Molecular Dynamic – p.42/67

Born-Oppenheimer : HF, DFT

Simplifications using independent electron methods :HF ou DFT-KSMolecular Orbitals denoted by{ϕi}Energy minimization with orthogonal MO :leads to :

Heffϕi =∑

j

Λijϕj

So that :

MkRk(t) = −∇k minΨ0

〈Ψ0 |He|Ψ0〉

0 = −Heffϕi +∑

j

Λijϕj

Ab Initio Molecular Dynamic – p.42/67

Car-Parrinello (1/2)

Goal : benefit from all advantagesEhrenfest : No electronic minimizationBO : Large time step

Tool : Adiabatic separation between fast electrons andslow nucleiHow : MO described as classical variables

Ab Initio Molecular Dynamic – p.43/67

Car-Parrinello (1/2)

Goal : benefit from all advantagesTool : Adiabatic separation between fast electrons andslow nucleiHow : MO described as classical variables, butdecoupled from the nucleiUsing an extended Lagrangian formulation

Ab Initio Molecular Dynamic – p.43/67

Car-Parrinello (2/2)

Goal : benefit from all advantagesTool : Adiabatic separation between fast electrons andslow nucleiHow : MO described as classical variables, butdecoupled from the nuclei

LCP =∑

k

1

2Mk

−→Rk

2 +∑

i

1

2µi 〈ϕi | ϕi〉

︸ ︷︷ ︸

Kinetic energy

−〈Ψ0 |He|Ψ0〉︸ ︷︷ ︸

Potential energy

+ constraints︸ ︷︷ ︸

orthogonality, geometric...

µ "Fictitious" mass of the electronsAb Initio Molecular Dynamic – p.44/67

Car-Parrinello (2/2)

Goal : benefit from all advantagesTool : Adiabatic separation between fast electrons andslow nucleiConstant of motion

HCP =∑

k

1

2Mk

−→Rk

2 +∑

i

1

2µi 〈ϕi | ϕi〉 + Eel

(

{ϕi} ,{−→

Rk

})

Ab Initio Molecular Dynamic – p.44/67

Car-Parrinello (2/2)

Goal : benefit from all advantagesTool : Adiabatic separation between fast electrons andslow nucleiEquations of motion

MkRk(t) = −∇k 〈Ψ0 |He|Ψ0〉 + ∇k {constraints}

µϕi(t) =δ

δϕ∗i

〈Ψ0 |He|Ψ0〉 +δ

δϕ∗i

{constraints}

∆t approximately 5 to 10 times smaller than BO

Ab Initio Molecular Dynamic – p.44/67

Car-Parrinello : HF,DFT-KS

We use HF or DFT-KS methods

LCP =∑

k

1

2Mk

−→Rk

2 +∑

i

1

2µi 〈ϕi | ϕi〉 −

⟨Ψ0

∣∣Heff |Ψ0

+∑

i,j

Λij (〈ϕi |ϕj〉 − δij)

Ab Initio Molecular Dynamic – p.45/67

Car-Parrinello : HF,DFT-KS

We use HF or DFT-KS methodsEquations of motion become

MkRk(t) = −∇k

⟨Ψ0

∣∣Heff |Ψ0

µϕi(t) = −Heffϕi +∑

j

Λijϕj

Very similar to BO :µϕi(t) = 0

Ab Initio Molecular Dynamic – p.45/67

Why does it work ?

Fast electrons, slow nucleiElectronic frequencies forSi8 :

f e(ω) =

∫ ∞

t=0

cos(ωt)∑

i

Ψ(t)∣∣∣ Ψ(0)

dt

Triangle : latest nuclear frequencyAb Initio Molecular Dynamic – p.46/67

Why does it work ?

Electronic Oscillations close to the BO surface

Econs =∑

k

1

2Mk

−→Rk

2 +∑

i

1

2µi 〈ϕi | ϕi〉 + 〈Ψ |He|Ψ〉

Ephys =∑

k

1

2Mk

−→Rk

2 + 〈Ψ |He|Ψ〉 = Econs − Te

Model System : Si FCC, 2 atoms/cell

Ab Initio Molecular Dynamic – p.47/67

Why does it work ?

Electronic Oscillations close to the BO surfaceModel System : Si FCC, 2 atoms/cell

Small oscillations, stable in time

Ab Initio Molecular Dynamic – p.47/67

Why does it work ?

Electronic Oscillations close to the BO surfaceModel System : Si FCC, 2 atoms/cell

Small oscillations, stable in time

Ab Initio Molecular Dynamic – p.47/67

Why does it work ?

Forces oscillations very smallModel System : Si FCC, 2 atoms/cell

Small oscillations, stable in timeOscillations averaged to 0

Ab Initio Molecular Dynamic – p.48/67

Why does it work ?

Forces oscillations very smallModel System : Si FCC, 2 atoms/cell

Small oscillations, stable in timeOscillations averaged to 0

Ab Initio Molecular Dynamic – p.48/67

Working Condition CP : adiabaticity

Fast electrons, small nuclei :µ ≪ Mk

ϕi ≈ 0 : wavefunction close to BO, always slightlyabove.Compromise forµ :

∆t large, but we want electron/nuclei separationElectronic frequencyϕi occ. andϕa virtual :ωe

ia =√

2(ǫa − ǫi)/µ

Smallest :ωemin ∝

EGAP/µ

Highest :ωemax ∝

Ecut/µ

so that∆tmax ∝√

µ/Ecut

Usually :µ = 400-500,∆t = 5-10 au = 0.12-0.24 fs.

Ab Initio Molecular Dynamic – p.49/67

Loosing adiabaticity

If EGAP ≈ 0, thenωemin too close toωnucl

For example for an elongated bond, exSn2

Ab Initio Molecular Dynamic – p.50/67

Loosing adiabaticity

If EGAP ≈ 0, thenωemin too close toωnucl

For example for an elongated bond, exSn2

For metallic systems !Two solutions :

Back to BOElectronic Thermostat

Ab Initio Molecular Dynamic – p.50/67

Comparison BO/CP

BOMD CPMDAlways on BO surface Always slightly above∆t ∼ τnucl ∆t ≪ τnucl

∆tBO ≈ 5 − 10∆tCP

Minimization at each step Only OrthogonalizationProblem when deviatingfrom the BO surface

Stable with respect to devi-ations

Works forEGAP = 0 Electronic thermostatUsed for solid systems Used for liquids

Ab Initio Molecular Dynamic – p.51/67

Comparison BO/CP

Ab Initio Molecular Dynamic – p.52/67

Comparison Ehrenfest/CP

Ehrenfest MD CPMDReal separation (quantum)Fictitious separation (clas-

sical)∆t ∼ τelec ∆t ≫ τelec

∆tCP ≈ 5 − 10∆tEhrenfest

Rigorous Orthonormality Imposed by constraintsDeviations from BO add upStable

Ab Initio Molecular Dynamic – p.53/67

Conclusion and perspectives

AIMD : includes electronic effects, allows forchemical reactions, catalytic processes . . .CPMD : Very used, very fashion !but . . .

Number of atoms still limitedDFT not always sufficient

PerspectivesHybrid methods : QM/MM, QM/QM’Post-HF and TD approachs : excited states, highlycorrelated materials . . .BO ? New algorithms faster, more efficient,becomes competitive with CPMD.

Ab Initio Molecular Dynamic – p.54/67

Application : Free energycalculations

Ab Initio Molecular Dynamic – p.55/67

Free energy profile

Reaction coordinateq =

q({−→

Rk

})

Probability density

P(z) =1

QNV T

d−→Rd

−→P exp(−βH)δ

(

q({−→

Rk

})

− z)

Free energy profile

F (z) = −kBT lnP(z)

Reaction rate :

k =kBT

he−

∆rG‡

RT

Ab Initio Molecular Dynamic – p.56/67

Rare event ?

System position forEa = 2 × kBT

⇒ Diffusive system.

Ab Initio Molecular Dynamic – p.57/67

Rare event ?

System position forEa = 5 × kBT

⇒ Nothing at the TS !

Ab Initio Molecular Dynamic – p.57/67

Rare event ?

System position forEa ≫ kBT

Alternating between the two states.Long residence time, short transition time.kTST ≈ 1s−1

⇒ Slow reaction≡ rare event.

Ab Initio Molecular Dynamic – p.57/67

Why is it so difficult ?

Standard MD is a "real time" method,∆t ≈ 0.1-1 fsChemical reaction time : fast around ns, typical aroundµs-ms, biology can be seconds⇒ Two incompatible time scalesMore, phase space dimension is 6N, impossible tofully sample

Ab Initio Molecular Dynamic – p.58/67

Why is it so difficult ?

⇒ Two incompatible time scalesSolutions

Work at higher T : faster sampling but might be notthe same phenomenaForce the reaction to occur :• Biais potential• Constrained dynamic• Adiabatic dynamic• Metadynamic

In all cases, we calculate∆F , notF

Ab Initio Molecular Dynamic – p.58/67

Bias potential

Many approaches : Umbrella sampling, adaptive biaispotential, accelerated dynamics, flooding potential...Main Idea : we add a potential to "erase" the barrier

V ′

({−→Rk

})

= V({−→

Rk

})

+ ∆V(−→q({−→

Rk

}))

Then get the non-biaised energy :

O({−→

Rk

})⟩

=

O({−→

Rk

})

exp (β∆V)⟩′

〈exp (β∆V)〉′

Problem : we do not know the barrier position, heightand shape !In practice : many simulations with a moving modelpotential Ab Initio Molecular Dynamic – p.59/67

Umbrella Sampling

Usual bias :∆V(

q({−→

Rk

}))

∝[

q({−→

Rk

})

− z]2

Simulations for different−→z

Ab Initio Molecular Dynamic – p.60/67

Constrained dynamics

Two families :q evolves continuously fromz0 to zf during thesimulation• Slow growth method : slow evolution, quasi-static• Fast growth method,Jarzinsky: fast evolution,

average taken on many trajectories

〈exp (−βW )〉 = exp (−βF )

Many simulation withq set to different values ofz.

Ab Initio Molecular Dynamic – p.61/67

Thermodynamic integration

Change in free energy calculated by integrating freeenergy derivative :

∆F (z = z0 → z = zf ) =

∫ zf

z0

∂F

∂qdq

Numerical evaluation using discrete valuesA constrained simulation is launched for each value ofq(z).How to obtain∂F

∂q (z) ?

Ab Initio Molecular Dynamic – p.62/67

Free energy derivatives

Two problems :q = z ⇒ q = 0 : no sampling for the impulsionpq.Blue-Moon :

〈O(z)〉 =

⟨Z−1/2O

cont

〈Z−1/2〉cont

with Z the reduce mass associated toq :

Z =∑

k

1

Mk

∂q

∂Rk

∂q

∂Rk

q is non linear with respect to{−→

Rk

}

, Jacobian matrix

J non unityAb Initio Molecular Dynamic – p.63/67

Free energy derivatives

Two problems :q = z ⇒ q = 0 : no sampling for the impulsionpq.

q is non linear with respect to{−→

Rk

}

, Jacobian matrix

J non unity

∂F

∂q(z) =

⟨∂V

∂q+ kBT

∂ ln |J|

∂q

q=z

Ab Initio Molecular Dynamic – p.63/67

Free energy derivatives

Two problems :q = z ⇒ q = 0 : no sampling for the impulsionpq.

q is non linear with respect to{−→

Rk

}

, Jacobian matrix

J non unity

∂F

∂q(z) =

⟨Z−1/2 [−λ + kBTG]

q=z⟨Z−1/2

q=z

with G = 1Z2

k,l1

MkMl

∂q∂Rk

∂2q∂RkRl

∂q∂Rl

,λ Lagrange multiplier associated to the constraint

σ({−→

Rk

})

= q − z = 0 (SHAKE)

Ab Initio Molecular Dynamic – p.63/67

Adiabatic dynamics

Idea : Decoupling motions alongq from other motionsUse different temperatures

One (chain) thermostat associated toqOne (chain) thermostat associated to the N-1 otherdegrees of freedomTq ≫ Tnuc

Change the mass of atoms concerned byq

Ab Initio Molecular Dynamic – p.64/67

Metadynamic

Idea : Similar to the adiabatic dynamics, usingextended Lagrangian !Reaction coordinates are included as collectivevariables (CV)sα

� Coarse� MD for CV

L = L0 +∑

α

1

2Mαsα

2 −∑

α

1

2kα [Sα(r) − sα]2

Mα large enough⇒ natural adiabatic separation

Ab Initio Molecular Dynamic – p.65/67

Metadynamic

Idea : Similar to the adiabatic dynamics, usingextended Lagrangian !Reaction coordinates are included as collectivevariables (CV)sα

� Coarse� MD for CVon top of this, potential wells are filled with gaussians

∆V (t) =∑

i

W exp

(

−|s − si(t)|

2

2δσ2

)

Important choices for W,σ, time interval betweenadding two gaussians

Ab Initio Molecular Dynamic – p.65/67

Metadynamic

Idea : Similar to the adiabatic dynamics, usingextended Lagrangian !Reaction coordinates are included as collectivevariables (CV)sα

� Coarse� MD for CV

Ab Initio Molecular Dynamic – p.65/67

Metadynamic

Idea : Similar to the adiabatic dynamics, usingextended Lagrangian !Reaction coordinates are included as collectivevariables (CV)sα

� Coarse� MD for CV

Ab Initio Molecular Dynamic – p.65/67

Metadynamic

Idea : Similar to the adiabatic dynamics, usingextended Lagrangian !Reaction coordinates are included as collectivevariables (CV)sα

� Coarse� MD for CV

Ab Initio Molecular Dynamic – p.65/67

Metadynamic

Idea : Similar to the adiabatic dynamics, usingextended Lagrangian !Reaction coordinates are included as collectivevariables (CV)sα

� Coarse� MD for CV

Ab Initio Molecular Dynamic – p.65/67

Metadynamic

Idea : Similar to the adiabatic dynamics, usingextended Lagrangian !Reaction coordinates are included as collectivevariables (CV)sα

� Coarse� MD for CV

Ab Initio Molecular Dynamic – p.65/67

How to choose a good RC ?

In practice, difficult to sam-

ple a coordinate space larger

than 3D

Chemist intuition might

fail ! !

Ab Initio Molecular Dynamic – p.66/67

Conclusion

Already many toolsbut choosing RC is still a hot topic for large systemsClassical nuclei : what about quantum effects ?

Correctionsa posteriori : tunneling, isotopic effectsPath IntegralZPE correction

Ab Initio Molecular Dynamic – p.67/67

Recommended