Re: [AMBER] How to modify/add velocity entries in .inpcrd file?

From: Jason Swails <jason.swails.gmail.com>
Date: Thu, 13 Jun 2013 19:18:32 -0400

On Thu, Jun 13, 2013 at 6:56 PM, Yan Duan <yduan1.ualberta.ca> wrote:

> Dear Amber users:
> I'm a novice to AMBER, after some searching, now I'm able to generate a
> prmtop and an .inpcrd file for a lipid bilayer and water molecules on its
> two sides.
> Now if I would like to assign velocities to the water molecules, I
> suppose I have to add some velocities entries to the .inpcrd file. But how
> could I do this job? When I tried to open the .inpcrd file, it shows like
> this:
>

I suggest against doing this by hand unless you have a very good reason to
do so. There are options to have the MD engine (sander or pmemd) assign
random velocities from a Maxwell-Boltzmann distribution according to some
initial temperature if you want.


>
> default_name
> 31898
> 17.5461438 35.6096227 48.2661678 17.0901438 35.3456227 47.2871678
> 18.3911438 36.2836227 48.0081678 16.4821438 36.0866227 49.1591678
> 16.7801438 36.1036227 50.2291678 15.7011438 35.2986227 49.0931678
> 15.7651438 37.4206227 48.7571678 15.2341438 37.7986227 49.6571678
> 16.4951438 38.2286227 48.5381678 14.8781438 37.2736227 47.5981678
> ......................................(thousands of lines like above)
>
> They are just some numbers without much physical meaning mentioned.
> Could someone help with this problem?
> So many thanks in advance!
>

However, when asked a question "How do you do X?", I rarely like the
answer "Don't do X.", so I'll provide an answer to your question here.
 (Again, I suggest against this approach). The inpcrd file consists of the
X, Y, and Z-coordinates of every atom in the system in the same order that
those atoms appear in the prmtop file, followed by the X, Y, and
Z-coordinates of the velocities of every atom in the system (in the same
order as the coordinates). The very last line, at the end of the
coordinates and velocities, is the 3 box lengths and and 3 box angles.
 Since each line has 6 double-precision numbers, it represents the
coordinates or velocities for 2 atoms. So your file should have 15952
lines in it (the 2 header lines, the box line, and 15949 coordinate lines)
if it does not have velocities (tleap and minimization restart files do not
have velocities). If your file has velocities, it will have 31901 lines
(31898 lines with coordinates + velocities, then the 2 header lines and the
box line).

I would consider doing this to be quite advanced, however, since there are
many things to consider (is the system relaxed of bad contacts? Is the
density equilibrated? Did you add 'good' velocities [harder than it
sounds]? did you use the proper flags so sander/pmemd use the velocities
instead of overwriting them with something else? etc.).

HTH,
Jason

-- 
Jason M. Swails
Quantum Theory Project,
University of Florida
Ph.D. Candidate
352-392-4032
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Thu Jun 13 2013 - 16:30:03 PDT
Custom Search