Skip to content
Snippets Groups Projects
Commit 8731d78e authored by James Graham's avatar James Graham
Browse files

Add glycosidic dihedrals

Update filename in README
parent ff281118
No related branches found
No related tags found
No related merge requests found
...@@ -9,8 +9,11 @@ This program uses a library of pre-defined molecule, atom, and bond types to con ...@@ -9,8 +9,11 @@ This program uses a library of pre-defined molecule, atom, and bond types to con
## Use ## Use
To use the program, execute: To use the program, execute:
`python pdb2lmp.py <PDB/GRO input> <output name>` `python pdb2lmp.py <PDB/GRO input> <output name>`
e.g.: e.g.:
`python pdb2lmp.py data/water.pdb water` `python pdb2lmp.py data/water.pdb water`
Output DATA and FF files are created using the output name specified appended with the prefixes `.data` and `.ff` respectively. For the conversion to be successful the molecule names in the import PDB/GRO must match an entry in the PDB2LMP molecule file. If a molecule is missing it may be added to `data/mol.dat`. Output DATA and FF files are created using the output name specified appended with the prefixes `.data` and `.ff` respectively. For the conversion to be successful the molecule names in the import PDB/GRO must match an entry in the PDB2LMP molecule file. If a molecule is missing it may be added to `data/mol-elba.json`.
...@@ -36,15 +36,15 @@ ...@@ -36,15 +36,15 @@
"sugar-dih-30pc-2": "fourier 2 0.75 3 0 -0.10 1 120", "sugar-dih-30pc-2": "fourier 2 0.75 3 0 -0.10 1 120",
"sugar-dih-80pc-1": "fourier 2 0.75 3 0 -0.32 1 -120", "sugar-dih-80pc-1": "fourier 2 0.75 3 0 -0.32 1 -120",
"sugar-dih-80pc-2": "fourier 2 0.75 3 0 -0.32 1 120", "sugar-dih-80pc-2": "fourier 2 0.75 3 0 -0.32 1 120",
"sugar-glyc-d1-3": "charmm -0.1801345 1 -123.0662189 0.0", "sugar-glyc-d1-3": "charmm -0.1801345 1 -123 0.0",
"sugar-glyc-d1-4": "charmm -0.8522 1 -146.907595 0.0", "sugar-glyc-d1-4": "charmm -0.8522 1 -147 0.0",
"sugar-glyc-d1-6": "charmm 0.4714055 1 0.8067885 0.0", "sugar-glyc-d1-6": "charmm 0.4714055 1 1 0.0",
"sugar-glyc-d2-a-34": "charmm -0.819724 1 -65.408620 0.0", "sugar-glyc-d2-a-34": "charmm -0.819724 1 -65 0.0",
"sugar-glyc-d2-a-6": "charmm 1.312271 1 13.593349 0.0", "sugar-glyc-d2-a-6": "charmm 1.312271 1 14 0.0",
"sugar-glyc-d2-b-34": "charmm -0.2683885 1 -83.0853785 0.0", "sugar-glyc-d2-b-34": "charmm -0.2683885 1 -83 0.0",
"sugar-glyc-d2-b-6": "charmm -0.542714 1 -26.391433 0.0", "sugar-glyc-d2-b-6": "charmm -0.542714 1 -26 0.0",
"sugar-glyc-d3-a": "charmm -6.74014666 1 -83.661744 0.0", "sugar-glyc-d3-a": "charmm -6.74014666 1 -84 0.0",
"sugar-glyc-d3-b": "charmm -0.05605633 1 -42.276276 0.0" "sugar-glyc-d3-b": "charmm -0.05605633 1 -42 0.0"
}, },
"improper":{ "improper":{
"dipole-cone-1": "dipole/cone 200 120 60", "dipole-cone-1": "dipole/cone 200 120 60",
......
...@@ -101,6 +101,13 @@ ...@@ -101,6 +101,13 @@
"angles":[ "angles":[
{"type": "sugar-glyc-1", "atoms":["C2", "C3", "+C1"]}, {"type": "sugar-glyc-1", "atoms":["C2", "C3", "+C1"]},
{"type": "sugar-glyc-2", "atoms":["C3", "+C1", "+C2"]} {"type": "sugar-glyc-2", "atoms":["C3", "+C1", "+C2"]}
],
"dihedrals":[
{"type": "sugar-glyc-d1-3", "atoms":["C2", "C3", "C4", "+C1"]},
{"type": "sugar-glyc-d2-a-34", "atoms":["C3", "C4", "+C1", "+C2"], "ifnext": "[0-9].A"},
{"type": "sugar-glyc-d2-b-34", "atoms":["C3", "C4", "+C1", "+C2"], "ifnext": "[0-9].B"},
{"type": "sugar-glyc-d3-a", "atoms":["C4", "+C1", "+C2", "+C3"], "ifnext": "[0-9].A"},
{"type": "sugar-glyc-d3-b", "atoms":["C4", "+C1", "+C2", "+C3"], "ifnext": "[0-9].B"}
] ]
}, },
"4XX":{ "4XX":{
...@@ -110,6 +117,13 @@ ...@@ -110,6 +117,13 @@
"angles":[ "angles":[
{"type": "sugar-glyc-1", "atoms":["C3", "C4", "+C1"]}, {"type": "sugar-glyc-1", "atoms":["C3", "C4", "+C1"]},
{"type": "sugar-glyc-2", "atoms":["C4", "+C1", "+C2"]} {"type": "sugar-glyc-2", "atoms":["C4", "+C1", "+C2"]}
],
"dihedrals":[
{"type": "sugar-glyc-d1-4", "atoms":["C2", "C3", "C4", "+C1"]},
{"type": "sugar-glyc-d2-a-34", "atoms":["C3", "C4", "+C1", "+C2"], "ifnext": "[0-9].A"},
{"type": "sugar-glyc-d2-b-34", "atoms":["C3", "C4", "+C1", "+C2"], "ifnext": "[0-9].B"},
{"type": "sugar-glyc-d3-a", "atoms":["C4", "+C1", "+C2", "+C3"], "ifnext": "[0-9].A"},
{"type": "sugar-glyc-d3-b", "atoms":["C4", "+C1", "+C2", "+C3"], "ifnext": "[0-9].B"}
] ]
}, },
"6XX":{ "6XX":{
...@@ -119,6 +133,13 @@ ...@@ -119,6 +133,13 @@
"angles":[ "angles":[
{"type": "sugar-glyc-1-C6", "atoms":["C4", "C5", "+C1"]}, {"type": "sugar-glyc-1-C6", "atoms":["C4", "C5", "+C1"]},
{"type": "sugar-glyc-2", "atoms":["C5", "+C1", "+C2"]} {"type": "sugar-glyc-2", "atoms":["C5", "+C1", "+C2"]}
],
"dihedrals":[
{"type": "sugar-glyc-d1-6", "atoms":["C2", "C3", "C4", "+C1"]},
{"type": "sugar-glyc-d2-a-6", "atoms":["C3", "C4", "+C1", "+C2"], "ifnext": "[0-9].A"},
{"type": "sugar-glyc-d2-b-6", "atoms":["C3", "C4", "+C1", "+C2"], "ifnext": "[0-9].B"},
{"type": "sugar-glyc-d3-a", "atoms":["C4", "+C1", "+C2", "+C3"], "ifnext": "[0-9].A"},
{"type": "sugar-glyc-d3-b", "atoms":["C4", "+C1", "+C2", "+C3"], "ifnext": "[0-9].B"}
] ]
} }
} }
......
...@@ -113,7 +113,8 @@ ...@@ -113,7 +113,8 @@
"maxLength": 2, "maxLength": 2,
"uniqueItems": true, "uniqueItems": true,
"items": {"type": "string"} "items": {"type": "string"}
} },
"ifnext": {"type": "string"}
} }
}, },
...@@ -129,7 +130,8 @@ ...@@ -129,7 +130,8 @@
"maxLength": 3, "maxLength": 3,
"uniqueItems": true, "uniqueItems": true,
"items": {"type": "string"} "items": {"type": "string"}
} },
"ifnext": {"type": "string"}
} }
}, },
...@@ -145,7 +147,8 @@ ...@@ -145,7 +147,8 @@
"maxLength": 4, "maxLength": 4,
"uniqueItems": true, "uniqueItems": true,
"items": {"type": "string"} "items": {"type": "string"}
} },
"ifnext": {"type": "string"}
} }
}, },
......
...@@ -76,7 +76,6 @@ class MolDatabase: ...@@ -76,7 +76,6 @@ class MolDatabase:
for mol in self.molecules.values(): for mol in self.molecules.values():
used_templates = set() used_templates = set()
while mol.templates: while mol.templates:
print(mol.templates)
template = mol.templates.pop() template = mol.templates.pop()
if template not in used_templates: if template not in used_templates:
mol.extend(self.molecules[template]) mol.extend(self.molecules[template])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment