Beispiel #1
0
bnd_t_bb = config.add_bond_type(
    3, np.array([30 * eps / sigma**2, 1.5 * sigma, eps, sigma]))
bnd_t_bs = config.add_bond_type(
    3, np.array([30 * eps / sigma**2, 1.5 * sigma, eps, sigma]))
bnd_t_ss = config.add_bond_type(
    3, np.array([30 * eps / sigma**2, 1.5 * sigma, eps, sigma]))

#Angle types (No angles)

#Dihedral types (No dihedrals)

#Tether types (No tethers)

#Molecule type
num_mols = 1
config.add_molecule_type('BTLBRS', num_mols)

len_bond = 1.94  #0.97*sigma #Equilibrium bond length
theta_bb = (45.0 / 180.0) * math.pi
sep = 1.9  # Must be <= len_bond

#Add atoms, bonds, etc
#Loop over all molecules (here only a single molecule type)
imol = 1
iatm = 1
ibnd = 1  #Index of atom, bond, etc. of the next entity to be added
for imol in range(1, num_mols + 1):
    iatm_beg = iatm
    ibnd_beg = ibnd

    #Backbone
Beispiel #2
0
import numpy as np
from configuration import Configuration
from config_io import *

#-------------------------------------------------------------------------------

config = Configuration()

#Add simulation box and boundary condition. The box size can be updated later if
#necessary.
config.add_simbox(10.0, 10.0, 10.0, 1)

#Molecule details
num_mols_A = 60
num_mols_B = 60
mol_t_A = config.add_molecule_type('A', num_mols_A)
mol_t_B = config.add_molecule_type('B', num_mols_B)

#Total number of atoms in the molecule
natm = 1

#Atom types
# natm atoms as point particles with mass 1.0
atm_t_a = config.add_atom_type('A', 1, 1.0)
atm_t_b = config.add_atom_type('B', 1, 1.0)

#Vdw interaction
eps = 1.0
sigma = 2.0
rcut = 2.0**(1.0 / 6) * sigma
rcut_coul = 0
Beispiel #3
0
import math
import numpy as np
from configuration import Configuration
from config_io import *

#-------------------------------------------------------------------------------

config = Configuration()

#Add simulation box and boundary condition. The box size can be updated later if
#necessary.
config.add_simbox(20.0, 20.0, 20.0, 0)

#Molecule details
num_mols = 1
config.add_molecule_type('CHN-UB', num_mols)

#Total number of atoms in the molecule
natm = 30 #int(sys.argv[1])

#Total number of bonds
nbnd = natm - 1

#Total number of angles. If no angles set num_angles to zero.
nang = natm - 2 if natm > 2 else 0

#Atom types
# natm atoms as point particles with mass 1.0
atm_t_bb = config.add_atom_type('M', 1, 1.0)

#Vdw interaction
Beispiel #4
0
#Vdw (pairwise) interaction. 12-6 LJ+Coulomb (cut & shifted)
#Assume same for all pairs
eps = 1.0
sigma = 2.0
rcut = 2.0**(1.0 / 6) * sigma
rcut_coul = rcut + 3.0
C = 20.0
config.add_ia_vdw('M', 'M', 5, np.array([eps, sigma, rcut, rcut_coul, C]))
config.add_ia_vdw('C', 'C', 5, np.array([eps, sigma, rcut, rcut_coul, C]))
config.add_ia_vdw('M', 'C', 5, np.array([eps, sigma, rcut, rcut_coul, C]))

#Molecules
#Chain, let there be 5 such molecules.
num_mols = 5
mol_t_chn = config.add_molecule_type('CHN', num_mols)

#Number of atoms in a chain
natm = 30

#Total number of bonds in a chain
nbnd = natm - 1

#Number of angles in a chain.
nang = natm - 2 if natm > 2 else 0

#Add atoms, bonds, and angles of chains.
len_bond = 2.0  #Approx. equilibrium bond length
sep = 1.95  # For checking overlap, must be <= len_bond
theta = (45.0 / 180.0) * math.pi  #Avg. initial bond angle