SetGlobas/MolHandling(fixes)/DicePlayer Translation
Fixed Numerus functions in the SetGlobals file and MolHandling, translated DicePlayer and tested till printing of initial geometry for cyc==1 Signed-off-by: Vitor Hideyoshi <vitor.h.n.batista@gmail.com>
This commit is contained in:
@@ -1,4 +1,3 @@
|
|||||||
from DPpack.MolHandling import total_mass
|
|
||||||
import os, sys
|
import os, sys
|
||||||
import math
|
import math
|
||||||
import shutil
|
import shutil
|
||||||
@@ -11,7 +10,11 @@ from numpy import linalg
|
|||||||
|
|
||||||
from DPpack.Misc import *
|
from DPpack.Misc import *
|
||||||
from DPpack.PTable import *
|
from DPpack.PTable import *
|
||||||
from DPpack.SetGlobals import *
|
|
||||||
|
env = ["OMP_STACKSIZE"]
|
||||||
|
|
||||||
|
bohr2ang = 0.52917721092
|
||||||
|
ang2bohr = 1/bohr2ang
|
||||||
|
|
||||||
# Usaremos uma nova classe que ira conter toda interação entre moleculas
|
# Usaremos uma nova classe que ira conter toda interação entre moleculas
|
||||||
|
|
||||||
@@ -173,9 +176,9 @@ class System:
|
|||||||
|
|
||||||
def print_geom(self, cycle, fh):
|
def print_geom(self, cycle, fh):
|
||||||
|
|
||||||
fh.write("{}\n".format(len(self.molecule[0])))
|
fh.write("{}\n".format(len(self.molecule[0].atom)))
|
||||||
fh.write("Cycle # {}\n".format(cycle))
|
fh.write("Cycle # {}\n".format(cycle))
|
||||||
for atom in self.molecule[0].atoms:
|
for atom in self.molecule[0].atom:
|
||||||
symbol = atomsymb[atom.na]
|
symbol = atomsymb[atom.na]
|
||||||
fh.write("{:<2s} {:>10.6f} {:>10.6f} {:>10.6f}\n".format(symbol,
|
fh.write("{:<2s} {:>10.6f} {:>10.6f} {:>10.6f}\n".format(symbol,
|
||||||
atom.rx, atom.ry, atom.rz))
|
atom.rx, atom.ry, atom.rz))
|
||||||
@@ -201,6 +204,8 @@ class Molecule:
|
|||||||
self.atom.append(a) # Inserção de um novo atomo
|
self.atom.append(a) # Inserção de um novo atomo
|
||||||
self.total_mass += a.mass
|
self.total_mass += a.mass
|
||||||
|
|
||||||
|
self.center_of_mass()
|
||||||
|
|
||||||
def center_of_mass(self):
|
def center_of_mass(self):
|
||||||
|
|
||||||
com = np.zeros(3)
|
com = np.zeros(3)
|
||||||
@@ -221,9 +226,9 @@ class Molecule:
|
|||||||
|
|
||||||
for atom in self.atom:
|
for atom in self.atom:
|
||||||
|
|
||||||
atom.rx -= com[0]
|
atom.rx -= self.com[0]
|
||||||
atom.ry -= com[1]
|
atom.ry -= self.com[1]
|
||||||
atom.rz -= com[2]
|
atom.rz -= self.com[2]
|
||||||
|
|
||||||
def charges_and_dipole(self):
|
def charges_and_dipole(self):
|
||||||
|
|
||||||
@@ -285,15 +290,14 @@ class Molecule:
|
|||||||
|
|
||||||
def inertia_tensor(self):
|
def inertia_tensor(self):
|
||||||
|
|
||||||
com = self.center_of_mass()
|
|
||||||
Ixx = Ixy = Ixz = Iyy = Iyz = Izz = 0.0
|
Ixx = Ixy = Ixz = Iyy = Iyz = Izz = 0.0
|
||||||
|
|
||||||
for atom in self.atom:
|
for atom in self.atom:
|
||||||
|
|
||||||
#### Obtain the displacement from the center of mass
|
#### Obtain the displacement from the center of mass
|
||||||
dx = atom.rx - com[0]
|
dx = atom.rx - self.com[0]
|
||||||
dy = atom.ry - com[1]
|
dy = atom.ry - self.com[1]
|
||||||
dz = atom.rz - com[2]
|
dz = atom.rz - self.com[2]
|
||||||
#### Update the diagonal components of the tensor
|
#### Update the diagonal components of the tensor
|
||||||
Ixx += atom.mass * (dy**2 + dz**2)
|
Ixx += atom.mass * (dy**2 + dz**2)
|
||||||
Iyy += atom.mass * (dz**2 + dx**2)
|
Iyy += atom.mass * (dz**2 + dx**2)
|
||||||
@@ -332,7 +336,7 @@ class Molecule:
|
|||||||
|
|
||||||
mat1 = 1/np.dot(dif_gradient, step) * np.matmul(dif_gradient.T, dif_gradient)
|
mat1 = 1/np.dot(dif_gradient, step) * np.matmul(dif_gradient.T, dif_gradient)
|
||||||
mat2 = 1/np.dot(step, np.matmul(self.hessian, step.T).T)
|
mat2 = 1/np.dot(step, np.matmul(self.hessian, step.T).T)
|
||||||
mat2 *= np.matmul( np.matmul(self.hessian, step.T), np.matmul(step, hessian) )
|
mat2 *= np.matmul( np.matmul(self.hessian, step.T), np.matmul(step, self.hessian) )
|
||||||
|
|
||||||
self.hessian += mat1 - mat2
|
self.hessian += mat1 - mat2
|
||||||
|
|
||||||
@@ -394,9 +398,8 @@ class Molecule:
|
|||||||
|
|
||||||
def print_mol_info(self, fh):
|
def print_mol_info(self, fh):
|
||||||
|
|
||||||
com = self.center_of_mass()
|
fh.write(" Center of mass = ( {:>10.4f} , {:>10.4f} , {:>10.4f} )\n".format(self.com[0],
|
||||||
fh.write(" Center of mass = ( {:>10.4f} , {:>10.4f} , {:>10.4f} )\n".format(com[0],
|
self.com[1], self.com[2]))
|
||||||
com[1], com[2]))
|
|
||||||
inertia = self.inertia_tensor()
|
inertia = self.inertia_tensor()
|
||||||
evals, evecs = self.principal_axes()
|
evals, evecs = self.principal_axes()
|
||||||
|
|
||||||
@@ -413,60 +416,13 @@ class Molecule:
|
|||||||
sizes = self.sizes_of_molecule()
|
sizes = self.sizes_of_molecule()
|
||||||
fh.write(" Characteristic lengths = ( {:>6.2f} , {:>6.2f} , {:>6.2f} )\n".format(
|
fh.write(" Characteristic lengths = ( {:>6.2f} , {:>6.2f} , {:>6.2f} )\n".format(
|
||||||
sizes[0], sizes[1], sizes[2]))
|
sizes[0], sizes[1], sizes[2]))
|
||||||
mol_mass = self.total_mass()
|
fh.write(" Total mass = {:>8.2f} au\n".format(self.total_mass))
|
||||||
fh.write(" Total mass = {:>8.2f} au\n".format(mol_mass))
|
|
||||||
|
|
||||||
chg_dip = self.charges_and_dipole()
|
chg_dip = self.charges_and_dipole()
|
||||||
fh.write(" Total charge = {:>8.4f} e\n".format(chg_dip[0]))
|
fh.write(" Total charge = {:>8.4f} e\n".format(chg_dip[0]))
|
||||||
fh.write(" Dipole moment = ( {:>9.4f} , {:>9.4f} , {:>9.4f} ) Total = {:>9.4f} Debye\n\n".format(
|
fh.write(" Dipole moment = ( {:>9.4f} , {:>9.4f} , {:>9.4f} ) Total = {:>9.4f} Debye\n\n".format(
|
||||||
chg_dip[1], chg_dip[2], chg_dip[3], chg_dip[4]))
|
chg_dip[1], chg_dip[2], chg_dip[3], chg_dip[4]))
|
||||||
|
|
||||||
def calculate_step(self, fh):
|
|
||||||
|
|
||||||
invhessian = linalg.inv(self.hessian)
|
|
||||||
pre_step = -1 * np.matmul(invhessian, self.gradient.T).T
|
|
||||||
maxstep = np.amax(np.absolute(pre_step))
|
|
||||||
factor = min(1, player['maxstep']/maxstep)
|
|
||||||
step = factor * pre_step
|
|
||||||
|
|
||||||
fh.write("\nCalculated step:\n")
|
|
||||||
pre_step_list = pre_step.tolist()
|
|
||||||
|
|
||||||
fh.write("-----------------------------------------------------------------------\n"
|
|
||||||
"Center Atomic Step (Bohr)\n"
|
|
||||||
"Number Number X Y Z\n"
|
|
||||||
"-----------------------------------------------------------------------\n")
|
|
||||||
for i in range(len(molecules[0])):
|
|
||||||
fh.write(" {:>5d} {:>3d} {:>14.9f} {:>14.9f} {:>14.9f}\n".format(
|
|
||||||
i + 1, molecules[0][i]['na'],
|
|
||||||
pre_step_list.pop(0), pre_step_list.pop(0), pre_step_list.pop(0)))
|
|
||||||
|
|
||||||
fh.write("-----------------------------------------------------------------------\n")
|
|
||||||
|
|
||||||
fh.write("Maximum step is {:>11.6}\n".format(maxstep))
|
|
||||||
fh.write("Scaling factor = {:>6.4f}\n".format(factor))
|
|
||||||
fh.write("\nFinal step (Bohr):\n")
|
|
||||||
step_list = step.tolist()
|
|
||||||
|
|
||||||
fh.write("-----------------------------------------------------------------------\n"
|
|
||||||
"Center Atomic Step (Bohr)\n"
|
|
||||||
"Number Number X Y Z\n"
|
|
||||||
"-----------------------------------------------------------------------\n")
|
|
||||||
for i in range(len(molecules[0])):
|
|
||||||
fh.write(" {:>5d} {:>3d} {:>14.9f} {:>14.9f} {:>14.9f}\n".format(
|
|
||||||
i + 1, molecules[0][i]['na'],
|
|
||||||
step_list.pop(0), step_list.pop(0), step_list.pop(0)))
|
|
||||||
|
|
||||||
fh.write("-----------------------------------------------------------------------\n")
|
|
||||||
|
|
||||||
step_max = np.amax(np.absolute(step))
|
|
||||||
step_rms = np.sqrt(np.mean(np.square(step)))
|
|
||||||
|
|
||||||
fh.write(" Max Step = {:>14.9f} RMS Step = {:>14.9f}\n\n".format(
|
|
||||||
step_max, step_rms))
|
|
||||||
|
|
||||||
return step
|
|
||||||
|
|
||||||
class Atom:
|
class Atom:
|
||||||
|
|
||||||
def __init__(self, lbl,na,rx,ry,rz,chg,eps,sig):
|
def __init__(self, lbl,na,rx,ry,rz,chg,eps,sig):
|
||||||
|
|||||||
@@ -6,16 +6,13 @@ from DPpack.MolHandling import *
|
|||||||
from DPpack.PTable import *
|
from DPpack.PTable import *
|
||||||
from DPpack.Misc import *
|
from DPpack.Misc import *
|
||||||
|
|
||||||
env = ["OMP_STACKSIZE"]
|
|
||||||
|
|
||||||
bohr2ang = 0.52917721092
|
|
||||||
ang2bohr = 1/bohr2ang
|
|
||||||
|
|
||||||
class Internal:
|
class Internal:
|
||||||
|
|
||||||
def __init__(self, infile):
|
def __init__(self, infile, outfile):
|
||||||
|
|
||||||
self.infile = infile
|
self.infile = infile
|
||||||
|
self.outfile = outfile
|
||||||
|
|
||||||
self.system = System()
|
self.system = System()
|
||||||
|
|
||||||
self.player = self.Player()
|
self.player = self.Player()
|
||||||
@@ -45,10 +42,9 @@ class Internal:
|
|||||||
def read_keywords(self):
|
def read_keywords(self):
|
||||||
|
|
||||||
try:
|
try:
|
||||||
with open(self.infile) as fh:
|
controlfile = self.infile.readlines()
|
||||||
controlfile = fh.readlines()
|
|
||||||
except EnvironmentError:
|
except EnvironmentError:
|
||||||
sys.exit("Error: cannot open file {}".format(self.infile))
|
sys.exit("Error: cannot read file {}".format(self.infile))
|
||||||
|
|
||||||
for line in controlfile:
|
for line in controlfile:
|
||||||
|
|
||||||
@@ -77,7 +73,7 @@ class Internal:
|
|||||||
elif key in ('readhessian', 'vdwforces') and value[0].lower() in ("yes", "no"):
|
elif key in ('readhessian', 'vdwforces') and value[0].lower() in ("yes", "no"):
|
||||||
setattr(self.player, key, value[0].lower())
|
setattr(self.player, key, value[0].lower())
|
||||||
|
|
||||||
elif key in ('maxcyc', 'initcyc', 'nprocs', 'altsteps', 'switchcyc'):
|
elif key in ('maxcyc', 'nprocs', 'altsteps', 'switchcyc'):
|
||||||
err = "Error: expected a positive integer for keyword {} in file {}".format(key, self.infile)
|
err = "Error: expected a positive integer for keyword {} in file {}".format(key, self.infile)
|
||||||
try:
|
try:
|
||||||
new_value = int(value[0])
|
new_value = int(value[0])
|
||||||
@@ -95,7 +91,7 @@ class Internal:
|
|||||||
if new_value < 0.01:
|
if new_value < 0.01:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
else:
|
else:
|
||||||
setattr(self.player, key).append(new_value)
|
setattr(self.player, key, new_value)
|
||||||
except ValueError:
|
except ValueError:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
|
|
||||||
@@ -136,7 +132,7 @@ class Internal:
|
|||||||
if new_value < 1:
|
if new_value < 1:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
else:
|
else:
|
||||||
setattr(self.dice, key, new_value)
|
getattr(self.dice, key).append(new_value)
|
||||||
elif i == 0:
|
elif i == 0:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
else:
|
else:
|
||||||
@@ -153,7 +149,7 @@ class Internal:
|
|||||||
if new_value < 1:
|
if new_value < 1:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
else:
|
else:
|
||||||
setattr(self.dice, key, new_value)
|
getattr(self.dice, key).append(new_value)
|
||||||
elif i < 2:
|
elif i < 2:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
else:
|
else:
|
||||||
@@ -179,7 +175,7 @@ class Internal:
|
|||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
for i in range (2):
|
for i in range (2):
|
||||||
try:
|
try:
|
||||||
setattr(self.gaussian, key)[i] = int(value[i])
|
getattr(self.gaussian, key)[i] = int(value[i])
|
||||||
except ValueError:
|
except ValueError:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
|
|
||||||
@@ -192,24 +188,24 @@ class Internal:
|
|||||||
elif key == 'pop' and value[0].lower() in ("chelpg", "mk", "nbo"):
|
elif key == 'pop' and value[0].lower() in ("chelpg", "mk", "nbo"):
|
||||||
setattr(self.gaussian, key, value[0].lower())
|
setattr(self.gaussian, key, value[0].lower())
|
||||||
|
|
||||||
#### Read the Molcas related keywords
|
# #### Read the Molcas related keywords
|
||||||
elif key in self.molcas_keywords and len(value) != 0: ## 'value' is not empty!
|
# elif key in self.molcas_keywords and len(value) != 0: ## 'value' is not empty!
|
||||||
|
|
||||||
if key == 'root': # If defined, must be well defined (only positive integer values)
|
# if key == 'root': # If defined, must be well defined (only positive integer values)
|
||||||
err = "Error: expected a positive integer for keyword {} in file {}".format(key, self.infile)
|
# err = "Error: expected a positive integer for keyword {} in file {}".format(key, self.infile)
|
||||||
if not value[0].isdigit():
|
# if not value[0].isdigit():
|
||||||
sys.exit(err)
|
# sys.exit(err)
|
||||||
new_value = int(value[0])
|
# new_value = int(value[0])
|
||||||
if new_value >= 1:
|
# if new_value >= 1:
|
||||||
setattr(self.molcas, key, new_value)
|
# setattr(self.molcas, key, new_value)
|
||||||
|
|
||||||
elif key in ('mbottom', 'orbfile'):
|
# elif key in ('mbottom', 'orbfile'):
|
||||||
setattr(self.molcas, key, value[0])
|
# setattr(self.molcas, key, value[0])
|
||||||
|
|
||||||
elif key == 'basis':
|
# elif key == 'basis':
|
||||||
setattr(self.molcas ,key, value[0])
|
# setattr(self.molcas ,key, value[0])
|
||||||
|
|
||||||
#### End
|
# #### End
|
||||||
|
|
||||||
|
|
||||||
def check_keywords(self):
|
def check_keywords(self):
|
||||||
@@ -225,10 +221,10 @@ class Internal:
|
|||||||
if self.dice.dens == None:
|
if self.dice.dens == None:
|
||||||
sys.exit("Error: 'dens' keyword not specified in file {}".format(self.infile))
|
sys.exit("Error: 'dens' keyword not specified in file {}".format(self.infile))
|
||||||
|
|
||||||
if len(self.dice.nmol) == 0:
|
if self.dice.nmol == 0:
|
||||||
sys.exit("Error: 'nmol' keyword not defined appropriately in file {}".format(self.infile))
|
sys.exit("Error: 'nmol' keyword not defined appropriately in file {}".format(self.infile))
|
||||||
|
|
||||||
if len(self.dice.nstep) == 0:
|
if self.dice.nstep == 0:
|
||||||
sys.exit("Error: 'nstep' keyword not defined appropriately in file {}".format(self.infile))
|
sys.exit("Error: 'nstep' keyword not defined appropriately in file {}".format(self.infile))
|
||||||
|
|
||||||
## Check only if QM program is Gaussian:
|
## Check only if QM program is Gaussian:
|
||||||
@@ -290,22 +286,22 @@ class Internal:
|
|||||||
# isave value is always the nearest multiple of 100
|
# isave value is always the nearest multiple of 100
|
||||||
self.dice.isave = round(self.dice.isave / 100) * 100
|
self.dice.isave = round(self.dice.isave / 100) * 100
|
||||||
|
|
||||||
def print_keywords(self, fh):
|
def print_keywords(self):
|
||||||
|
|
||||||
fh.write("##########################################################################################\n"
|
self.outfile.write("##########################################################################################\n"
|
||||||
"############# Welcome to DICEPLAYER version 1.0 #############\n"
|
"############# Welcome to DICEPLAYER version 1.0 #############\n"
|
||||||
"##########################################################################################\n"
|
"##########################################################################################\n"
|
||||||
"\n")
|
"\n")
|
||||||
fh.write("Your python version is {}\n".format(sys.version))
|
self.outfile.write("Your python version is {}\n".format(sys.version))
|
||||||
fh.write("\n")
|
self.outfile.write("\n")
|
||||||
fh.write("Program started on {}\n".format(weekday_date_time()))
|
self.outfile.write("Program started on {}\n".format(weekday_date_time()))
|
||||||
fh.write("\n")
|
self.outfile.write("\n")
|
||||||
fh.write("Environment variables:\n")
|
self.outfile.write("Environment variables:\n")
|
||||||
for var in env:
|
for var in env:
|
||||||
fh.write("{} = {}\n".format(var,
|
self.outfile.write("{} = {}\n".format(var,
|
||||||
(os.environ[var] if var in os.environ else "Not set")))
|
(os.environ[var] if var in os.environ else "Not set")))
|
||||||
|
|
||||||
fh.write("\n==========================================================================================\n"
|
self.outfile.write("\n==========================================================================================\n"
|
||||||
" CONTROL variables being used in this run:\n"
|
" CONTROL variables being used in this run:\n"
|
||||||
"------------------------------------------------------------------------------------------\n"
|
"------------------------------------------------------------------------------------------\n"
|
||||||
"\n")
|
"\n")
|
||||||
@@ -314,13 +310,13 @@ class Internal:
|
|||||||
if getattr(self.player,key) != None:
|
if getattr(self.player,key) != None:
|
||||||
if isinstance(getattr(self.player,key), list):
|
if isinstance(getattr(self.player,key), list):
|
||||||
string = " ".join(str(x) for x in getattr(self.player,key))
|
string = " ".join(str(x) for x in getattr(self.player,key))
|
||||||
fh.write("{} = {}\n".format(key, string))
|
self.outfile.write("{} = {}\n".format(key, string))
|
||||||
else:
|
else:
|
||||||
fh.write("{} = {}\n".format(key, getattr(self.player,key)))
|
self.outfile.write("{} = {}\n".format(key, getattr(self.player,key)))
|
||||||
|
|
||||||
fh.write("\n")
|
self.outfile.write("\n")
|
||||||
|
|
||||||
fh.write("------------------------------------------------------------------------------------------\n"
|
self.outfile.write("------------------------------------------------------------------------------------------\n"
|
||||||
" DICE variables being used in this run:\n"
|
" DICE variables being used in this run:\n"
|
||||||
"------------------------------------------------------------------------------------------\n"
|
"------------------------------------------------------------------------------------------\n"
|
||||||
"\n")
|
"\n")
|
||||||
@@ -329,15 +325,15 @@ class Internal:
|
|||||||
if getattr(self.dice,key) != None:
|
if getattr(self.dice,key) != None:
|
||||||
if isinstance(getattr(self.dice,key), list):
|
if isinstance(getattr(self.dice,key), list):
|
||||||
string = " ".join(str(x) for x in getattr(self.dice,key))
|
string = " ".join(str(x) for x in getattr(self.dice,key))
|
||||||
fh.write("{} = {}\n".format(key, string))
|
self.outfile.write("{} = {}\n".format(key, string))
|
||||||
else:
|
else:
|
||||||
fh.write("{} = {}\n".format(key, getattr(self.dice,key)))
|
self.outfile.write("{} = {}\n".format(key, getattr(self.dice,key)))
|
||||||
|
|
||||||
fh.write("\n")
|
self.outfile.write("\n")
|
||||||
|
|
||||||
if self.player.qmprog in ("g03", "g09", "g16"):
|
if self.player.qmprog in ("g03", "g09", "g16"):
|
||||||
|
|
||||||
fh.write("------------------------------------------------------------------------------------------\n"
|
self.outfile.write("------------------------------------------------------------------------------------------\n"
|
||||||
" GAUSSIAN variables being used in this run:\n"
|
" GAUSSIAN variables being used in this run:\n"
|
||||||
"------------------------------------------------------------------------------------------\n"
|
"------------------------------------------------------------------------------------------\n"
|
||||||
"\n")
|
"\n")
|
||||||
@@ -346,15 +342,15 @@ class Internal:
|
|||||||
if getattr(self.gaussian,key) != None:
|
if getattr(self.gaussian,key) != None:
|
||||||
if isinstance(getattr(self.gaussian,key), list):
|
if isinstance(getattr(self.gaussian,key), list):
|
||||||
string = " ".join(str(x) for x in getattr(self.gaussian,key))
|
string = " ".join(str(x) for x in getattr(self.gaussian,key))
|
||||||
fh.write("{} = {}\n".format(key, string))
|
self.outfile.write("{} = {}\n".format(key, string))
|
||||||
else:
|
else:
|
||||||
fh.write("{} = {}\n".format(key, getattr(self.gaussian,key)))
|
self.outfile.write("{} = {}\n".format(key, getattr(self.gaussian,key)))
|
||||||
|
|
||||||
fh.write("\n")
|
self.outfile.write("\n")
|
||||||
|
|
||||||
# elif self.player.qmprog == "molcas":
|
# elif self.player.qmprog == "molcas":
|
||||||
|
|
||||||
# fh.write("------------------------------------------------------------------------------------------\n"
|
# self.outfile.write("------------------------------------------------------------------------------------------\n"
|
||||||
# " MOLCAS variables being used in this run:\n"
|
# " MOLCAS variables being used in this run:\n"
|
||||||
# "------------------------------------------------------------------------------------------\n"
|
# "------------------------------------------------------------------------------------------\n"
|
||||||
# "\n")
|
# "\n")
|
||||||
@@ -363,11 +359,11 @@ class Internal:
|
|||||||
# if molcas[key] != None:
|
# if molcas[key] != None:
|
||||||
# if isinstance(molcas[key], list):
|
# if isinstance(molcas[key], list):
|
||||||
# string = " ".join(str(x) for x in molcas[key])
|
# string = " ".join(str(x) for x in molcas[key])
|
||||||
# fh.write("{} = {}\n".format(key, string))
|
# self.outfile.write("{} = {}\n".format(key, string))
|
||||||
# else:
|
# else:
|
||||||
# fh.write("{} = {}\n".format(key, molcas[key]))
|
# self.outfile.write("{} = {}\n".format(key, molcas[key]))
|
||||||
|
|
||||||
# fh.write("\n")
|
# self.outfile.write("\n")
|
||||||
|
|
||||||
def read_potential(self): # Deve ser atualizado para o uso de
|
def read_potential(self): # Deve ser atualizado para o uso de
|
||||||
|
|
||||||
@@ -390,7 +386,6 @@ class Internal:
|
|||||||
if ntypes != len(self.dice.nmol):
|
if ntypes != len(self.dice.nmol):
|
||||||
sys.exit("Error: number of molecule types in file {} must match that of 'nmol' keyword in file {}".format(
|
sys.exit("Error: number of molecule types in file {} must match that of 'nmol' keyword in file {}".format(
|
||||||
self.dice.ljname, self.infile))
|
self.dice.ljname, self.infile))
|
||||||
|
|
||||||
line = 2
|
line = 2
|
||||||
for i in range(ntypes):
|
for i in range(ntypes):
|
||||||
|
|
||||||
@@ -400,7 +395,7 @@ class Internal:
|
|||||||
sys.exit("Error: expected an integer in line {} of file {}".format(line, self.dice.ljname))
|
sys.exit("Error: expected an integer in line {} of file {}".format(line, self.dice.ljname))
|
||||||
|
|
||||||
nsites = int(nsites)
|
nsites = int(nsites)
|
||||||
self.system.add_type(Molecule())
|
self.system.add_type(nsites,Molecule())
|
||||||
|
|
||||||
for j in range(nsites):
|
for j in range(nsites):
|
||||||
|
|
||||||
@@ -410,8 +405,6 @@ class Internal:
|
|||||||
if len(new_atom) < 8:
|
if len(new_atom) < 8:
|
||||||
sys.exit("Error: expected at least 8 fields in line {} of file {}".format(line, self.dice.ljname))
|
sys.exit("Error: expected at least 8 fields in line {} of file {}".format(line, self.dice.ljname))
|
||||||
|
|
||||||
self.system.molecule[i].add_atom()
|
|
||||||
|
|
||||||
if not new_atom[0].isdigit():
|
if not new_atom[0].isdigit():
|
||||||
sys.exit("Error: expected an integer in field 1, line {} of file {}".format(line, self.dice.ljname))
|
sys.exit("Error: expected an integer in field 1, line {} of file {}".format(line, self.dice.ljname))
|
||||||
lbl = int(new_atom[0])
|
lbl = int(new_atom[0])
|
||||||
@@ -468,7 +461,7 @@ class Internal:
|
|||||||
"Error: expected a positive float after 'mass=' in field 9, line {} of file {}".format(
|
"Error: expected a positive float after 'mass=' in field 9, line {} of file {}".format(
|
||||||
line, self.dice.ljname))
|
line, self.dice.ljname))
|
||||||
|
|
||||||
self.system.molecule[i].add_atom(Atom(lbl,na,rx,ry,rz,chg,eps,sig,mass))
|
self.system.molecule[i].add_atom(Atom(lbl,na,rx,ry,rz,chg,eps,sig))
|
||||||
|
|
||||||
to_delete = ['lbl','na','rx','ry','rz','chg','eps','sig','mass']
|
to_delete = ['lbl','na','rx','ry','rz','chg','eps','sig','mass']
|
||||||
for _var in to_delete:
|
for _var in to_delete:
|
||||||
@@ -476,44 +469,44 @@ class Internal:
|
|||||||
exec(f'del {_var}')
|
exec(f'del {_var}')
|
||||||
|
|
||||||
|
|
||||||
def print_potential(self, fh):
|
def print_potential(self):
|
||||||
|
|
||||||
formatstr = "{:<3d} {:>3d} {:>10.5f} {:>10.5f} {:>10.5f} {:>10.6f} {:>9.5f} {:>7.4f} {:>9.4f}\n"
|
formatstr = "{:<3d} {:>3d} {:>10.5f} {:>10.5f} {:>10.5f} {:>10.6f} {:>9.5f} {:>7.4f} {:>9.4f}\n"
|
||||||
fh.write("\n"
|
self.outfile.write("\n"
|
||||||
"==========================================================================================\n")
|
"==========================================================================================\n")
|
||||||
fh.write(" Potential parameters from file {}:\n".format(self.dice.ljname))
|
self.outfile.write(" Potential parameters from file {}:\n".format(self.dice.ljname))
|
||||||
fh.write("------------------------------------------------------------------------------------------\n"
|
self.outfile.write("------------------------------------------------------------------------------------------\n"
|
||||||
"\n")
|
"\n")
|
||||||
|
|
||||||
fh.write("Combination rule: {}\n".format(self.dice.combrule))
|
self.outfile.write("Combination rule: {}\n".format(self.dice.combrule))
|
||||||
fh.write("Types of molecules: {}\n\n".format(len(self.system.molecule)))
|
self.outfile.write("Types of molecules: {}\n\n".format(len(self.system.molecule)))
|
||||||
|
|
||||||
i = 0
|
i = 0
|
||||||
for mol in self.system.molecule:
|
for mol in self.system.molecule:
|
||||||
i += 1
|
i += 1
|
||||||
fh.write("{} atoms in molecule type {}:\n".format(len(mol), i))
|
self.outfile.write("{} atoms in molecule type {}:\n".format(len(mol.atom), i))
|
||||||
fh.write("---------------------------------------------------------------------------------\n"
|
self.outfile.write("---------------------------------------------------------------------------------\n"
|
||||||
"Lbl AN X Y Z Charge Epsilon Sigma Mass\n")
|
"Lbl AN X Y Z Charge Epsilon Sigma Mass\n")
|
||||||
fh.write("---------------------------------------------------------------------------------\n")
|
self.outfile.write("---------------------------------------------------------------------------------\n")
|
||||||
|
|
||||||
for atom in mol.atom:
|
for atom in mol.atom:
|
||||||
|
|
||||||
fh.write(formatstr.format(atom.lbl, atom.na, atom.rx, atom.ry, atom.rz,
|
self.outfile.write(formatstr.format(atom.lbl, atom.na, atom.rx, atom.ry, atom.rz,
|
||||||
atom.chg, atom.eps, atom.sig, atom.mass))
|
atom.chg, atom.eps, atom.sig, atom.mass))
|
||||||
|
|
||||||
fh.write("\n")
|
self.outfile.write("\n")
|
||||||
|
|
||||||
if self.player.ghosts == "yes" or self.player.lps == "yes":
|
if self.player.ghosts == "yes" or self.player.lps == "yes":
|
||||||
fh.write("\n"
|
self.outfile.write("\n"
|
||||||
"------------------------------------------------------------------------------------------\n"
|
"------------------------------------------------------------------------------------------\n"
|
||||||
" Aditional potential parameters:\n"
|
" Aditional potential parameters:\n"
|
||||||
"------------------------------------------------------------------------------------------\n")
|
"------------------------------------------------------------------------------------------\n")
|
||||||
|
|
||||||
# if player['ghosts'] == "yes":
|
# if player['ghosts'] == "yes":
|
||||||
|
|
||||||
# fh.write("\n")
|
# self.outfile.write("\n")
|
||||||
# fh.write("{} ghost atoms appended to molecule type 1 at:\n".format(len(ghost_types)))
|
# self.outfile.write("{} ghost atoms appended to molecule type 1 at:\n".format(len(ghost_types)))
|
||||||
# fh.write("---------------------------------------------------------------------------------\n")
|
# self.outfile.write("---------------------------------------------------------------------------------\n")
|
||||||
|
|
||||||
# atoms_string = ""
|
# atoms_string = ""
|
||||||
# for ghost in ghost_types:
|
# for ghost in ghost_types:
|
||||||
@@ -522,19 +515,19 @@ class Internal:
|
|||||||
# atoms_string += "{}{} ".format(atom_sym,atom)
|
# atoms_string += "{}{} ".format(atom_sym,atom)
|
||||||
|
|
||||||
# if ghost['type'] == "g":
|
# if ghost['type'] == "g":
|
||||||
# fh.write(textwrap.fill("* Geometric center of atoms {}".format(atoms_string), 80))
|
# self.outfile.write(textwrap.fill("* Geometric center of atoms {}".format(atoms_string), 80))
|
||||||
# elif ghost['type'] == "m":
|
# elif ghost['type'] == "m":
|
||||||
# fh.write(textwrap.fill("* Center of mass of atoms {}".format(atoms_string), 80))
|
# self.outfile.write(textwrap.fill("* Center of mass of atoms {}".format(atoms_string), 80))
|
||||||
# elif ghost['type'] == "z":
|
# elif ghost['type'] == "z":
|
||||||
# fh.write(textwrap.fill("* Center of atomic number of atoms {}".format(atoms_string), 80))
|
# self.outfile.write(textwrap.fill("* Center of atomic number of atoms {}".format(atoms_string), 80))
|
||||||
|
|
||||||
# fh.write("\n")
|
# self.outfile.write("\n")
|
||||||
|
|
||||||
# if player['lps'] == 'yes':
|
# if player['lps'] == 'yes':
|
||||||
|
|
||||||
# fh.write("\n")
|
# self.outfile.write("\n")
|
||||||
# fh.write("{} lone pairs appended to molecule type 1:\n".format(len(lp_types)))
|
# self.outfile.write("{} lone pairs appended to molecule type 1:\n".format(len(lp_types)))
|
||||||
# fh.write("---------------------------------------------------------------------------------\n")
|
# self.outfile.write("---------------------------------------------------------------------------------\n")
|
||||||
|
|
||||||
# for lp in lp_types:
|
# for lp in lp_types:
|
||||||
# # LP type 1 or 2
|
# # LP type 1 or 2
|
||||||
@@ -546,36 +539,33 @@ class Internal:
|
|||||||
# atom3_num = lp['numbers'][2]
|
# atom3_num = lp['numbers'][2]
|
||||||
# atom3_sym = atomsymb[ molecules[0][atom3_num - 1]['na'] ].strip()
|
# atom3_sym = atomsymb[ molecules[0][atom3_num - 1]['na'] ].strip()
|
||||||
|
|
||||||
# fh.write(textwrap.fill(
|
# self.outfile.write(textwrap.fill(
|
||||||
# "* Type {} on atom {}{} with {}{} {}{}. Alpha = {:<5.1f} Deg and D = {:<4.2f} Angs".format(
|
# "* Type {} on atom {}{} with {}{} {}{}. Alpha = {:<5.1f} Deg and D = {:<4.2f} Angs".format(
|
||||||
# lp['type'], atom1_sym, atom1_num, atom2_sym, atom2_num, atom3_sym, atom3_num, lp['alpha'],
|
# lp['type'], atom1_sym, atom1_num, atom2_sym, atom2_num, atom3_sym, atom3_num, lp['alpha'],
|
||||||
# lp['dist']), 86))
|
# lp['dist']), 86))
|
||||||
# fh.write("\n")
|
# self.outfile.write("\n")
|
||||||
|
|
||||||
# # Other LP types
|
# # Other LP types
|
||||||
|
|
||||||
fh.write("\n"
|
self.outfile.write("\n"
|
||||||
"==========================================================================================\n")
|
"==========================================================================================\n")
|
||||||
|
|
||||||
return
|
def check_executables(self):
|
||||||
|
|
||||||
|
self.outfile.write("\n")
|
||||||
def check_executables(self, fh):
|
self.outfile.write(90 * "=")
|
||||||
|
self.outfile.write("\n\n")
|
||||||
fh.write("\n")
|
|
||||||
fh.write(90 * "=")
|
|
||||||
fh.write("\n\n")
|
|
||||||
|
|
||||||
dice_path = shutil.which(self.dice.progname)
|
dice_path = shutil.which(self.dice.progname)
|
||||||
if dice_path != None:
|
if dice_path != None:
|
||||||
fh.write("Program {} found at {}\n".format(self.dice.progname, dice_path))
|
self.outfile.write("Program {} found at {}\n".format(self.dice.progname, dice_path))
|
||||||
self.dice.path = dice_path
|
self.dice.path = dice_path
|
||||||
else:
|
else:
|
||||||
sys.exit("Error: cannot find dice executable")
|
sys.exit("Error: cannot find dice executable")
|
||||||
|
|
||||||
qmprog_path = shutil.which(self.gaussian.qmprog)
|
qmprog_path = shutil.which(self.gaussian.qmprog)
|
||||||
if qmprog_path != None:
|
if qmprog_path != None:
|
||||||
fh.write("Program {} found at {}\n".format(self.gaussian.qmprog, qmprog_path))
|
self.outfile.write("Program {} found at {}\n".format(self.gaussian.qmprog, qmprog_path))
|
||||||
self.gaussian.path = qmprog_path
|
self.gaussian.path = qmprog_path
|
||||||
else:
|
else:
|
||||||
sys.exit("Error: cannot find {} executable".format(self.gaussian.qmprog))
|
sys.exit("Error: cannot find {} executable".format(self.gaussian.qmprog))
|
||||||
@@ -583,16 +573,211 @@ class Internal:
|
|||||||
if self.gaussian.qmprog in ("g03", "g09", "g16"):
|
if self.gaussian.qmprog in ("g03", "g09", "g16"):
|
||||||
formchk_path = shutil.which("formchk")
|
formchk_path = shutil.which("formchk")
|
||||||
if formchk_path != None:
|
if formchk_path != None:
|
||||||
fh.write("Program formchk found at {}\n".format(formchk_path))
|
self.outfile.write("Program formchk found at {}\n".format(formchk_path))
|
||||||
else:
|
else:
|
||||||
sys.exit("Error: cannot find formchk executable")
|
sys.exit("Error: cannot find formchk executable")
|
||||||
|
|
||||||
|
|
||||||
|
def calculate_step(self):
|
||||||
|
|
||||||
|
invhessian = linalg.inv(self.system.molecule[0].hessian)
|
||||||
|
pre_step = -1 * np.matmul(invhessian, self.system.molecule[0].gradient.T).T
|
||||||
|
maxstep = np.amax(np.absolute(pre_step))
|
||||||
|
factor = min(1, self.player.maxstep/maxstep)
|
||||||
|
step = factor * pre_step
|
||||||
|
|
||||||
|
self.player.outfile.write("\nCalculated step:\n")
|
||||||
|
pre_step_list = pre_step.tolist()
|
||||||
|
|
||||||
|
self.player.outfile.write("-----------------------------------------------------------------------\n"
|
||||||
|
"Center Atomic Step (Bohr)\n"
|
||||||
|
"Number Number X Y Z\n"
|
||||||
|
"-----------------------------------------------------------------------\n")
|
||||||
|
for i in range(len(self.system.molecule[0].atom)):
|
||||||
|
self.player.outfile.write(" {:>5d} {:>3d} {:>14.9f} {:>14.9f} {:>14.9f}\n".format(
|
||||||
|
i + 1, self.system.molecule[0].atom[i].na,
|
||||||
|
pre_step_list.pop(0), pre_step_list.pop(0), pre_step_list.pop(0)))
|
||||||
|
|
||||||
|
self.player.outfile.write("-----------------------------------------------------------------------\n")
|
||||||
|
|
||||||
|
self.player.outfile.write("Maximum step is {:>11.6}\n".format(maxstep))
|
||||||
|
self.player.outfile.write("Scaling factor = {:>6.4f}\n".format(factor))
|
||||||
|
self.player.outfile.write("\nFinal step (Bohr):\n")
|
||||||
|
step_list = step.tolist()
|
||||||
|
|
||||||
|
self.player.outfile.write("-----------------------------------------------------------------------\n"
|
||||||
|
"Center Atomic Step (Bohr)\n"
|
||||||
|
"Number Number X Y Z\n"
|
||||||
|
"-----------------------------------------------------------------------\n")
|
||||||
|
for i in range(len(self.system.molecule[0].atom)):
|
||||||
|
self.player.outfile.write(" {:>5d} {:>3d} {:>14.9f} {:>14.9f} {:>14.9f}\n".format(
|
||||||
|
i + 1, self.system.molecule[0].atom[i].na,
|
||||||
|
step_list.pop(0), step_list.pop(0), step_list.pop(0)))
|
||||||
|
|
||||||
|
self.player.outfile.write("-----------------------------------------------------------------------\n")
|
||||||
|
|
||||||
|
step_max = np.amax(np.absolute(step))
|
||||||
|
step_rms = np.sqrt(np.mean(np.square(step)))
|
||||||
|
|
||||||
|
self.player.outfile.write(" Max Step = {:>14.9f} RMS Step = {:>14.9f}\n\n".format(
|
||||||
|
step_max, step_rms))
|
||||||
|
|
||||||
|
return step
|
||||||
|
|
||||||
|
def read_initial_cicle(self):
|
||||||
|
|
||||||
|
try:
|
||||||
|
with open(self.infile) as self.outfile:
|
||||||
|
controlfile = self.outfile.readlines()
|
||||||
|
except EnvironmentError:
|
||||||
|
sys.exit("Error: cannot open file {}".format(self.infile))
|
||||||
|
|
||||||
|
for line in controlfile:
|
||||||
|
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
def populate_asec_vdw(self, cycle):
|
||||||
|
|
||||||
|
asec_charges = [] # (rx, ry, rz, chg)
|
||||||
|
vdw_meanfield = [] # (rx, ry, rz, eps, sig)
|
||||||
|
|
||||||
|
if self.dice.nstep[-1] % self.dice.isave == 0:
|
||||||
|
nconfigs = round(self.dice.nstep[-1] / self.dice.isave)
|
||||||
|
else:
|
||||||
|
nconfigs = int(self.dice.nstep[-1] / self.dice.isave)
|
||||||
|
|
||||||
|
norm_factor = nconfigs * self.player.nprocs
|
||||||
|
|
||||||
|
nsitesref = len(self.system.molecule[0]) + len(ghost_atoms) + len(lp_atoms)
|
||||||
|
|
||||||
|
nsites_total = dice['nmol'][0] * nsitesref
|
||||||
|
for i in range(1, len(dice['nmol'])):
|
||||||
|
nsites_total += dice['nmol'][i] * len(molecules[i])
|
||||||
|
|
||||||
|
thickness = []
|
||||||
|
picked_mols = []
|
||||||
|
|
||||||
|
for proc in range(1, player['nprocs'] + 1): ## Run over folders
|
||||||
|
|
||||||
|
path = "step{:02d}".format(cycle) + os.sep + "p{:02d}".format(proc)
|
||||||
|
file = path + os.sep + dice['outname'] + ".xyz"
|
||||||
|
if not os.path.isfile(file):
|
||||||
|
sys.exit("Error: cannot find file {}".format(file))
|
||||||
|
try:
|
||||||
|
with open(file) as xyzfh:
|
||||||
|
xyzfile = xyzfh.readlines()
|
||||||
|
except:
|
||||||
|
sys.exit("Error: cannot open file {}".format(file))
|
||||||
|
|
||||||
|
for config in range(nconfigs): ## Run over configs in a folder
|
||||||
|
|
||||||
|
if int( xyzfile.pop(0).split()[0] ) != nsites_total:
|
||||||
|
sys.exit("Error: wrong number of sites in file {}".format(file))
|
||||||
|
|
||||||
|
box = xyzfile.pop(0).split()[-3:]
|
||||||
|
box = [ float(box[0]), float(box[1]), float(box[2]) ]
|
||||||
|
sizes = sizes_of_molecule(molecules[0])
|
||||||
|
thickness.append( min([ (box[0] - sizes[0])/2, (box[1] - sizes[1])/2,
|
||||||
|
(box[2] - sizes[2])/2 ]) )
|
||||||
|
|
||||||
|
xyzfile = xyzfile[nsitesref:] ## Skip the first (reference) molecule
|
||||||
|
mol_count = 0
|
||||||
|
for type in range(len(dice['nmol'])): ## Run over types of molecules
|
||||||
|
|
||||||
|
if type == 0:
|
||||||
|
nmols = dice['nmol'][0] - 1
|
||||||
|
else:
|
||||||
|
nmols = dice['nmol'][type]
|
||||||
|
|
||||||
|
for mol in range(nmols): ## Run over molecules of each type
|
||||||
|
|
||||||
|
new_molecule = []
|
||||||
|
for site in range(len(molecules[type])): ## Run over sites of each molecule
|
||||||
|
|
||||||
|
new_molecule.append({})
|
||||||
|
line = xyzfile.pop(0).split()
|
||||||
|
|
||||||
|
if line[0].title() != atomsymb[molecules[type][site]['na']].strip():
|
||||||
|
sys.exit("Error reading file {}".format(file))
|
||||||
|
|
||||||
|
new_molecule[site]['na'] = molecules[type][site]['na']
|
||||||
|
new_molecule[site]['rx'] = float(line[1])
|
||||||
|
new_molecule[site]['ry'] = float(line[2])
|
||||||
|
new_molecule[site]['rz'] = float(line[3])
|
||||||
|
new_molecule[site]['chg'] = molecules[type][site]['chg']
|
||||||
|
new_molecule[site]['eps'] = molecules[type][site]['eps']
|
||||||
|
new_molecule[site]['sig'] = molecules[type][site]['sig']
|
||||||
|
|
||||||
|
dist = minimum_distance(molecules[0], new_molecule)
|
||||||
|
if dist < thickness[-1]:
|
||||||
|
mol_count += 1
|
||||||
|
for atom in new_molecule:
|
||||||
|
asec_charges.append({})
|
||||||
|
vdw_meanfield.append({})
|
||||||
|
|
||||||
|
asec_charges[-1]['rx'] = atom['rx']
|
||||||
|
asec_charges[-1]['ry'] = atom['ry']
|
||||||
|
asec_charges[-1]['rz'] = atom['rz']
|
||||||
|
asec_charges[-1]['chg'] = atom['chg'] / norm_factor
|
||||||
|
|
||||||
|
if player['vdwforces'] == "yes":
|
||||||
|
vdw_meanfield[-1]['rx'] = atom['rx']
|
||||||
|
vdw_meanfield[-1]['ry'] = atom['ry']
|
||||||
|
vdw_meanfield[-1]['rz'] = atom['rz']
|
||||||
|
vdw_meanfield[-1]['eps'] = atom['eps']
|
||||||
|
vdw_meanfield[-1]['sig'] = atom['sig']
|
||||||
|
|
||||||
|
#### Read lines with ghosts or lps in molecules of type 0 (reference)
|
||||||
|
#### and, if dist < thickness, appends to asec
|
||||||
|
if type == 0:
|
||||||
|
for ghost in ghost_atoms:
|
||||||
|
line = xyzfile.pop(0).split()
|
||||||
|
if line[0] != dice_ghost_label:
|
||||||
|
sys.exit("Error reading file {}".format(file))
|
||||||
|
if dist < thickness[-1]:
|
||||||
|
asec_charges.append({})
|
||||||
|
asec_charges[-1]['rx'] = float(line[1])
|
||||||
|
asec_charges[-1]['ry'] = float(line[2])
|
||||||
|
asec_charges[-1]['rz'] = float(line[3])
|
||||||
|
asec_charges[-1]['chg'] = ghost['chg'] / norm_factor
|
||||||
|
|
||||||
|
for lp in lp_atoms:
|
||||||
|
line = xyzfile.pop(0).split()
|
||||||
|
if line[0] != dice_ghost_label:
|
||||||
|
sys.exit("Error reading file {}".format(file))
|
||||||
|
if dist < thickness[-1]:
|
||||||
|
asec_charges.append({})
|
||||||
|
asec_charges[-1]['rx'] = float(line[1])
|
||||||
|
asec_charges[-1]['ry'] = float(line[2])
|
||||||
|
asec_charges[-1]['rz'] = float(line[3])
|
||||||
|
asec_charges[-1]['chg'] = lp['chg'] / norm_factor
|
||||||
|
|
||||||
|
picked_mols.append(mol_count)
|
||||||
|
|
||||||
|
self.player.outfile.write("Done\n")
|
||||||
|
|
||||||
|
string = "In average, {:^7.2f} molecules ".format(sum(picked_mols)/norm_factor)
|
||||||
|
string += "were selected from each of the {} configurations ".format(len(picked_mols))
|
||||||
|
string += "of the production simulations to form the ASEC, comprising a shell with "
|
||||||
|
string += "minimum thickness of {:>6.2f} Angstrom\n".format(sum(thickness)/norm_factor)
|
||||||
|
|
||||||
|
self.player.outfile.write(textwrap.fill(string, 86))
|
||||||
|
self.player.outfile.write("\n")
|
||||||
|
|
||||||
|
otherfh = open("ASEC.dat", "w")
|
||||||
|
for charge in asec_charges:
|
||||||
|
otherfh.write("{:>10.5f} {:>10.5f} {:>10.5f} {:>11.8f}\n".format(
|
||||||
|
charge['rx'], charge['ry'], charge['rz'], charge['chg']))
|
||||||
|
otherfh.close()
|
||||||
|
|
||||||
|
return asec_charges
|
||||||
|
|
||||||
class Player:
|
class Player:
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
|
|
||||||
self.maxcyc = None
|
self.maxcyc = None
|
||||||
# self.initcyc = 1 # Eliminated
|
|
||||||
self.nprocs = 1
|
self.nprocs = 1
|
||||||
self.switchcyc = 3
|
self.switchcyc = 3
|
||||||
self.altsteps = 20000
|
self.altsteps = 20000
|
||||||
@@ -604,8 +789,9 @@ class Internal:
|
|||||||
self.ghosts = "no"
|
self.ghosts = "no"
|
||||||
self.vdwforces = "no"
|
self.vdwforces = "no"
|
||||||
self.tol_factor = 1.2
|
self.tol_factor = 1.2
|
||||||
|
self.qmprog = "g16"
|
||||||
|
|
||||||
|
self.cyc = 1
|
||||||
|
|
||||||
class Dice:
|
class Dice:
|
||||||
|
|
||||||
|
|||||||
BIN
DPpack/__pycache__/Dice.cpython-38.pyc
Normal file
BIN
DPpack/__pycache__/Dice.cpython-38.pyc
Normal file
Binary file not shown.
BIN
DPpack/__pycache__/Gaussian.cpython-38.pyc
Normal file
BIN
DPpack/__pycache__/Gaussian.cpython-38.pyc
Normal file
Binary file not shown.
BIN
DPpack/__pycache__/Misc.cpython-38.pyc
Normal file
BIN
DPpack/__pycache__/Misc.cpython-38.pyc
Normal file
Binary file not shown.
BIN
DPpack/__pycache__/MolHandling.cpython-38.pyc
Normal file
BIN
DPpack/__pycache__/MolHandling.cpython-38.pyc
Normal file
Binary file not shown.
BIN
DPpack/__pycache__/PTable.cpython-38.pyc
Normal file
BIN
DPpack/__pycache__/PTable.cpython-38.pyc
Normal file
Binary file not shown.
BIN
DPpack/__pycache__/SetGlobals.cpython-38.pyc
Normal file
BIN
DPpack/__pycache__/SetGlobals.cpython-38.pyc
Normal file
Binary file not shown.
BIN
DPpack/__pycache__/__init__.cpython-38.pyc
Normal file
BIN
DPpack/__pycache__/__init__.cpython-38.pyc
Normal file
Binary file not shown.
399
diceplayer.py
399
diceplayer.py
@@ -18,6 +18,7 @@ if __name__ == '__main__':
|
|||||||
#### and set the usage and help messages ####
|
#### and set the usage and help messages ####
|
||||||
|
|
||||||
parser = argparse.ArgumentParser(prog='Diceplayer')
|
parser = argparse.ArgumentParser(prog='Diceplayer')
|
||||||
|
parser.add_argument('--continue', dest='opt_continue' , default=False, action='store_true')
|
||||||
parser.add_argument('--version', action='version', version='%(prog)s 1.0')
|
parser.add_argument('--version', action='version', version='%(prog)s 1.0')
|
||||||
parser.add_argument('-i', dest='infile', default='control.in', metavar='INFILE',
|
parser.add_argument('-i', dest='infile', default='control.in', metavar='INFILE',
|
||||||
help='input file of diceplayer [default = control.in]')
|
help='input file of diceplayer [default = control.in]')
|
||||||
@@ -27,270 +28,300 @@ if __name__ == '__main__':
|
|||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
|
|
||||||
#### Read and check the keywords in INFILE
|
|
||||||
|
|
||||||
read_keywords(args.infile)
|
|
||||||
check_keywords(args.infile)
|
|
||||||
|
|
||||||
#### Open OUTFILE for writing and print keywords and initial info
|
#### Open OUTFILE for writing and print keywords and initial info
|
||||||
|
|
||||||
try:
|
try:
|
||||||
if player['initcyc'] > 1 and os.path.exists(args.outfile):
|
|
||||||
oldname = args.outfile + ".old"
|
if args.opt_continue and os.path.exists(args.outfile):
|
||||||
os.replace(args.outfile, oldname)
|
|
||||||
logfh = open(args.outfile, 'w', 1)
|
outfile = open(args.outfile,'r')
|
||||||
|
run_file = outfile.readlines()
|
||||||
|
control_sequence = ' Step # '
|
||||||
|
|
||||||
|
for line in run_file:
|
||||||
|
if control_sequence in line:
|
||||||
|
cyc = int(line[-2]) + 1
|
||||||
|
|
||||||
|
outfile.close()
|
||||||
|
os.rename(os.path.abspath(args.outfile),os.path.abspath(args.outfile)+".backup")
|
||||||
|
outfile = open(args.outfile,'w')
|
||||||
|
|
||||||
|
|
||||||
|
if os.path.exists(args.outfile):
|
||||||
|
os.rename(os.path.abspath(args.outfile),os.path.abspath(args.outfile)+".backup")
|
||||||
|
outfile = open(args.outfile,'w')
|
||||||
|
else:
|
||||||
|
outfile = open(args.outfile,"w")
|
||||||
|
|
||||||
except EnvironmentError as err:
|
except EnvironmentError as err:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
|
|
||||||
print_keywords(logfh)
|
try:
|
||||||
|
|
||||||
#### Check whether the executables are in the path
|
if os.path.exists(args.infile):
|
||||||
|
infile = open(args.infile,"r")
|
||||||
|
|
||||||
check_executables(logfh)
|
except EnvironmentError as err:
|
||||||
|
sys.exit(err)
|
||||||
|
|
||||||
#### Read the potential, store the info in 'molecules' and prints the info in OUTFILE
|
#### Read and check the keywords in INFILE
|
||||||
|
|
||||||
read_potential(args.infile)
|
internal = Internal(infile, outfile)
|
||||||
|
|
||||||
if player['lps'] == "yes":
|
internal.read_keywords()
|
||||||
read_lps()
|
|
||||||
|
|
||||||
if player['ghosts'] == "yes":
|
if args.opt_continue:
|
||||||
read_ghosts()
|
internal.player.cyc = cyc
|
||||||
|
|
||||||
print_potential(logfh)
|
internal.check_keywords()
|
||||||
|
internal.print_keywords()
|
||||||
|
|
||||||
|
# #### Check whether the executables are in the path
|
||||||
|
|
||||||
|
# internal.check_executables()
|
||||||
|
|
||||||
|
# #### Read the potential, store the info in 'molecules' and prints the info in OUTFILE
|
||||||
|
|
||||||
|
internal.read_potential()
|
||||||
|
|
||||||
|
# if internal.player.lps == "yes":
|
||||||
|
# read_lps()
|
||||||
|
|
||||||
|
# if internal.player.ghosts == "yes":
|
||||||
|
# read_ghosts()
|
||||||
|
|
||||||
|
internal.print_potential()
|
||||||
|
|
||||||
#### Bring the molecules to standard orientation and prints info about them
|
#### Bring the molecules to standard orientation and prints info about them
|
||||||
|
|
||||||
for i in range(len(molecules)):
|
for i in range(len(internal.system.molecule)):
|
||||||
logfh.write("\nMolecule type {}:\n\n".format(i + 1))
|
internal.outfile.write("\nMolecule type {}:\n\n".format(i + 1))
|
||||||
print_mol_info(molecules[i], logfh)
|
internal.system.molecule[i].print_mol_info(internal.outfile)
|
||||||
logfh.write(" Translating and rotating molecule to standard orientation...")
|
internal.outfile.write(" Translating and rotating molecule to standard orientation...")
|
||||||
standard_orientation(molecules[i])
|
internal.system.molecule[i].standard_orientation()
|
||||||
logfh.write(" Done\n\n New values:\n")
|
internal.outfile.write(" Done\n\n New values:\n")
|
||||||
print_mol_info(molecules[i], logfh)
|
internal.system.molecule[i].print_mol_info(internal.outfile)
|
||||||
|
|
||||||
logfh.write(90 * "=")
|
internal.outfile.write(90 * "=")
|
||||||
logfh.write("\n")
|
internal.outfile.write("\n")
|
||||||
|
|
||||||
#### Open the geoms.xyz file and prints the initial geometry if starting from zero
|
#### Open the geoms.xyz file and prints the initial geometry if starting from zero
|
||||||
|
|
||||||
if player['initcyc'] == 1:
|
if internal.player.cyc == 1:
|
||||||
try:
|
try:
|
||||||
geomsfh = open("geoms.xyz", "w", 1)
|
geomsfh = open("geoms.xyz", "w", 1)
|
||||||
except EnvironmentError as err:
|
except EnvironmentError as err:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
print_geom(0, geomsfh)
|
internal.system.print_geom(0, geomsfh)
|
||||||
else:
|
else:
|
||||||
try:
|
try:
|
||||||
geomsfh = open("geoms.xyz", "A", 1)
|
geomsfh = open("geoms.xyz", "A", 1)
|
||||||
except EnvironmentError as err:
|
except EnvironmentError as err:
|
||||||
sys.exit(err)
|
sys.exit(err)
|
||||||
|
|
||||||
|
# internal.outfile.write("\nStarting the iterative process.\n")
|
||||||
|
|
||||||
logfh.write("\nStarting the iterative process.\n")
|
# ## Initial position (in Bohr)
|
||||||
|
# position = internal.system.molecule[0].read_position()
|
||||||
|
|
||||||
## Initial position (in Bohr)
|
# ## If restarting, read the last gradient and hessian
|
||||||
position = read_position(molecules[0])
|
# if internal.player.cyc > 1:
|
||||||
|
# if internal.player.qmprog in ("g03", "g09", "g16"):
|
||||||
|
# Gaussian.read_forces("grad_hessian.dat")
|
||||||
|
# Gaussian.read_hessian_fchk("grad_hessian.dat")
|
||||||
|
|
||||||
## If restarting, read the last gradient and hessian
|
# #if player['qmprog'] == "molcas":
|
||||||
if player['initcyc'] > 1:
|
# #Molcas.read_forces("grad_hessian.dat")
|
||||||
if player['qmprog'] in ("g03", "g09", "g16"):
|
# #Molcas.read_hessian("grad_hessian.dat")
|
||||||
Gaussian.read_forces("grad_hessian.dat")
|
|
||||||
Gaussian.read_hessian_fchk("grad_hessian.dat")
|
|
||||||
|
|
||||||
#if player['qmprog'] == "molcas":
|
# ####
|
||||||
#Molcas.read_forces("grad_hessian.dat")
|
# #### Start the iterative process
|
||||||
#Molcas.read_hessian("grad_hessian.dat")
|
# ####
|
||||||
|
|
||||||
####
|
# for cycle in range(internal.player.cyc, internal.player.cyc + internal.player.maxcyc):
|
||||||
#### Start the iterative process
|
|
||||||
####
|
|
||||||
|
|
||||||
for cycle in range(player['initcyc'], player['initcyc'] + player['maxcyc']):
|
# internal.outfile.write("\n" + 90 * "-" + "\n")
|
||||||
|
# internal.outfile.write("{} Step # {}\n".format(40 * " ", cycle))
|
||||||
|
# internal.outfile.write(90 * "-" + "\n\n")
|
||||||
|
|
||||||
logfh.write("\n" + 90 * "-" + "\n")
|
# make_step_dir(cycle)
|
||||||
logfh.write("{} Step # {}\n".format(40 * " ", cycle))
|
|
||||||
logfh.write(90 * "-" + "\n\n")
|
|
||||||
|
|
||||||
make_step_dir(cycle)
|
# if internal.player.altsteps == 0 or cycle == 1:
|
||||||
|
# internal.dice.randominit = True
|
||||||
|
# else:
|
||||||
|
# internal.dice.randominit = False
|
||||||
|
|
||||||
if player['altsteps'] == 0 or cycle == 1:
|
# ####
|
||||||
dice['randominit'] = True
|
# #### Start block of parallel simulations
|
||||||
else:
|
# ####
|
||||||
dice['randominit'] = False
|
|
||||||
|
|
||||||
####
|
# procs = []
|
||||||
#### Start block of parallel simulations
|
# sentinels = []
|
||||||
####
|
# for proc in range(1, internal.player.nprocs + 1):
|
||||||
|
|
||||||
procs = []
|
# p = Process(target=Dice.simulation_process, args=(cycle, proc, internal.outfile))
|
||||||
sentinels = []
|
# p.start()
|
||||||
for proc in range(1, player['nprocs'] + 1):
|
# procs.append(p)
|
||||||
|
# sentinels.append(p.sentinel)
|
||||||
|
|
||||||
p = Process(target=Dice.simulation_process, args=(cycle, proc, logfh))
|
# while procs:
|
||||||
p.start()
|
# finished = connection.wait(sentinels)
|
||||||
procs.append(p)
|
# for proc_sentinel in finished:
|
||||||
sentinels.append(p.sentinel)
|
# i = sentinels.index(proc_sentinel)
|
||||||
|
# status = procs[i].exitcode
|
||||||
|
# procs.pop(i)
|
||||||
|
# sentinels.pop(i)
|
||||||
|
# if status != 0:
|
||||||
|
# for p in procs:
|
||||||
|
# p.terminate()
|
||||||
|
# sys.exit(status)
|
||||||
|
|
||||||
while procs:
|
# for proc in range(1, internal.player.nprocs + 1):
|
||||||
finished = connection.wait(sentinels)
|
# Dice.print_last_config(cycle, proc)
|
||||||
for proc_sentinel in finished:
|
|
||||||
i = sentinels.index(proc_sentinel)
|
|
||||||
status = procs[i].exitcode
|
|
||||||
procs.pop(i)
|
|
||||||
sentinels.pop(i)
|
|
||||||
if status != 0:
|
|
||||||
for p in procs:
|
|
||||||
p.terminate()
|
|
||||||
sys.exit(status)
|
|
||||||
|
|
||||||
for proc in range(1, player['nprocs'] + 1):
|
# ####
|
||||||
Dice.print_last_config(cycle, proc)
|
# #### End of parallel simulations block
|
||||||
|
# ####
|
||||||
|
|
||||||
####
|
# ## Make ASEC
|
||||||
#### End of parallel simulations block
|
# internal.outfile.write("\nBuilding the ASEC and vdW meanfields... ")
|
||||||
####
|
# asec_charges = internal.populate_asec_vdw(cycle)
|
||||||
|
|
||||||
## Make ASEC
|
# ## After ASEC is built, compress files bigger than 1MB
|
||||||
logfh.write("\nBuilding the ASEC and vdW meanfields... ")
|
# for proc in range(1, internal.player.nprocs + 1):
|
||||||
asec_charges = populate_asec_vdw(cycle, logfh)
|
# path = "step{:02d}".format(cycle) + os.sep + "p{:02d}".format(proc)
|
||||||
|
# compress_files_1mb(path)
|
||||||
|
|
||||||
## After ASEC is built, compress files bigger than 1MB
|
# ####
|
||||||
for proc in range(1, player['nprocs'] + 1):
|
# #### Start QM calculation
|
||||||
path = "step{:02d}".format(cycle) + os.sep + "p{:02d}".format(proc)
|
# ####
|
||||||
compress_files_1mb(path)
|
|
||||||
|
|
||||||
####
|
# make_qm_dir(cycle)
|
||||||
#### Start QM calculation
|
|
||||||
####
|
|
||||||
|
|
||||||
make_qm_dir(cycle)
|
# if internal.player.opt == "yes":
|
||||||
|
|
||||||
if player['opt'] == "yes":
|
# ##
|
||||||
|
# ## Gaussian block
|
||||||
|
# ##
|
||||||
|
# if internal.player.qmprog in ("g03", "g09", "g16"):
|
||||||
|
|
||||||
##
|
# if cycle > 1:
|
||||||
## Gaussian block
|
# src = "step{:02d}".format(cycle - 1) + os.sep + "qm" + os.sep + "asec.chk"
|
||||||
##
|
# dst = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.chk"
|
||||||
if player['qmprog'] in ("g03", "g09", "g16"):
|
# shutil.copyfile(src, dst)
|
||||||
|
|
||||||
if cycle > 1:
|
# Gaussian.make_force_input(cycle, asec_charges)
|
||||||
src = "step{:02d}".format(cycle - 1) + os.sep + "qm" + os.sep + "asec.chk"
|
# Gaussian.run_gaussian(cycle, "force", internal.outfile)
|
||||||
dst = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.chk"
|
# Gaussian.run_formchk(cycle, internal.outfile)
|
||||||
shutil.copyfile(src, dst)
|
|
||||||
|
|
||||||
Gaussian.make_force_input(cycle, asec_charges)
|
# ## Read the gradient
|
||||||
Gaussian.run_gaussian(cycle, "force", logfh)
|
# file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.fchk"
|
||||||
Gaussian.run_formchk(cycle, logfh)
|
# gradient = Gaussian.read_forces(file, internal.outfile)
|
||||||
|
# if len(cur_gradient) > 0:
|
||||||
|
# old_gradient = cur_gradient
|
||||||
|
# cur_gradient = gradient
|
||||||
|
|
||||||
## Read the gradient
|
# ## If 1st step, read the hessian
|
||||||
file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.fchk"
|
# if cycle == 1:
|
||||||
gradient = Gaussian.read_forces(file, logfh)
|
# if internal.player.readhessian == "yes":
|
||||||
if len(cur_gradient) > 0:
|
# file = "grad_hessian.dat"
|
||||||
old_gradient = cur_gradient
|
# internal.outfile.write("\nReading the hessian matrix from file {}\n".format(file))
|
||||||
cur_gradient = gradient
|
# hessian = Gaussian.read_hessian_fchk(file)
|
||||||
|
# else:
|
||||||
|
# file = "step01" + os.sep + "qm" + os.sep + "asec.fchk"
|
||||||
|
# internal.outfile.write("\nReading the hessian matrix from file {}\n".format(file))
|
||||||
|
# hessian = internal.gaussian.read_hessian(file)
|
||||||
|
|
||||||
## If 1st step, read the hessian
|
# ## From 2nd step on, update the hessian
|
||||||
if cycle == 1:
|
# else:
|
||||||
if player['readhessian'] == "yes":
|
# internal.outfile.write("\nUpdating the hessian matrix using the BFGS method... ")
|
||||||
file = "grad_hessian.dat"
|
# hessian = internal.system.molecule[0].update_hessian(step, cur_gradient, old_gradient, hessian)
|
||||||
logfh.write("\nReading the hessian matrix from file {}\n".format(file))
|
# internal.outfile.write("Done\n")
|
||||||
hessian = Gaussian.read_hessian_fchk(file)
|
|
||||||
else:
|
|
||||||
file = "step01" + os.sep + "qm" + os.sep + "asec.fchk"
|
|
||||||
logfh.write("\nReading the hessian matrix from file {}\n".format(file))
|
|
||||||
hessian = Gaussian.read_hessian(file)
|
|
||||||
|
|
||||||
## From 2nd step on, update the hessian
|
# ## Save gradient and hessian
|
||||||
else:
|
# internal.gaussian.print_grad_hessian(cycle, cur_gradient, hessian)
|
||||||
logfh.write("\nUpdating the hessian matrix using the BFGS method... ")
|
|
||||||
hessian = update_hessian(step, cur_gradient, old_gradient, hessian)
|
|
||||||
logfh.write("Done\n")
|
|
||||||
|
|
||||||
## Save gradient and hessian
|
# ## Calculate the step and update the position
|
||||||
Gaussian.print_grad_hessian(cycle, cur_gradient, hessian)
|
# step = internal.calculate_step(cur_gradient, hessian, internal.outfile)
|
||||||
|
# position += step
|
||||||
|
|
||||||
## Calculate the step and update the position
|
# ## Update the geometry of the reference molecule
|
||||||
step = calculate_step(cur_gradient, hessian, logfh)
|
# internal.system.molecule[0].update_molecule(position, internal.outfile)
|
||||||
position += step
|
|
||||||
|
|
||||||
## Update the geometry of the reference molecule
|
# ## If needed, calculate the charges
|
||||||
update_molecule(position, logfh)
|
# if cycle < internal.player.switchcyc:
|
||||||
|
|
||||||
## If needed, calculate the charges
|
# internal.gaussian.make_charge_input(cycle, asec_charges)
|
||||||
if cycle < player['switchcyc']:
|
# internal.gaussian.run_gaussian(cycle, "charge", internal.outfile)
|
||||||
|
|
||||||
Gaussian.make_charge_input(cycle, asec_charges)
|
# ## Read the new charges and update molecules[0]
|
||||||
Gaussian.run_gaussian(cycle, "charge", logfh)
|
# if cycle < internal.player.switchcyc:
|
||||||
|
# file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec2.log"
|
||||||
|
# internal.gaussian.read_charges(file, internal.outfile)
|
||||||
|
# else:
|
||||||
|
# file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.log"
|
||||||
|
# internal.gaussian.read_charges(file, internal.outfile)
|
||||||
|
|
||||||
## Read the new charges and update molecules[0]
|
# ## Print new info for molecule[0]
|
||||||
if cycle < player['switchcyc']:
|
# internal.outfile.write("\nNew values for molecule type 1:\n\n")
|
||||||
file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec2.log"
|
# internal.system.molecule[0].print_mol_info()
|
||||||
Gaussian.read_charges(file, logfh)
|
|
||||||
else:
|
|
||||||
file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.log"
|
|
||||||
Gaussian.read_charges(file, logfh)
|
|
||||||
|
|
||||||
## Print new info for molecule[0]
|
# ## Print new geometry in geoms.xyz
|
||||||
logfh.write("\nNew values for molecule type 1:\n\n")
|
# internal.system.molecule[0].print_geom(cycle, geomsfh)
|
||||||
print_mol_info(molecules[0], logfh)
|
|
||||||
|
|
||||||
## Print new geometry in geoms.xyz
|
# ##
|
||||||
print_geom(cycle, geomsfh)
|
# ## Molcas block
|
||||||
|
# ##
|
||||||
##
|
# #if player['qmprog'] == "molcas":
|
||||||
## Molcas block
|
|
||||||
##
|
|
||||||
#if player['qmprog'] == "molcas":
|
|
||||||
|
|
||||||
|
|
||||||
#elif player['opt'] == "ts":
|
# #elif player['opt'] == "ts":
|
||||||
|
|
||||||
##
|
# ##
|
||||||
## Gaussian block
|
# ## Gaussian block
|
||||||
##
|
# ##
|
||||||
#if player['qmprog'] in ("g03", "g09", "g16"):
|
# #if player['qmprog'] in ("g03", "g09", "g16"):
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
##
|
# ##
|
||||||
## Molcas block
|
# ## Molcas block
|
||||||
##
|
# ##
|
||||||
#if player['qmprog'] == "molcas":
|
# #if player['qmprog'] == "molcas":
|
||||||
|
|
||||||
|
|
||||||
else: ## Only relax the charge distribution
|
# else: ## Only relax the charge distribution
|
||||||
|
|
||||||
if player['qmprog'] in ("g03", "g09", "g16"):
|
# if internal.player.qmprog in ("g03", "g09", "g16"):
|
||||||
|
|
||||||
if cycle > 1:
|
# if cycle > 1:
|
||||||
src = "step{:02d}".format(cycle - 1) + os.sep + "qm" + os.sep + "asec.chk"
|
# src = "step{:02d}".format(cycle - 1) + os.sep + "qm" + os.sep + "asec.chk"
|
||||||
dst = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.chk"
|
# dst = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec.chk"
|
||||||
shutil.copyfile(src, dst)
|
# shutil.copyfile(src, dst)
|
||||||
|
|
||||||
Gaussian.make_charge_input(cycle, asec_charges)
|
# Gaussian.make_charge_input(cycle, asec_charges)
|
||||||
Gaussian.run_gaussian(cycle, "charge", logfh)
|
# Gaussian.run_gaussian(cycle, "charge", internal.outfile)
|
||||||
|
|
||||||
file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec2.log"
|
# file = "step{:02d}".format(cycle) + os.sep + "qm" + os.sep + "asec2.log"
|
||||||
Gaussian.read_charges(file)
|
# Gaussian.read_charges(file)
|
||||||
|
|
||||||
## Print new info for molecule[0]
|
# ## Print new info for molecule[0]
|
||||||
logfh.write("\nNew values for molecule type 1:\n\n")
|
# internal.outfile.write("\nNew values for molecule type 1:\n\n")
|
||||||
print_mol_info(molecules[0], logfh)
|
# internal.system.molecule[0].print_mol_info()
|
||||||
|
|
||||||
#if player['qmprog'] == "molcas":
|
# #if player['qmprog'] == "molcas":
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
####
|
# ####
|
||||||
#### End of the iterative process
|
# #### End of the iterative process
|
||||||
####
|
# ####
|
||||||
|
|
||||||
## imprimir ultimas mensagens, criar um arquivo de potencial para ser usado em eventual
|
# ## imprimir ultimas mensagens, criar um arquivo de potencial para ser usado em eventual
|
||||||
## continuacao, fechar arquivos (geoms.xyz, run.log, ...)
|
# ## continuacao, fechar arquivos (geoms.xyz, run.log, ...)
|
||||||
|
|
||||||
logfh.write("\nDiceplayer finished normally!\n")
|
# internal.outfile.write("\nDiceplayer finished normally!\n")
|
||||||
logfh.close()
|
# internal.outfile.close()
|
||||||
####
|
# ####
|
||||||
#### End of the program
|
# #### End of the program
|
||||||
####
|
# ####
|
||||||
97
run.log
97
run.log
@@ -2,34 +2,38 @@
|
|||||||
############# Welcome to DICEPLAYER version 1.0 #############
|
############# Welcome to DICEPLAYER version 1.0 #############
|
||||||
##########################################################################################
|
##########################################################################################
|
||||||
|
|
||||||
Your python version is 3.6.1 (default, Apr 24 2017, 06:18:27)
|
Your python version is 3.8.8 (default, Apr 13 2021, 19:58:26)
|
||||||
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.42.1)]
|
[GCC 7.3.0]
|
||||||
|
|
||||||
Program started on Wednesday, 14 Jun 2017 at 12:30:02
|
Program started on Saturday, 25 Sep 2021 at 15:24:31
|
||||||
|
|
||||||
Environment variables:
|
Environment variables:
|
||||||
OMP_STACKSIZE = 32M
|
OMP_STACKSIZE = Not set
|
||||||
|
|
||||||
==========================================================================================
|
==========================================================================================
|
||||||
CONTROL variables being used in this run:
|
CONTROL variables being used in this run:
|
||||||
------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
altsteps = 20000
|
altsteps = 20000
|
||||||
|
cyc = 1
|
||||||
|
freq = no
|
||||||
ghosts = no
|
ghosts = no
|
||||||
initcyc = 1
|
|
||||||
lps = no
|
lps = no
|
||||||
maxcyc = 3
|
maxcyc = 3
|
||||||
maxstep = 0.3
|
maxstep = 0.3
|
||||||
nprocs = 2
|
nprocs = 2
|
||||||
opt = no
|
opt = no
|
||||||
qmprog = g09
|
qmprog = g09
|
||||||
switch_step = 3
|
readhessian = no
|
||||||
zipprog = gzip
|
switchcyc = 3
|
||||||
|
tol_factor = 1.2
|
||||||
|
vdwforces = no
|
||||||
|
|
||||||
------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------
|
||||||
DICE variables being used in this run:
|
DICE variables being used in this run:
|
||||||
------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
combrule = *
|
||||||
dens = 0.75
|
dens = 0.75
|
||||||
isave = 1000
|
isave = 1000
|
||||||
ljname = phb.pot
|
ljname = phb.pot
|
||||||
@@ -38,6 +42,7 @@ nmol = 1 100
|
|||||||
nstep = 40000 60000 50000
|
nstep = 40000 60000 50000
|
||||||
outname = phb
|
outname = phb
|
||||||
press = 1.0
|
press = 1.0
|
||||||
|
progname = dice
|
||||||
temp = 300.0
|
temp = 300.0
|
||||||
title = Diceplayer run
|
title = Diceplayer run
|
||||||
|
|
||||||
@@ -45,15 +50,13 @@ title = Diceplayer run
|
|||||||
GAUSSIAN variables being used in this run:
|
GAUSSIAN variables being used in this run:
|
||||||
------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
chglevel = MP2/aug-cc-pVTZ
|
||||||
chgmult = 0 1
|
chgmult = 0 1
|
||||||
level = MP2/aug-cc-pVTZ
|
level = MP2/aug-cc-pVTZ
|
||||||
pop = chelpg
|
pop = chelpg
|
||||||
|
qmprog = g09
|
||||||
|
|
||||||
|
|
||||||
==========================================================================================
|
|
||||||
|
|
||||||
Program dice found at /usr/local/bin/dice
|
|
||||||
|
|
||||||
==========================================================================================
|
==========================================================================================
|
||||||
Potential parameters from file phb.pot:
|
Potential parameters from file phb.pot:
|
||||||
------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------
|
||||||
@@ -136,11 +139,11 @@ Molecule type 1:
|
|||||||
Translating and rotating molecule to standard orientation... Done
|
Translating and rotating molecule to standard orientation... Done
|
||||||
|
|
||||||
New values:
|
New values:
|
||||||
Center of mass = ( -0.0000 , 0.0000 , -0.0000 )
|
Center of mass = ( -0.0000 , 0.0000 , 0.0000 )
|
||||||
Moments of inertia = 3.144054E+02 2.801666E+03 3.027366E+03
|
Moments of inertia = 3.144054E+02 2.801666E+03 3.027366E+03
|
||||||
Major principal axis = ( 1.000000 , 0.000000 , 0.000000 )
|
Major principal axis = ( 1.000000 , 0.000000 , 0.000000 )
|
||||||
Inter principal axis = ( -0.000000 , 1.000000 , -0.000000 )
|
Inter principal axis = ( -0.000000 , 1.000000 , -0.000000 )
|
||||||
Minor principal axis = ( 0.000000 , 0.000000 , 1.000000 )
|
Minor principal axis = ( -0.000000 , 0.000000 , 1.000000 )
|
||||||
Characteristic lengths = ( 11.97 , 5.27 , 2.99 )
|
Characteristic lengths = ( 11.97 , 5.27 , 2.99 )
|
||||||
Total mass = 226.28 au
|
Total mass = 226.28 au
|
||||||
Total charge = -0.0000 e
|
Total charge = -0.0000 e
|
||||||
@@ -162,68 +165,14 @@ Molecule type 2:
|
|||||||
Translating and rotating molecule to standard orientation... Done
|
Translating and rotating molecule to standard orientation... Done
|
||||||
|
|
||||||
New values:
|
New values:
|
||||||
Center of mass = ( 0.0000 , 0.0000 , 0.0000 )
|
Center of mass = ( 1.6067 , -1.0929 , 0.0026 )
|
||||||
Moments of inertia = 1.205279E+02 2.859254E+02 4.033761E+02
|
Moments of inertia = 1.561638E+02 6.739391E+02 8.270247E+02
|
||||||
Major principal axis = ( -1.000000 , 0.000000 , 0.000000 )
|
Major principal axis = ( 0.899747 , -0.436411 , 0.000541 )
|
||||||
Inter principal axis = ( 0.000000 , 1.000000 , 0.000000 )
|
Inter principal axis = ( 0.436411 , 0.899747 , -0.001219 )
|
||||||
Minor principal axis = ( 0.000000 , 0.000000 , 1.000000 )
|
Minor principal axis = ( 0.000045 , 0.001333 , 0.999999 )
|
||||||
Characteristic lengths = ( 5.67 , 5.13 , 1.51 )
|
Characteristic lengths = ( 5.67 , 5.05 , 1.51 )
|
||||||
Total mass = 112.20 au
|
Total mass = 112.20 au
|
||||||
Total charge = -0.0000 e
|
Total charge = -0.0000 e
|
||||||
Dipole moment = ( 1.7575 , 1.5369 , -0.0000 ) Total = 2.3347 Debye
|
Dipole moment = ( 1.8148 , 1.4689 , -0.0016 ) Total = 2.3347 Debye
|
||||||
|
|
||||||
==========================================================================================
|
==========================================================================================
|
||||||
|
|
||||||
Starting the iterative process.
|
|
||||||
|
|
||||||
------------------------------------------------------------------------------------------
|
|
||||||
Step # 1
|
|
||||||
------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
Simulation process p01 initiated with pid 6822
|
|
||||||
Simulation process p02 initiated with pid 6823
|
|
||||||
p01> NVT thermalization initiated (from random configuration) on 14 Jun 2017 at 12:30:02
|
|
||||||
p02> NVT thermalization initiated (from random configuration) on 14 Jun 2017 at 12:30:02
|
|
||||||
p02> NPT thermalization initiated on 14 Jun 2017 at 12:41:16
|
|
||||||
p01> NPT thermalization initiated on 14 Jun 2017 at 12:41:17
|
|
||||||
p02> NPT production initiated on 14 Jun 2017 at 13:01:25
|
|
||||||
p01> NPT production initiated on 14 Jun 2017 at 13:01:27
|
|
||||||
p02> ----- NPT production finished on 14 Jun 2017 at 13:57:41
|
|
||||||
p01> ----- NPT production finished on 14 Jun 2017 at 13:57:53
|
|
||||||
|
|
||||||
Building the ASEC and vdW meanfields... In average, 99.97 molecules were selected from the production simulations to form the
|
|
||||||
ASEC comprising a shell with minimum thickness of 15.352263400006278 AngstromDone.
|
|
||||||
|
|
||||||
------------------------------------------------------------------------------------------
|
|
||||||
Step # 2
|
|
||||||
------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
Simulation process p01 initiated with pid 6903
|
|
||||||
Simulation process p02 initiated with pid 6904
|
|
||||||
p02> NPT thermalization initiated (from previous configuration) on 14 Jun 2017 at 13:58:52
|
|
||||||
p01> NPT thermalization initiated (from previous configuration) on 14 Jun 2017 at 13:58:52
|
|
||||||
p02> NPT production initiated on 14 Jun 2017 at 14:05:14
|
|
||||||
p01> NPT production initiated on 14 Jun 2017 at 14:05:20
|
|
||||||
p02> ----- NPT production finished on 14 Jun 2017 at 14:23:58
|
|
||||||
p01> ----- NPT production finished on 14 Jun 2017 at 14:24:05
|
|
||||||
|
|
||||||
Building the ASEC and vdW meanfields... In average, 99.66 molecules were selected from the production simulations to form the
|
|
||||||
ASEC comprising a shell with minimum thickness of 14.942583400006276 AngstromDone.
|
|
||||||
|
|
||||||
------------------------------------------------------------------------------------------
|
|
||||||
Step # 3
|
|
||||||
------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
Simulation process p01 initiated with pid 6945
|
|
||||||
p01> NPT thermalization initiated (from previous configuration) on 14 Jun 2017 at 14:24:45
|
|
||||||
Simulation process p02 initiated with pid 6946
|
|
||||||
p02> NPT thermalization initiated (from previous configuration) on 14 Jun 2017 at 14:24:45
|
|
||||||
p02> NPT production initiated on 14 Jun 2017 at 14:31:05
|
|
||||||
p01> NPT production initiated on 14 Jun 2017 at 14:31:06
|
|
||||||
p02> ----- NPT production finished on 14 Jun 2017 at 14:48:15
|
|
||||||
p01> ----- NPT production finished on 14 Jun 2017 at 14:48:15
|
|
||||||
|
|
||||||
Building the ASEC and vdW meanfields... In average, 99.0 molecules were selected from the production simulations to form the
|
|
||||||
ASEC comprising a shell with minimum thickness of 14.79446440000628 AngstromDone.
|
|
||||||
|
|
||||||
Diceplayer finished normally!
|
|
||||||
180
run.log.backup
Normal file
180
run.log.backup
Normal file
@@ -0,0 +1,180 @@
|
|||||||
|
##########################################################################################
|
||||||
|
############# Welcome to DICEPLAYER version 1.0 #############
|
||||||
|
##########################################################################################
|
||||||
|
|
||||||
|
Your python version is 3.8.8 (default, Apr 13 2021, 19:58:26)
|
||||||
|
[GCC 7.3.0]
|
||||||
|
|
||||||
|
Program started on Saturday, 25 Sep 2021 at 15:23:44
|
||||||
|
|
||||||
|
Environment variables:
|
||||||
|
OMP_STACKSIZE = Not set
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
CONTROL variables being used in this run:
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
altsteps = 20000
|
||||||
|
cyc = 1
|
||||||
|
freq = no
|
||||||
|
ghosts = no
|
||||||
|
lps = no
|
||||||
|
maxcyc = 3
|
||||||
|
maxstep = 0.3
|
||||||
|
nprocs = 2
|
||||||
|
opt = no
|
||||||
|
qmprog = g09
|
||||||
|
readhessian = no
|
||||||
|
switchcyc = 3
|
||||||
|
tol_factor = 1.2
|
||||||
|
vdwforces = no
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
DICE variables being used in this run:
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
combrule = *
|
||||||
|
dens = 0.75
|
||||||
|
isave = 1000
|
||||||
|
ljname = phb.pot
|
||||||
|
ncores = 1
|
||||||
|
nmol = 1 100
|
||||||
|
nstep = 40000 60000 50000
|
||||||
|
outname = phb
|
||||||
|
press = 1.0
|
||||||
|
progname = dice
|
||||||
|
temp = 300.0
|
||||||
|
title = Diceplayer run
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
GAUSSIAN variables being used in this run:
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
chglevel = MP2/aug-cc-pVTZ
|
||||||
|
chgmult = 0 1
|
||||||
|
level = MP2/aug-cc-pVTZ
|
||||||
|
pop = chelpg
|
||||||
|
qmprog = g09
|
||||||
|
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
Potential parameters from file phb.pot:
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Combination rule: *
|
||||||
|
Types of molecules: 2
|
||||||
|
|
||||||
|
31 atoms in molecule type 1:
|
||||||
|
---------------------------------------------------------------------------------
|
||||||
|
Lbl AN X Y Z Charge Epsilon Sigma Mass
|
||||||
|
---------------------------------------------------------------------------------
|
||||||
|
1 6 -4.40034 0.66551 0.41431 -0.387593 0.07000 3.5500 12.0110
|
||||||
|
1 6 -4.49957 -0.67279 -0.15327 0.804001 0.07000 3.5500 12.0110
|
||||||
|
1 6 -3.25630 -1.28922 -0.61351 -0.338491 0.07000 3.5500 12.0110
|
||||||
|
1 6 -2.05849 -0.66807 -0.48674 -0.220783 0.07000 3.5500 12.0110
|
||||||
|
1 6 -1.97114 0.65148 0.10511 0.563527 0.07000 3.5500 12.0110
|
||||||
|
1 6 -3.20601 1.29684 0.49712 -0.145372 0.07000 3.5500 12.0110
|
||||||
|
2 8 -5.59453 -1.25309 -0.28765 -0.714461 0.21000 2.9600 15.9990
|
||||||
|
3 7 -0.87404 1.35870 0.27636 -0.721792 0.17000 3.2500 14.0070
|
||||||
|
4 6 0.38785 0.81512 0.14410 0.607123 0.07000 3.5500 12.0110
|
||||||
|
4 6 1.40776 1.65800 -0.33261 -0.295476 0.07000 3.5500 12.0110
|
||||||
|
4 6 0.75950 -0.46815 0.58791 -0.346661 0.07000 3.5500 12.0110
|
||||||
|
4 6 2.71021 1.21519 -0.46119 -0.298546 0.07000 3.5500 12.0110
|
||||||
|
4 6 2.07354 -0.89884 0.50831 -0.234284 0.07000 3.5500 12.0110
|
||||||
|
4 6 3.08076 -0.08936 -0.06112 0.294651 0.07000 3.5500 12.0110
|
||||||
|
5 7 4.37238 -0.53979 -0.20183 -0.190497 0.17000 3.2500 14.0070
|
||||||
|
6 6 5.41980 0.43824 -0.43836 -0.213183 0.06600 3.5000 12.0110
|
||||||
|
6 6 4.76361 -1.73522 0.52225 -0.225420 0.06600 3.5000 12.0110
|
||||||
|
7 1 6.36700 -0.08536 -0.51962 0.109840 0.03000 2.5000 1.0079
|
||||||
|
7 1 5.25196 0.96612 -1.37421 0.077140 0.03000 2.5000 1.0079
|
||||||
|
7 1 5.49517 1.17412 0.36749 0.125758 0.03000 2.5000 1.0079
|
||||||
|
7 1 4.15838 -2.58442 0.21446 0.083229 0.03000 2.5000 1.0079
|
||||||
|
7 1 5.79695 -1.96254 0.28041 0.115361 0.03000 2.5000 1.0079
|
||||||
|
7 1 4.67416 -1.61707 1.60661 0.121440 0.03000 2.5000 1.0079
|
||||||
|
7 1 0.02813 -1.09554 1.08007 0.179434 0.03000 2.4200 1.0079
|
||||||
|
7 1 2.31876 -1.86576 0.91913 0.177250 0.03000 2.4200 1.0079
|
||||||
|
7 1 3.45102 1.89880 -0.84669 0.198844 0.03000 2.4200 1.0079
|
||||||
|
7 1 1.14759 2.66909 -0.61498 0.173388 0.03000 2.4200 1.0079
|
||||||
|
7 1 -3.11930 2.29679 0.90060 0.151534 0.03000 2.4200 1.0079
|
||||||
|
7 1 -5.31582 1.13611 0.74479 0.205289 0.03000 2.4200 1.0079
|
||||||
|
7 1 -3.33813 -2.25037 -1.10231 0.184367 0.03000 2.4200 1.0079
|
||||||
|
7 1 -1.16374 -1.11791 -0.89380 0.160382 0.03000 2.4200 1.0079
|
||||||
|
|
||||||
|
16 atoms in molecule type 2:
|
||||||
|
---------------------------------------------------------------------------------
|
||||||
|
Lbl AN X Y Z Charge Epsilon Sigma Mass
|
||||||
|
---------------------------------------------------------------------------------
|
||||||
|
1 6 0.67203 -2.82345 0.00263 -0.115000 0.07000 3.5500 12.0110
|
||||||
|
1 6 2.07203 -2.82345 0.00263 -0.115000 0.07000 3.5500 12.0110
|
||||||
|
1 6 2.76823 -1.61764 0.00263 -0.115000 0.07000 3.5500 12.0110
|
||||||
|
1 6 2.06824 -0.40521 0.00264 -0.115000 0.07000 3.5500 12.0110
|
||||||
|
1 14 0.67589 -0.40522 0.00264 0.150000 0.07000 3.5500 28.0860
|
||||||
|
1 104 -0.02420 -1.61760 0.00263 -0.115000 0.07000 3.5500 0.0000
|
||||||
|
2 1 0.13203 -3.75875 0.00263 0.115000 0.03000 2.4200 1.0079
|
||||||
|
2 1 2.61203 -3.75875 0.00263 0.115000 0.03000 2.4200 1.0079
|
||||||
|
2 1 2.60824 0.53010 0.00264 0.115000 0.03000 2.4200 1.0079
|
||||||
|
2 1 -1.10420 -1.61760 0.00263 0.115000 0.03000 2.4200 1.0079
|
||||||
|
3 8 -0.00411 0.77257 0.00264 -0.585000 0.17000 3.0700 15.9990
|
||||||
|
3 1 0.61978 1.50220 0.00264 0.435000 0.00000 0.0000 1.0079
|
||||||
|
4 6 4.27823 -1.61764 0.00263 0.115000 0.17000 3.8000 12.0110
|
||||||
|
4 1 4.63490 -0.74399 0.50704 0.000000 0.00000 0.0000 1.0079
|
||||||
|
4 1 4.63490 -2.49130 0.50704 0.000000 0.00000 0.0000 1.0079
|
||||||
|
4 1 4.63490 -1.61764 -1.00617 0.000000 0.00000 0.0000 1.0079
|
||||||
|
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
|
||||||
|
Molecule type 1:
|
||||||
|
|
||||||
|
Center of mass = ( -0.0000 , 0.0000 , 0.0000 )
|
||||||
|
Moments of inertia = 3.144054E+02 2.801666E+03 3.027366E+03
|
||||||
|
Major principal axis = ( 0.999972 , 0.007210 , 0.002184 )
|
||||||
|
Inter principal axis = ( -0.007218 , 0.999967 , 0.003660 )
|
||||||
|
Minor principal axis = ( -0.002157 , -0.003676 , 0.999991 )
|
||||||
|
Characteristic lengths = ( 11.96 , 5.25 , 2.98 )
|
||||||
|
Total mass = 226.28 au
|
||||||
|
Total charge = -0.0000 e
|
||||||
|
Dipole moment = ( 9.8367 , 0.6848 , 0.8358 ) Total = 9.8959 Debye
|
||||||
|
|
||||||
|
Translating and rotating molecule to standard orientation... Done
|
||||||
|
|
||||||
|
New values:
|
||||||
|
Center of mass = ( -0.0000 , 0.0000 , 0.0000 )
|
||||||
|
Moments of inertia = 3.144054E+02 2.801666E+03 3.027366E+03
|
||||||
|
Major principal axis = ( 1.000000 , 0.000000 , 0.000000 )
|
||||||
|
Inter principal axis = ( -0.000000 , 1.000000 , -0.000000 )
|
||||||
|
Minor principal axis = ( -0.000000 , 0.000000 , 1.000000 )
|
||||||
|
Characteristic lengths = ( 11.97 , 5.27 , 2.99 )
|
||||||
|
Total mass = 226.28 au
|
||||||
|
Total charge = -0.0000 e
|
||||||
|
Dipole moment = ( 9.8432 , 0.6168 , 0.8120 ) Total = 9.8959 Debye
|
||||||
|
|
||||||
|
|
||||||
|
Molecule type 2:
|
||||||
|
|
||||||
|
Center of mass = ( 1.6067 , -1.0929 , 0.0026 )
|
||||||
|
Moments of inertia = 1.205279E+02 2.859254E+02 4.033761E+02
|
||||||
|
Major principal axis = ( 0.795913 , -0.605411 , -0.000001 )
|
||||||
|
Inter principal axis = ( 0.605411 , 0.795913 , 0.000001 )
|
||||||
|
Minor principal axis = ( 0.000000 , -0.000002 , 1.000000 )
|
||||||
|
Characteristic lengths = ( 5.74 , 5.26 , 1.51 )
|
||||||
|
Total mass = 112.20 au
|
||||||
|
Total charge = -0.0000 e
|
||||||
|
Dipole moment = ( 2.3293 , 0.1593 , -0.0000 ) Total = 2.3347 Debye
|
||||||
|
|
||||||
|
Translating and rotating molecule to standard orientation... Done
|
||||||
|
|
||||||
|
New values:
|
||||||
|
Center of mass = ( 1.6067 , -1.0929 , 0.0026 )
|
||||||
|
Moments of inertia = 1.561638E+02 6.739391E+02 8.270247E+02
|
||||||
|
Major principal axis = ( 0.899747 , -0.436411 , 0.000541 )
|
||||||
|
Inter principal axis = ( 0.436411 , 0.899747 , -0.001219 )
|
||||||
|
Minor principal axis = ( 0.000045 , 0.001333 , 0.999999 )
|
||||||
|
Characteristic lengths = ( 5.67 , 5.05 , 1.51 )
|
||||||
|
Total mass = 112.20 au
|
||||||
|
Total charge = -0.0000 e
|
||||||
|
Dipole moment = ( 1.8148 , 1.4689 , -0.0016 ) Total = 2.3347 Debye
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
|
||||||
|
Starting the iterative process.
|
||||||
Reference in New Issue
Block a user