Re: [AMBER] Question for residues.py to parameterize a nonstandard residue for constant pH MD

From: Jason Swails <jason.swails.gmail.com>
Date: Mon, 29 Sep 2014 07:47:42 -0400

On Sun, 2014-09-28 at 11:46 -0700, Levi Pierce wrote:
> So it looks like this block in cpinutil.py is wonky??? We are hitting the
> if statement and it gets evaluated like so
>
> parm.ptr('natom') = 69
> parm.parm_data['RESIDUE_POINTER'][resnum-1] = 1
>
> so natoms = 68
>
> Then natoms does not equal len(res.atom_list) and we never add it to the
> list and we get an empty cpin file. If I comment out the continue it
> generates the cpin file correctly what exactly is this if statement
> checking for, should parm.parm_data['RESIDUE_POINTER'][resnum-1] actually
> evaluate to 0 and not 1?
>
> Thanks so much!

Ah, good catch. It's missing a "+1". The way this particular piece of
code works is to find out how many atoms are in that particular residue
by subtracting the index of the first atom of this residue from the
index of the first atom of the next residue. For the last residue, this
trick doesn't work, and the equivalent would be the first atom *after*
the last atom in the system (rather than the last atom in the system).

This block of code is pretty important, though, as it protects against
titrating a C-terminal titratable amino acid (which is not currently
supported and would probably ruin a simulation).

I believe this is the first time that anybody has actually tried to
titrate the last (or only) residue in a system (reference compounds for
amino acids are always capped, so they are never the last residue).

I have made this change, and I'll release an update for it shortly.

Thanks!
Jason

-- 
Jason M. Swails
BioMaPS,
Rutgers University
Postdoctoral Researcher
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Mon Sep 29 2014 - 05:00:03 PDT
Custom Search