def MOTD(): utils.ff_print_source(False) utils.ff_use_colours(fancy_format_colours) utils.ff_print_time(False) os.system('color 07') features = [ 'Loading molecules from xyz files or alternatively download from pubchem.', 'Visualising molecules as a ball-and-stick model or as a wireframe model.', 'Algorithms for guessing atom types, bonds, and bond orders.', 'Support for STO-nG basis set for atomic/molecular orbital visualtions and calculations.', 'Crude extended-Hückel method for calculation of molecular orbitals.' ] planned_features = [ 'Improvements to extended-Hückel and molecular integrals.', 'Marching cubes algorithm to visualise orbitals as iso-volumes instead of current random-dot style.' ] utils.message(f'Welcome, this project so far supports the following:', colour='blue') [utils.message(f'-- {f}', colour='blue') for f in features] utils.message(f'Planned features:', colour='blue') [utils.message(f'-- {f}', colour='blue') for f in planned_features] print()
'Improvements to extended-Hückel and molecular integrals.', 'Marching cubes algorithm to visualise orbitals as iso-volumes instead of current random-dot style.' ] utils.message(f'Welcome, this project so far supports the following:', colour='blue') [utils.message(f'-- {f}', colour='blue') for f in features] utils.message(f'Planned features:', colour='blue') [utils.message(f'-- {f}', colour='blue') for f in planned_features] print() MOTD() utils.ff_print_source(fancy_format_source) utils.ff_use_colours(fancy_format_colours) utils.ff_print_time(fancy_format_time) utils.ff_verbosity(verbosity) if colour_map == None: colour_map = cmap.BlueRed(posneg_mode=True) #viewer setup pg.init() screen = scr.Screen3D(resolution, bkgr_colour=background_colour) mol = mol6.Molecule(molecule, basis_set_type=basis_set, repeat=repeats) if add_hydrogens: mol.add_hydrogens() atoms = mol.atoms
import modules.minimizer as mini import modules.moldynamics as md import os, math, copy import numpy as np from subprocess import check_output # def printer(m): # for a1, a2 in m.get_unique_bonds(): # print(a1, a2, a1.distance_to(a2)) # for a1, a2, a3, angle in m.get_unique_bond_angles(): # print(a1,a2,a3,angle) utils.ff_print_source(False) utils.ff_use_colours(False) utils.ff_print_time(False) ff = uff.ForceField() ethane = mol.Molecule('butane.pcp') a = ethane.atoms # md.perform_md(ethane) # ethane2 = mol.Molecule('benzene2') p = plot.Plot() # e1 = ff.get_energy(ethane,verbosity=1)*4.18 # e2 = ff.get_energy(ethane2,verbosity=1)*4.18 # print((e2-e1)/0.001) # print((44.67307-44.64240)/0.001)