Attachment 'N2Ru-Dissociation2.py'

Download

   1 from math import sqrt
   2 
   3 import Numeric as num
   4 
   5 from ASE.Calculators.PairPotential import PairPotential
   6 from ASE.Filters.Subset import Subset
   7 from ASE.Filters.NudgedElasticBand import NudgedElasticBand
   8 from ASE.Dynamics.MDMin import MDMin
   9 from ASE.IO.NetCDF import ReadNetCDF
  10 
  11 
  12 initial = ReadNetCDF('N2.nc')
  13 final = ReadNetCDF('2N.nc')
  14 
  15 configs0 = [initial]
  16 for i in range(7):
  17     configs0.append(initial.Copy())
  18 configs0.append(final)
  19 
  20 configs = []
  21 for config in configs0:
  22     config.SetCalculator(PairPotential())
  23     configs.append(Subset(config, indices=[-2, -1]))
  24 
  25 band = NudgedElasticBand(configs)
  26 band.SetInterpolatedPositions()
  27 
  28 # Create a quickmin object:
  29 relax = MDMin(band, dt=0.08)
  30 
  31 relax.Run(20)
  32 
  33 e0 = initial.GetPotentialEnergy()
  34 for config in configs0:
  35     d = config[-2].GetCartesianPosition() - config[-1].GetCartesianPosition()
  36     print sqrt(num.dot(d, d)), config.GetPotentialEnergy() - e0

Attached Files

To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
  • [get | view] (2005-11-17 10:40:35, 14.4 KB) [[attachment:2N.gif]]
  • [get | view] (2005-11-17 10:38:37, 14.6 KB) [[attachment:N2.gif]]
  • [get | view] (2005-11-17 10:37:12, 0.5 KB) [[attachment:N2.py]]
  • [get | view] (2005-11-17 10:41:12, 1.5 KB) [[attachment:N2Ru-Dissociation1.py]]
  • [get | view] (2006-09-27 15:11:52, 1.0 KB) [[attachment:N2Ru-Dissociation2-ANEB.py]]
  • [get | view] (2005-11-17 10:41:40, 0.9 KB) [[attachment:N2Ru-Dissociation2.py]]
  • [get | view] (2005-11-17 10:42:05, 1.0 KB) [[attachment:N2Ru-association.py]]
  • [get | view] (2005-11-17 10:38:04, 1.1 KB) [[attachment:N2Ru-relax.py]]
  • [get | view] (2005-11-17 10:37:43, 1.0 KB) [[attachment:N2Ru.py]]
  • [get | view] (2006-09-05 08:56:57, 30.4 KB) [[attachment:aneb.jpeg]]
  • [get | view] (2006-09-05 08:47:05, 23.2 KB) [[attachment:neb.jpeg]]
 All files | Selected Files: delete move to page copy to page

You are not allowed to attach a file to this page.