-
Notifications
You must be signed in to change notification settings - Fork 652
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improper ordering in MDAnalysis #2386
Comments
There's more to this... CHARMM (PSF) and GROMACS (ITP/TPR) have the central atom in an improper first, while AMBER (PRMTOP) has it third. None of the related parsers rearrange Improper atom ordering. I think this will complicate outputting to a standard topology structure like Parmed in #2404. |
So MDA currently uses this definition of improper: http://cbio.bmt.tue.nl/pumma/uploads/Theory/improper.png This looks like what gromacs also uses: So the angle between the plane of IJK and plane of JKL. With this definition the order can be reversed. Amber looks like it didn't have a standard: ? So I think reversing it seems harmless, but I'm not sure why it was reversed... |
Sorry, trying to catch up here, but I'll happily take the blame for any non-standard improper ordering on reading parm7 files in mda. If this helps in any way, I believe the attempt in the reader was just to read the atom indices for each dihedral (be it improper or not) purely based on the order that they are written in the parm7 file. |
Ah I just reread all this, so it looks like if Amber has the central atom as k, then we need to rearrange to get the same angle. |
So on the note of reversal of the i,j,k,l order, this discussion might be worth noting: https://mailman-1.sys.kth.se/pipermail/gromacs.org_gmx-users/2013-April/080824.html Appending the central atom as the first entry isn't too much of a change, but going by this comment openmm/openmm#220 (comment) consistently ordering the remaining atoms is not immediately obvious to me (I am probably just missing something obvious). I was thinking just following whatever logic parmed takes when converting between parm7 to top files might be the best idea here, but I'm not actually sure that any re-ordering actually takes place. Creating an { ACE PHE NME } peptide in
which relates to the following parmed-generated human readable entry (just divide by 3 and add one to the numbers to get the corresponding atom number):
now converting this via parmed (3.2.0) to a .top file gives you the following dihedral entry:
Again, I should point out that is has been a long day, and I am most likely misunderstanding something. |
Looking through Parmed a bit, it puts central atoms first for harmonic improper dihedrals, but third for periodic impropers (which all of AMBER's are). GROMACS periodic impropers (dihedrals type 4) are identical to periodic propers:
Interestingly, according to the DIHEDRALS_INC_HYDROGEN section of the prmtop format:
So it looks like impropers are symmetric, oops. But it's probably worth tracking which are harmonic and which are periodic, at least for ParmEd i/o. |
So not relevant to the the discussion on impropers, but on a larger side note on AMBER topologies here (considering the whole ParmEd i/o), beyond impropers we have a wider issue that some of the fancier terms are not supported / read by MDAnalysis. Of particular note here is that CMAP terms are not supported. For now ParmEd doesn't support ff19SB-style CMAP terms, however we might need to implement a means at topology read to block/warn users that load say ff19SB parm7 files (I haven't tried this yet, but one of my students claims it just works), and then try to pass it to ParmEd, that not all the terms in the original parm7 are accounted for. |
Closed due to not being real issue. |
Expected behavior
Impropers, where the central atom is
typically located in the third indexlocated in varying non-symmetric places (see below), are faithfully represented in MDAnalysis.Actual behavior
MDAnalysis shows a representation where Improper.values[0] < Improper.values[-1].
Looking at the topology impropers:
(35, 43, 34, 31) is now (31, 34, 43, 35).
Code to reproduce the behavior
Show us how to reproduce the failiure. If you can, use trajectory files from the test data.
Currently version of MDAnalysis
python -c "import MDAnalysis as mda; print(mda.__version__)"
) 0.20.1python -V
)? 3.7.3The text was updated successfully, but these errors were encountered: