Ejemplo n.º 1
0
 def get_log_product_normalmode_freq(self, coords, nnegative=0):
     """return the log product of the squared normal mode frequencies
     
     Parameters
     ----------
     coords : array
     nnegative : int, optional
         number of expected negative eigenvalues
     
     Notes
     -----
     this is necessary to calculate the free energy contribution of a minimum
     """
     nzero = self.get_nzero_modes()
     freqs, vecs = self.get_normalmodes(coords)
     n, lprod = logproduct_freq2(freqs, nzero, nnegative=nnegative)
     return lprod
Ejemplo n.º 2
0
 def get_log_product_normalmode_freq(self, coords, nnegative=0):
     """return the log product of the squared normal mode frequencies
     
     Parameters
     ----------
     coords : array
     nnegative : int, optional
         number of expected negative eigenvalues
     
     Notes
     -----
     this is necessary to calculate the free energy contribution of a minimum
     """
     nzero = self.get_nzero_modes()
     freqs, vecs = self.get_normalmodes(coords)
     n, lprod = logproduct_freq2(freqs, nzero, nnegative=nnegative)
     return lprod
Ejemplo n.º 3
0
#min1 = db.transition_states()[0]

# determine point group order of system
determine_pgorder = PointGroupOrderCluster(system.get_compare_exact())
pgorder = determine_pgorder(min1.coords)
# free energy from symmetry
Fpg = np.log(pgorder) / beta

# get the hession
e, g, hess = pot.getEnergyGradientHessian(min1.coords)
# TODO: go to reduced coordinates here

# get the eigenvalues
freqs2 = normalmode_frequencies(hess)

# analyze eigenvalues
n, lnf = logproduct_freq2(freqs2, 6)

Ffrq = (n * np.log(beta) + 0.5 * lnf / beta)

# print a short summary
E = pot.getEnergy(coords)
print "point group order:", pgorder
print "number of zero eigenvalues:", (np.abs(freqs2) < 1e-4).sum()
print "number of negative eigenvalues:", (freqs2 < -1e-4).sum()
print "free energy at beta=%f:" % beta, E + Ffrq + Fpg
print "contributions from"
print "potential energy", E
print "frequencies", Ffrq
print "point group order", Fpg
Ejemplo n.º 4
0
#coords = db.transition_states()[0].coords
energy = pot.getEnergy(coords)
#coords = np.loadtxt("2.txt").flatten()
print energy

match = ExactMatchAACluster(system.aasystem)
get_pgorder = PointGroupOrderCluster(match)

coords = db.minima()[0].coords
hess = pot.NumericalHessian(coords, eps=1e-4)
metric = system.aasystem.metric_tensor(coords)

print get_pgorder(coords)
frq = normalmode_frequencies(hess, metric)
print frq
fvib = logproduct_freq2(frq, 6)[1]
print fvib

beta = 1./2.479
for m in db.minima():
    hess = pot.NumericalHessian(m.coords, eps=1e-5)
    metric = system.aasystem.metric_tensor(m.coords)

    pgorder =  get_pgorder(m.coords)
    frq = normalmode_frequencies(hess, metric, eps=1e-3)
    fvib = logproduct_freq2(frq, 6, eps=1e-3)[1]
    print fvib, 0.5*fvib /beta 
    m.pgorder = pgorder
    m.fvib = fvib 

for ts in db.transition_states():
Ejemplo n.º 5
0
# determine point group order of system
determine_pgorder = PointGroupOrderCluster(system.get_compare_exact())
pgorder = determine_pgorder(min1.coords)
# free energy from symmetry
Fpg = np.log(pgorder)/beta

# get the hession
e, g, hess = pot.getEnergyGradientHessian(min1.coords)
# TODO: go to reduced coordinates here 

# get the eigenvalues
freqs2 = normalmode_frequencies(hess)

# analyze eigenvalues
n, lnf = logproduct_freq2(freqs2, 6)

Ffrq = (n*np.log(beta) + 0.5*lnf /beta) 

# print a short summary
E = pot.getEnergy(coords)
print "point group order:", pgorder 
print "number of zero eigenvalues:", (np.abs(freqs2) < 1e-4).sum()
print "number of negative eigenvalues:", (freqs2 < -1e-4).sum()
print "free energy at beta=%f:"%beta, E + Ffrq + Fpg
print "contributions from"
print "potential energy", E
print "frequencies", Ffrq
print "point group order", Fpg

Ejemplo n.º 6
0
#coords = db.transition_states()[0].coords
energy = pot.getEnergy(coords)
#coords = np.loadtxt("2.txt").flatten()
print energy

match = ExactMatchAACluster(system.aasystem)
get_pgorder = PointGroupOrderCluster(match)

coords = db.minima()[0].coords
hess = pot.NumericalHessian(coords, eps=1e-4)
metric = system.aasystem.metric_tensor(coords)

print get_pgorder(coords)
frq = normalmode_frequencies(hess, metric)
print frq
fvib = logproduct_freq2(frq, 6)[1]
print fvib

beta = 1. / 2.479
for m in db.minima():
    hess = pot.NumericalHessian(m.coords, eps=1e-5)
    metric = system.aasystem.metric_tensor(m.coords)

    pgorder = get_pgorder(m.coords)
    frq = normalmode_frequencies(hess, metric, eps=1e-3)
    fvib = logproduct_freq2(frq, 6, eps=1e-3)[1]
    print fvib, 0.5 * fvib / beta
    m.pgorder = pgorder
    m.fvib = fvib

for ts in db.transition_states():