Debian Codegraph @

examples/all_atom/force_field_OPLSAA/star_polymer/moltemplate_files/ch2.lt

raw
1 # This file contains a definition for the "CH2" 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:57L","@atom:60LCH2" to
13 # "@atom:57" and "@atom:60" (defined in "oplsaa2024.lt")
14
15
16
17 # Then define "CH2":
18
19
20 CH2 inherits OPLSAA {
21
22 # atom-id mol-id atom-type charge x y z
23
24 write("Data Atoms") {
25 $atom:c $mol:... @atom:57L 0.0 0.000000 0.000000 0.000000
26 $atom:H1 $mol:... @atom:60LCH2 0.0 0.000000 0.631044 0.892431
27 $atom:H2 $mol:... @atom:60LCH2 0.0 0.000000 0.631044 -0.892431
28 }
29
30 write('Data Bond List') {
31 $bond:ch1 $atom:c $atom:H1
32 $bond:ch2 $atom:c $atom:H2
33 }
34
35 # Atom type numbers (@atom:57L,@atom:60LCH3) are defined in "loplsaa2024.lt",
36 # @atom:54L "C - CT | n-CH3 C: alkane (LOPLS, 2012)"
37 # @atom:57L "C - CT | CH2 C: alkanes (LOPLS, 2012)"
38 # @atom:60LCH3 "H - HC | CH3 H: alkanes (LOPLS,2012)"
39 # @atom:60LCH2 "H - HC | CH2 H: alkanes (LOPLS,2012)"
40 # In this example, atomic charges are generated by atom type (according to the
41 # rules in loplsaa2024.lt), and can be omitted. Just leave them as "0.0" for now.
42 # The "..." in "$mol:..." tells moltemplate that this molecule may be part
43 # of a larger molecule, and (if so) to use the larger parent object's
44 # molecule id number as it's own.
45
46 } # CH2
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62 # Optional: Shift all the coordinates in the +Y direction by 0.4431163.
63 # This way, the carbon atom is no longer located at 0,0,0, but the
64 # axis of an alkane chain containing this monomer is at 0,0,0.
65 # (This makes it more convenient to construct a polymer later.
66 # If this is confusing, then simply add 0.4431163 to the Y
67 # coordinates in the "Data Atoms" section above.)
68
69 CH2.move(0,0.4431163,0)
70
71
72
73
74 ######### (scratchwork calculations for the atomic coordinates) #########
75 # Lcc = 1.5350 # length of the C-C bond (Sp3)
76 # Lch = 1.0930 # length of the C-H bond
77 # theta=2*atan(sqrt(2)) # ~= 109.5 degrees = tetrahedronal angle (C-C-C angle)
78 # DeltaXc = Lcc*sin(theta/2) # = 1.2533222517240594
79 # DeltaYc = Lcc*cos(theta/2) # = 0.8862326632060754
80 # # 0.5*DeltaYc = 0.4431163
81 # DeltaZh = Lch*sin(theta/2) # = 0.892431
82 # DeltaYh = Lch*cos(theta/2) # = 0.631044