Debian Codegraph @

examples/all_atom/force_field_OPLSAA/hexadecane/moltemplate_files/ch3.lt

raw
1 # This file contains a definition for the "CH3" molecular subunit.
2
3 # First, load the OPLS force field parameters we will need.
4 # This file is located in the "force_fields" subdirectory
5 # distributed with moltemplate.
6
7 import "loplsaa2024.lt" # <-- defines the standard "OPLSAA" force field as well as
8 # custom parameters for long alkane chains taken from
9 # Sui et al. J.Chem.Theory.Comp (2012), 8, 1459
10 # To use the ordinary OPLSAA force field parameters,
11 # (instead of the Sui et al. parameters), change the
12 # atom types below from "@atom:54L","@atom:60LCH3" to
13 # "@atom:54" and "@atom:60" (defined in "oplsaa2024.lt")
14
15 # The "loplsaa2024.lt" and "oplsaa2024.lt" files are located at:
16 # https://github.com/jewettaij/moltemplate/tree/master/moltemplate/force_fields/
17 # If you want to customize these files, download them and copy them to this folder.
18
19
20
21
22 CH3 inherits OPLSAA {
23
24 # atom-id mol-id atom-type charge x y z
25
26 write("Data Atoms") {
27 $atom:c $mol:... @atom:54L 0.0 0.000000 0.000000 0.000000
28 $atom:H1 $mol:... @atom:60LCH3 0.0 0.000000 0.631044 0.892431
29 $atom:H2 $mol:... @atom:60LCH3 0.0 0.000000 0.631044 -0.892431
30 $atom:H3 $mol:... @atom:60LCH3 0.0 -0.892431 -0.631044 0.000000
31 }
32
33 write('Data Bond List') {
34 $bond:ch1 $atom:c $atom:H1
35 $bond:ch2 $atom:c $atom:H2
36 $bond:ch3 $atom:c $atom:H3
37 }
38
39 # Atom type numbers (@atom:54L,@atom:60LCH3) are defined in "loplsaa2024.lt",
40 # @atom:54L "C - CT | n-CH3 C: alkane (LOPLS, 2012)"
41 # @atom:57L "C - CT | CH2 C: alkanes (LOPLS, 2012)"
42 # @atom:60LCH3 "H - HC | CH3 H: alkanes (LOPLS,2012)"
43 # @atom:60LCH2 "H - HC | CH2 H: alkanes (LOPLS,2012)"
44 # In this example, atomic charges are generated by atom type (according to the
45 # rules in loplsaa2024.lt), and can be omitted. Just leave them as "0.0" for now.
46 # The "..." in "$mol:..." tells moltemplate that this molecule may be part
47 # of a larger molecule, and (if so) to use the larger parent object's
48 # molecule id number as it's own.
49
50 } # CH3
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66 # Optional: Shift all the coordinates in the +Y direction by 0.4431163.
67 # This way, the carbon atom is no longer located at 0,0,0, but the
68 # axis of an alkane chain containing this monomer is at 0,0,0.
69 # (This makes it more convenient to construct a polymer later.
70 # If this is confusing, then simply add 0.4431163 to the Y
71 # coordinates in the "Data Atoms" section above.)
72
73 CH3.move(0,0.4431163,0)
74
75
76
77
78 ######### (scratchwork calculations for the atomic coordinates) #########
79 # Lcc = 1.5350 # length of the C-C bond (Sp3)
80 # Lch = 1.0930 # length of the C-H bond
81 # theta=2*atan(sqrt(2)) # ~= 109.5 degrees = tetrahedronal angle (C-C-C angle)
82 # DeltaXc = Lcc*sin(theta/2) # = 1.2533222517240594
83 # DeltaYc = Lcc*cos(theta/2) # = 0.8862326632060754
84 # # 0.5*DeltaYc = 0.4431163
85 # DeltaZh = Lch*sin(theta/2) # = 0.892431
86 # DeltaYh = Lch*cos(theta/2) # = 0.631044