AW: keeping a protein in a solvation box

From: Norman Geist (
Date: Wed Jun 13 2012 - 01:17:06 CDT



If you think the moving of your protein is unnatural, it possibly come due
to the pme. For that, there are two parameters that can remove the center of
mass drift. One for the simulation start, to remove the com motion from the
velocities "COMmotion" and one for during the simulation "zeromomentum".


On the other hand the moving of your protein might be normal and simple
thermodynamic. To visualize the periodic box correctly, you need to wrap the
coordinates. I wouldn't suggest to let namd do this, as you have no
parameters for that, there will occur overlong bonds, as every atom that
crosses the boundary will get wrapped. The better option is to do the
wrapping within VMD. For that, it could look like:


1. Load your psf and trajectory (dcd trajectory will contain box

2. pbc wrap -all -compound res -center com -centersel protein

3. pbc box (draw a dynamic box)


The wrapping example will wrap -all frames and does only wrap residues when
they completely crossed the boundary (good for water to prevent long bond
behavior) and will recenter the box around the CenterOfMass of your protein
so the protein will not be distorted (as long as it still fits in the box).




Norman Geist.


Von: [] Im Auftrag
von Aaron Oakley
Gesendet: Mittwoch, 13. Juni 2012 05:27
Betreff: Re: namd-l: keeping a protein in a solvation box


On 13/06/2012, at 1:03 PM, Dr. Eddie wrote:

Thanks for the info!


Now correct me if I am wrong (and I pretty sure I am) but I can't understand
the following. If I have a piece if a protein which is sticking out of my
pbc solvated box, say residue 1, then there is no solvant for residue 1 to
interact with except the on periodic boundary and in the box. But around
residue 1 there is no solvant since it wrap (wrapWater). So it seems it
would be in vacuum but not see any surface tension of the solvant due to the
pbc. Where is my misunderstanding?


The residue WILL interact with solvent, but it will be with the solvent
molecules on the other side of the periodic system.


When I look at this using vmd I see part of the protein leave the box. If I
add a periodic image then it looks like the part that left the box is
solvated. But as mentioned above this seems like an illusion.


It is NOT an illusion. NAMD calculates interactions across the periodic


Thanks for pasting the code! I think I have a vague understanding of what it
will do. Just so I am clear, if I only have a protein in water and I want to
align my protein I need only add


beneath # write your atom selection as per the user's manual

Is that correct.

Thanks very much for your help and patience!




On Tue, Jun 12, 2012 at 6:52 PM, Giacomo Fiorin <>

And at any rate, Eddie, your protein never leaves the box, for as long as
you have PBCs enabled. Most of the time you're sure of that, if you want to
be 100% sure look into using VMD to wrap the coordinates.


On Tue, Jun 12, 2012 at 7:50 PM, Giacomo Fiorin <>

Thanks Aaron! You beat me to this.


However, I can see another email coming requesting to clarify, so I'm
pasting here the example configuration. The last time I sent this to namd-l
was a while ago and may not show up easily in a keyword search.


colvar {


    name com

    width 1.0


    distance {

        group1 {

            # write your atom selection as per the user's manual


        group2 {

            # change the position of this dummyAtom if you want a different

            # point as the center

            dummyAtom (0.0, 0.0, 0.0)






colvar {


    name orient

    width 0.05


    orientation {

        atoms {

            # write your atom selection as per the user's manual


        refPositionsFile reference_coordinates.pdb





harmonic {

    colvars com orient

    forceConstant 10.0

    centers 0.0 (1.0, 0.0, 0.0, 0.0)




On Tue, Jun 12, 2012 at 7:45 PM, Aaron Oakley <> wrote:

You could use collective variables to remove the rotation/translation
component of your macromolecule.


On 13/06/2012, at 8:44 AM, Dr. Eddie wrote:

> Hi all,
> What is the best way to keep a protein inside a solvation box?
> With wrapwater and wrapall on my protein still climbs out of the box
(presumably still experiencing solvation due to periodic boundary
conditions, but I can't be sure). I'd like the protein to stay in the box.
Should I fix one single atom in the protein? Is there a better way than just
making an enormous box?
> Thanks,
> Eddie




A/Prof Aaron Oakley
School of Chemistry
University of Wollongong
Northfields Avenue
Wollongong, NSW, 2522
Phone: (02) 4221 4347
Fax:   (02) 4221 4287

This archive was generated by hypermail 2.1.6 : Mon Dec 31 2012 - 23:21:39 CST