[ase-users] Structure Optimization
Sungsik Kim
sungsik312 at gmail.com
Wed Apr 10 15:21:49 CEST 2013
Hello,
I am Sungsik kim.
I am studying dissociative adsorption of methane on platinum.
I have a problem with structure optimization.
When I add CH4 on the slab, positions of four H atoms are changed after
optimization.
Is there any way to fix the positions of four hydrogen atoms in methane
on the slab?
Even though I used fixbondlength and fixinternals, hydrogens are not fixed
in
methane.
#################################################################
from ase import Atoms
from ase.calculators.emt import EMT
from ase.constraints import FixAtoms
from ase.optimize import QuasiNewton
from ase.io import write
import numpy as np
from ase.io import read
from ase.constraints import FixAtoms
from ase.calculators.emt import EMT
from ase.neb import NEB
from ase.optimize import QuasiNewton
from ase.visualize import view
from ase.optimize import BFGS
from ase.lattice.surface import fcc100, add_adsorbate
from ase.constraints import FixAtoms
from ase.calculators.emt import EMT
from ase.optimize import QuasiNewton
from ase.data.molecules import molecule
from ase.io import read
from ase.constraints import FixAtoms
from ase.calculators.emt import EMT
from ase.neb import NEB
from ase.optimize import BFGS
import numpy as np
import matplotlib.pylab as plt
from ase.calculators.jacapo import *
from ase.vibrations import Vibrations
from ase.optimize import FIRE
from ase.constraints import FixBondLength
from ase.constraints import FixBondLengths
# Definition of Molecules
O2=molecule('O2')
CH3=molecule('CH3')
CH3.set_tags((1,2,2,2))
CH4=molecule('CH4')
CH4.set_tags((3,4,4,4,4))
# Initial State
slab = fcc100('Pt', size=(2, 2, 1))
add_adsorbate(slab, CH4, 3, (1.4,1.4))
mask = [atom.symbol == 'Pt' for atom in slab]
slab.set_constraint(FixAtoms(mask=mask))
view(slab)
calc1 = Jacapo('inita.nc',
xc='PBE',
pw=350,
kpts=(2,2,1),
atoms=slab)
qn = QuasiNewton(slab, trajectory='inita.traj')
qn.run(fmax=0.05)
print slab.get_potential_energy()
##############################################################
Thank you for your time.
Sincerely
Sungsik
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listserv.fysik.dtu.dk/pipermail/ase-users/attachments/20130410/626f81ee/attachment.html>
More information about the ase-users
mailing list