Re: [gmx-users] k-means clustering in GROMACS

2007-01-07 Thread David van der Spoel

Nikos Sgourakis wrote:

Dear GROMACS users,

Here I have implemented the k-means clustering algorithm in the original 
GROMACS module, gmx_cluster.c (called by the wrapper g_cluster).
k-means is a heuristic algorithm that finds the partition of n points 
(conformations) in k groups (clusters), such that the sum of the 
distances of each point from the centroid of its belonging cluster is 
minimized.

To compile, re-run make after replacing the original file: `make g_cluster`
Most of the in-line options of the original program work. However, there 
are no output structure files. Instead, `./g_cluster -method kmeans etc` 
will produce a file with the indeces of all conformations within each 
one of the k clusters (k-means.dat), and a list of all centroids 
(centroids.dat).  The conformations can then be easily retrieved from 
the original trajectory file.
Please, let me know of any difficulties in compiling/running kmeans for 
GROMACS.


Nikos




Nikos,

first, thanks for contributing to gromacs. I have some questions about 
your code though. Have you run this code at all, and if so on what 
platform and with which compiler? The code contains this:


void kmeans(int k)
{
  int distr[k];

etc.

which is not standard C as far as I know. You can replace this by:

  int *dist;
  snew(distr,k);
  

  sfree(distr);

where snew and sfree are gromacs macros for allocating an array with 
length k for arbitrary  data types.


It would also be nice if you use a uniform indentation, preferable the 
emacs default.


Regards,
--
David.

David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group,
Dept. of Cell and Molecular Biology, Uppsala University.
Husargatan 3, Box 596,  75124 Uppsala, Sweden
phone:  46 18 471 4205  fax: 46 18 511 755
[EMAIL PROTECTED]   [EMAIL PROTECTED]   http://folding.bmc.uu.se

___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the 
www interface or send it to [EMAIL PROTECTED]

Can't post? Read http://www.gromacs.org/mailing_lists/users.php


[gmx-users] Centering using trjconv

2007-01-07 Thread Mitchell J Stanton-Cook
Hello All.

I am simulating t4 lysozyme with NAG. I have added a short peptide label
to lysozyme which binds calcium ions.

During the simulation there is some drift. I am attempting to re-center
the protein+label+NAG+Ca ion.

I am using trjconv and have setup an index file that contains only these
atom groups (protein+label+NAG+Ca ion).

First, I tried just centering using:

trjconv -f d61_15_25ns.gro -s md_initial.tpr -n analysis.ndx -center
tric -o test.pdb

This center's, however NAG and the calcium ion are not in the expected
positions.

Using:

trjconv -f d61_15_25ns.gro -s md_initial.tpr -n analysis.ndx -center
tric -o test.pdb -pbc whole

The ions and NAG are where they are expected, however, the protein has
been split.

Using inbox results in something similar.

Does anyone know how to do this?

Cheers Mitch


___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the 
www interface or send it to [EMAIL PROTECTED]
Can't post? Read http://www.gromacs.org/mailing_lists/users.php


Re: [gmx-users] PMF calculation

2007-01-07 Thread Mark Abraham
> Dear all,
> I am working on a tripeptide and would like to calculate Potential
> Mean Force for the tripeptide. Suggestions to calculate PMF are
> awaited.

How about looking for PMF in the manual and reading what it has to say there?

Mark

___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the
www interface or send it to [EMAIL PROTECTED]
Can't post? Read http://www.gromacs.org/mailing_lists/users.php


Re: [gmx-users] Re: question about dihedral angle in *.itp file

2007-01-07 Thread Mark Abraham
> Thank you very much for your answer!
> I have check manual in chapter4. I am still confused about this sentence.

Which sentence? Please either quote it, or refer precisely to it with a
reference. Nobody is going to read the whole of chapter 4 to find the one
relevant sentence that is confusing you :-)

> As we know, each dihedral was counted only once(?) in the program.
> however,
> if several torsional dihedral angles with different parameters can be
> defined
> on the same set of atoms i, j, k, and l, does this mean that this dihedral
> will
> be counted several times.

For purposes of GROMACS, a bonded function is defined by the function type
(an integer) and the set of atoms to which it applies. See table 5.4.
There may only be one instance of a given function type for a given set of
atoms. grompp will take the last such function that it finds. Thus you
cannot have multiple periodic dihedral functions on the same four atoms,
even if their multiplicity varies.

> for second question about multiplicity m
> i am really confused about the physical mean of m, according to equation
> V=k(1+Col(delta)*Cos(m*phi))
> it seems that m is just the periodiocity of Cosine function.
> Could anyone help me figure out, Thank you very much:)

That equation didn't come from the gromacs manual as far as I can see.
"multiplicity" and "periodicity" are referring to the same phenomenon -
that of the rate with which the sinusoid repeats itself. m determines the
number of minima the function has - the multiplicity. Thus for a H-C-C-H
dihedral you would want minima every 120 degrees, but for H-C=C-H every
180 degrees. The simplest functional form that will do both of these is a
sinusoid with a periodicity/multiplicity parameter. The derivation of the
word is from "multiple" in reference to a quantity, rather than "multiply"
the operation, if that helps.

Mark

___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the
www interface or send it to [EMAIL PROTECTED]
Can't post? Read http://www.gromacs.org/mailing_lists/users.php


[gmx-users] PMF calculation

2007-01-07 Thread chetana baliga

Dear all,
I am working on a tripeptide and would like to calculate Potential
Mean Force for the tripeptide. Suggestions to calculate PMF are
awaited.

Regards,
Chetana
___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the 
www interface or send it to [EMAIL PROTECTED]

Can't post? Read http://www.gromacs.org/mailing_lists/users.php


[gmx-users] Re: question about dihedral angle in *.itp file

2007-01-07 Thread linfu
Thank you very much for your answer!
I have check manual in chapter4. I am still confused about this sentence.
As we know, each dihedral was counted only once(?) in the program. however,
if several torsional dihedral angles with different parameters can be defined
on the same set of atoms i, j, k, and l, does this mean that this dihedral will
be counted several times.

for second question about multiplicity m
i am really confused about the physical mean of m, according to equation 
V=k(1+Col(delta)*Cos(m*phi))
it seems that m is just the periodiocity of Cosine function.
Could anyone help me figure out, Thank you very much:)

BEST REGARDS

Fu Lin


=== 2007-01-03 19:00:05 您在来信中写道:===

>Send gmx-users mailing list submissions to
>   gmx-users@gromacs.org
>
>To subscribe or unsubscribe via the World Wide Web, visit
>   http://www.gromacs.org/mailman/listinfo/gmx-users
>or, via email, send a message with subject or body 'help' to
>   [EMAIL PROTECTED]
>
>You can reach the person managing the list at
>   [EMAIL PROTECTED]
>
>When replying, please edit your Subject line so it is more specific
>than "Re: Contents of gmx-users digest..."
>
>
>Today's Topics:
>
>   1. Re: Error when adding a unnatural amio acid (David van der Spoel)
>   2. Re: question about dihedral angle in *.itp file
>  (David van der Spoel)
>   3. (no subject) (sharada)
>   4. Re: (no subject) (Mark Abraham)
>   5. Re: (no subject) (Caterina Arcangeli)
>
>
>--
>
>Message: 1
>Date: Wed, 03 Jan 2007 08:50:37 +0100
>From: David van der Spoel <[EMAIL PROTECTED]>
>Subject: Re: [gmx-users] Error when adding a unnatural amio acid
>To: Discussion list for GROMACS users 
>Message-ID: <[EMAIL PROTECTED]>
>Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
>yuemin liu wrote:
>> Hi, Everyone,
>> 
>> I got Error when adding a unnatural amio acid in a
>> protein. I have all the rtp and hdb file modified
>> using information either from ffgmx.rtp ffgmx.hdb or
>> thr rtp file form progdrg. There is no H1 in either
>> rtp file or my new pdb file. When I try use pdb2gmx to
>> generate top file, it always give the error message
>> following;
>> "Atom H1 not found in rtp database in residue ASO, it
>> looks a bit like H". I know it refers to the Hydrogen
>> of the peptide bond which has nothing wrong there.
>> 
>> Hope can get help from you with this,
>> 
>And by the way, avoid using ffgmx. Search archives for reasons why.
>
>-- 
>David.
>
>David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group,
>Dept. of Cell and Molecular Biology, Uppsala University.
>Husargatan 3, Box 596, 75124 Uppsala, Sweden
>phone: 46 18 471 4205  fax: 46 18 511 755
>[EMAIL PROTECTED]  [EMAIL PROTECTED]   http://folding.bmc.uu.se
>
>
>
>--
>
>Message: 2
>Date: Wed, 03 Jan 2007 08:51:47 +0100
>From: David van der Spoel <[EMAIL PROTECTED]>
>Subject: Re: [gmx-users] question about dihedral angle in *.itp file
>To: Discussion list for GROMACS users 
>Message-ID: <[EMAIL PROTECTED]>
>Content-Type: text/plain; charset=GB2312
>
>linfu wrote:
>> Dear GMX community!
>> 
>> I have a question about dihedral angle in *.itp file.
>> question 1:
>> 
>> why several torsional dihedral angles with different parameters can be 
>> defined
>> on the same set of atoms i, j, k, and l.
>
>why  not?
>
>> 
>> question 2:
>> 
>> how do we get multiplicity m if we want to make some parameter for some 
>> torsional 
>> angle.
>
>which functional form? check equations in chapter 4.
>
>
>-- 
>David.
>
>David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group,
>Dept. of Cell and Molecular Biology, Uppsala University.
>Husargatan 3, Box 596, 75124 Uppsala, Sweden
>phone: 46 18 471 4205  fax: 46 18 511 755
>[EMAIL PROTECTED]  [EMAIL PROTECTED]   http://folding.bmc.uu.se
>
>
>
>--
>
>Message: 3
>Date: Wed, 3 Jan 2007 13:31:44 +0530 (IST)
>From: sharada <[EMAIL PROTECTED]>
>Subject: [gmx-users] (no subject)
>To: gmx-users@gromacs.org
>Message-ID: <[EMAIL PROTECTED]>
>Content-Type: text/plain; charset="us-ascii"
>
>Hello gmx_users,
>I wish you a very happy and prosperous new year 2007.  I have a very 
>fundamental question in trjcat usage. I have two *.trr files of 5ns and 10 ns 
>runs . I  would like to concanate the two and make a 15ns trr file. How to 
>give the command so that the starting time of the 10ns file should be 5001ps 
>and not 0ps and end time is 15000ps and not 1 ps.  May this is a trivial 
>question. Kindly help.  I have tried using the following command :
>trjcat -f nchnp3_5npep.trr nchnp3_10p

[gmx-users] k-means clustering in GROMACS

2007-01-07 Thread Nikos Sgourakis

Dear GROMACS users,

Here I have implemented the k-means clustering algorithm in the 
original GROMACS module, gmx_cluster.c (called by the wrapper g_cluster).
k-means is a heuristic algorithm that finds the partition of n points 
(conformations) in k groups (clusters), such that the sum of the 
distances of each point from the centroid of its belonging cluster is 
minimized.

To compile, re-run make after replacing the original file: `make g_cluster`
Most of the in-line options of the original program work. However, there 
are no output structure files. Instead, `./g_cluster -method kmeans etc` 
will produce a file with the indeces of all conformations within each 
one of the k clusters (k-means.dat), and a list of all centroids 
(centroids.dat).  The conformations can then be easily retrieved from 
the original trajectory file.
Please, let me know of any difficulties in compiling/running kmeans for 
GROMACS.


Nikos

--
___
Nikolaos G. Sgourakis, MSc
Center for Biotechnology and Interdisciplinary studies
Troy, NY 12180
www.rpi.edu/~sgourn

/*
 * $Id: gmx_cluster.c,v 1.7.2.1 2005/12/15 10:07:46 hess Exp $
 * 
 *This source code is part of
 * 
 * G   R   O   M   A   C   S
 * 
 *  GROningen MAchine for Chemical Simulations
 * 
 *VERSION 3.2.0
 * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others.
 * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
 * Copyright (c) 2001-2004, The GROMACS development team,
 * check out http://www.gromacs.org for more information.

 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 * 
 * If you want to redistribute modifications, please consider that
 * scientific software is very special. Version control is crucial -
 * bugs must be traceable. We will be happy to consider code for
 * inclusion in the official distribution, but derived work must not
 * be called official GROMACS. Details are found in the README & COPYING
 * files - if they are missing, get the official version at www.gromacs.org.
 * 
 * To help us fund GROMACS development, we humbly ask that you cite
 * the papers on the package - you can find them in the top README file.
 * 
 * For more info, check our website at http://www.gromacs.org
 * 
 * And Hey:
 * Green Red Orange Magenta Azure Cyan Skyblue
 */
#ifdef HAVE_CONFIG_H
#include 
#endif
#include 
#include 
#include 
#include "macros.h"
#include "smalloc.h"
#include "typedefs.h"
#include "copyrite.h"
#include "statutil.h"
#include "tpxio.h"
#include "string2.h"
#include "vec.h"
#include "macros.h"
#include "index.h"
#include "random.h"
#include "pbc.h"
#include "xvgr.h"
#include "futil.h"
#include "matio.h"
#include "eigensolver.h"
#include "cmat.h"
#include "do_fit.h"
#include "trnio.h"
#include "viewit.h"

/* macro's to print to two file pointers at once (i.e. stderr and log) */
#define lo_ffprintf(fp1,fp2,buf) \
   fprintf(fp1,"%s",buf);\
   fprintf(fp2,"%s",buf);
/* just print a prepared buffer to fp1 and fp2 */
#define ffprintf(fp1,fp2,buf) { lo_ffprintf(fp1,fp2,buf) }
/* prepare buffer with one argument, then print to fp1 and fp2 */
#define ffprintf1(fp1,fp2,buf,fmt,arg) {\
   sprintf(buf,fmt,arg);\
   lo_ffprintf(fp1,fp2,buf)\
}
/* prepare buffer with two arguments, then print to fp1 and fp2 */
#define ffprintf2(fp1,fp2,buf,fmt,arg1,arg2) {\
   sprintf(buf,fmt,arg1,arg2);\
   lo_ffprintf(fp1,fp2,buf)\
}

typedef struct {
  int ncl;
  int *cl;
} t_clusters;

typedef struct {
  int nr;
  int *nb;
} t_nnb;
  
void pr_energy(FILE *fp,real e)
{
  fprintf(fp,"Energy: %8.4f\n",e);  
}

void cp_index(int nn,int from[],int to[])
{
  int i;
  
  for(i=0; (inn;
  snew(low_index,nn);
  cp_index(nn,m->m_ind,low_index);
  if (getenv("TESTMC")) {
e[cur] = mat_energy(m);
pr_energy(log,e[cur]);
fprintf(log,"Doing 1000 random swaps\n");
for(i=0; (i<1000); i++) {
  do {
isw = nn*rando(seed);
jsw = nn*rando(seed);
  } while ((isw == jsw) || (isw >= nn) || (jsw >= nn));
  iisw = m->m_ind[isw];
  jjsw = m->m_ind[jsw];
  m->m_ind[isw] = jjsw;
  m->m_ind[jsw] = iisw;
}
  }
  e[cur] = mat_energy(m);
  pr_energy(log,e[cur]);
  for(i=0; (i= nn) || (jsw >= nn));

iisw = m->m_ind[isw];
jjsw = m->m_ind[jsw];
ei   = row_energy(nn,iisw,m->mat[jsw]);
ej   = row_energy(nn,jjsw,m->mat[isw]);

e[next] = e[cur] + (ei+ej-EROW(m,isw)-EROW(m,jsw))/nn;

efac = kT ? exp((e[next]-e[cur])/kT) : -1;
if ((e[next] > e[cur]) || (efac > rando(seed))) {
  
  if (e[next] > e[cur])
cp_index(nn,m->m_ind,low_index);
  else
fprintf(log,"Taking uphill step\n");

  /* Now swapping rows */
  m->m_ind[isw] = jjsw;
  m->m_ind[jsw] = iisw;
  EROW

[gmx-users] GROMACS AMBER DNA TERMINUS

2007-01-07 Thread Andreas Kukol

Dear All,

I am using Gromacs 3.1.1 with the AMBER port. After following the 
instructions on the ffamber web-page, pdb2gmx works fine. But according 
to point 6:


"... However, for nucleic acids this also often causes pdb2gmx to 
replace an H atom in the first residue of all nucleic acid chains with 
an incorrect H atom, resulting in non-neutral charge. The correct atom 
is generally replaced with an atom of type amberXX_25 (hydroxyl H), as 
pdb2gmx treats it as a terminal hydrogen ..."


Indeed I find this atom in the first residue:

1 amber99_25  1DG5H5T  1 0.4422  1.008   ; qtot 
0.4422


The solution given (a) is to correct the atom type and charge in the 
.top file by hand.


My question is:
What is the correct atom type and charge for this hydrogen ?

The ffamber03.rtp contains exactly this atom type and charge in the 
specification for the residue DG5. So it should be correct ??


Many thanks
Andreas
___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the 
www interface or send it to [EMAIL PROTECTED]

Can't post? Read http://www.gromacs.org/mailing_lists/users.php


Re: [gmx-users] REMD demuxing

2007-01-07 Thread Nikos Sgourakis

Hello,
Instead of using system calls, you may also use the pymacs python 
interface by Daniel Seelinger:

http://www.mpibpc.mpg.de/groups/grubmueller/start/people/dseelig/pymacs.html
You can access all information in an xtc file in an object-oriented manner.
Nikos


Andrea C. Vaiana wrote:

Hello everyone,
I'm trying to find a better way of demuxing REMD runs, I wrote a 
python script to do this but it is very slow because it relies on 
system calls to trjconv in order to read/write frames. I checked the 
documentation and mailing lists, it seems that this should be possible 
using "trjcat -demux...". I've tried this and reached similar problems 
(seemingly unresolved...) as Merc Martens in july. I've attached the 
last mail from that thread at the bottom of this email.


I have an remd.xvg file that looks like this:

0.00   0   1   2   3   4   5   6   7   8   9   10   11   12   13   
15   14   16   17  
0.187500   0   1   2   3   4   5   6   7   8   9   10   11   12   13   
15   14   16   17
0.375000   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
15   14   16   17
0.562500   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
15   14   16   17
0.75   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
15   14   16   17
0.937500   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
16   14   15   17

.
.
.



When I run:
trjcat -dt 0.75 -f  run3.0.xtc ... run3.47.xtc -o  run3.U.0.xtc ... 
run3.U.47.xtc   -demux remd.xvg


NOTE: I dump to the xtc file every 0.75ps but I'm using an xvg file 
(created from my log file) with all the replica exchanges i.e., every 
0.1875ps. Would this cause problems?


I get 48 identical xtc files named: run3.U.0.xtc #run3.U0.xtc.1# ... 
#run3.U0.xtc.47#

each of these is very small (219 K wheras my trajectories are 10 M).

a gmxdump on one of these produces:

run3.U.0.xtc frame 0:
  natoms= 0  step= 0  time= 0  prec=2.8026e-45
  box (3x3):
 box[0]={ 5.65765e+00,  0.0e+00,  0.0e+00}
 box[1]={ 0.0e+00,  5.44156e+00,  0.0e+00}
 box[2]={ 0.0e+00,  0.0e+00,  5.42684e+00}
not available: x
run3.U.0.xtc frame 1:
  natoms= 0  step=   500  time=  0.75  prec=2.8026e-45
  box (3x3):
 box[0]={ 5.65765e+00,  0.0e+00,  0.0e+00}
 box[1]={ 0.0e+00,  5.44156e+00,  0.0e+00}
 box[2]={ 0.0e+00,  0.0e+00,  5.42684e+00}
not available: x
run3.U.0.xtc frame 2:
  natoms= 0  step=  1000  time=   1.5  prec=2.8026e-45
  box (3x3):
 box[0]={ 5.65765e+00,  0.0e+00,  0.0e+00}
 box[1]={ 0.0e+00,  5.44156e+00,  0.0e+00}
 box[2]={ 0.0e+00,  0.0e+00,  5.42684e+00}
not available: x
.
.
.

Does anyone know what's wrong?
Alternatively: does anyone have a fast python routine for 
reading/writing xtc frames?



thanks for any help.

Andrea


merc mertens
Mon, 17 Jul 2006 09:20:41 -0700

hello,

i am still trying to figure out how demultiplexing with trjcat 
(version 3.3.1) works.

i produced 3 trajectories, each containing only one frame:
e.g.

traj0.xtc frame 0:
   natoms= 14670  step=   500  time= 1  prec=  1000
   box (3x3):
  box[0]={ 8.47401e+00,  0.0e+00,  0.0e+00}
  box[1]={ 0.0e+00,  4.98164e+00,  0.0e+00}
  box[2]={ 0.0e+00,  0.0e+00,  3.48938e+00}
   x (14670x3):
  x[0]={ 1.95100e+00,  2.11100e+00,  3.09600e+00}
  x[1]={ 1.95000e+00,  2.14800e+00,  3.19000e+00}
  x[2]={ 1.88400e+00,  2.15100e+00,  3.03200e+00}
  x[3]={ 1.94800e+00,  2.01100e+00,  3.11200e+00}
...

traj1.xtc and traj2.xtc look the same (apart from containing 
different coordinates).


remd.xvg for -demux contains only one line:

"1 2 1 0"

using those files with:
trjcat -f traj0.xtc traj1.xtc traj2.xtc -demux remd.xvg

produces: trajout.xtc

trajout.xtc frame 0:
   natoms= 0  step=   500  time= 1  prec=  -1.99104
   box (3x3):
  box[0]={ 8.48018e+00,  0.0e+00,  0.0e+00}
  box[1]={ 0.0e+00,  4.98527e+00,  0.0e+00}
  box[2]={ 0.0e+00,  0.0e+00,  3.49192e+00}
not available: x

so, even if there are definitely coordinates in the trajectory and 
there can not be a mistake in the frame number, since there is only 
one, it seems strange to me, that trjcat does not output anything but 
the box to the *xtc file. further, the statement "not available: x" 
seems curious to me.

thanks for any help,
merc







  





--
___
Nikolaos G. Sgourakis, MSc
Center for Biotechnology and Interdisciplinary studies
Troy, NY 12180
www.rpi.edu/~sgourn


___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the 
www interface or send it to [EMAIL PROTECTED]

Can't post? Read htt

Re: [gmx-users] How can I generate a FCC unit cell?

2007-01-07 Thread Mark Abraham
> Hi gmx-users,
> I need to generate a FCC unit cell (in fact a face centered cubic lattice)
> in order to produce a nanocristal. I would like to know if is possible
> to make this using directly GROMACS. In affirmative case, as I can make
> it?

Setting up the contents of your periodic cell is not something gromacs
will do for you. Either you need to find other software, or do it by hand.
Once you have such a cell of the correct dimensions in a .pdb (or similar)
file, you can use editconf to describe the periodicity.

Mark

___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the
www interface or send it to [EMAIL PROTECTED]
Can't post? Read http://www.gromacs.org/mailing_lists/users.php


Re: [gmx-users] REMD demuxing

2007-01-07 Thread David van der Spoel

Andrea C. Vaiana wrote:

Hello everyone,
I'm trying to find a better way of demuxing REMD runs, I wrote a python 
script to do this but it is very slow because it relies on system calls 
to trjconv in order to read/write frames. I checked the documentation 
and mailing lists, it seems that this should be possible using "trjcat 
-demux...". I've tried this and reached similar problems (seemingly 
unresolved...) as Merc Martens in july. I've attached the last mail from 
that thread at the bottom of this email.


I have an remd.xvg file that looks like this:

0.00   0   1   2   3   4   5   6   7   8   9   10   11   12   13   
15   14   16   17  
0.187500   0   1   2   3   4   5   6   7   8   9   10   11   12   13   
15   14   16   17
0.375000   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
15   14   16   17
0.562500   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
15   14   16   17
0.75   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
15   14   16   17
0.937500   0   1   2   3   5   4   6   7   8   9   10   11   12   13   
16   14   15   17

.
.
.



When I run:
trjcat -dt 0.75 -f  run3.0.xtc ... run3.47.xtc -o  run3.U.0.xtc ... 
run3.U.47.xtc   -demux remd.xvg


NOTE: I dump to the xtc file every 0.75ps but I'm using an xvg file 
(created from my log file) with all the replica exchanges i.e., every 
0.1875ps. Would this cause problems?


I get 48 identical xtc files named: run3.U.0.xtc #run3.U0.xtc.1# ... 
#run3.U0.xtc.47#

each of these is very small (219 K wheras my trajectories are 10 M).

a gmxdump on one of these produces:

run3.U.0.xtc frame 0:
  natoms= 0  step= 0  time= 0  prec=2.8026e-45
  box (3x3):
 box[0]={ 5.65765e+00,  0.0e+00,  0.0e+00}
 box[1]={ 0.0e+00,  5.44156e+00,  0.0e+00}
 box[2]={ 0.0e+00,  0.0e+00,  5.42684e+00}
not available: x
run3.U.0.xtc frame 1:
  natoms= 0  step=   500  time=  0.75  prec=2.8026e-45
  box (3x3):
 box[0]={ 5.65765e+00,  0.0e+00,  0.0e+00}
 box[1]={ 0.0e+00,  5.44156e+00,  0.0e+00}
 box[2]={ 0.0e+00,  0.0e+00,  5.42684e+00}
not available: x
run3.U.0.xtc frame 2:
  natoms= 0  step=  1000  time=   1.5  prec=2.8026e-45
  box (3x3):
 box[0]={ 5.65765e+00,  0.0e+00,  0.0e+00}
 box[1]={ 0.0e+00,  5.44156e+00,  0.0e+00}
 box[2]={ 0.0e+00,  0.0e+00,  5.42684e+00}
not available: x
.
.
.

Does anyone know what's wrong?
Alternatively: does anyone have a fast python routine for 
reading/writing xtc frames?



thanks for any help.

Andrea


merc mertens
Mon, 17 Jul 2006 09:20:41 -0700

hello,

i am still trying to figure out how demultiplexing with trjcat 
(version 3.3.1) works.

i produced 3 trajectories, each containing only one frame:
e.g.

traj0.xtc frame 0:
   natoms= 14670  step=   500  time= 1  prec=  1000
   box (3x3):
  box[0]={ 8.47401e+00,  0.0e+00,  0.0e+00}
  box[1]={ 0.0e+00,  4.98164e+00,  0.0e+00}
  box[2]={ 0.0e+00,  0.0e+00,  3.48938e+00}
   x (14670x3):
  x[0]={ 1.95100e+00,  2.11100e+00,  3.09600e+00}
  x[1]={ 1.95000e+00,  2.14800e+00,  3.19000e+00}
  x[2]={ 1.88400e+00,  2.15100e+00,  3.03200e+00}
  x[3]={ 1.94800e+00,  2.01100e+00,  3.11200e+00}
...

traj1.xtc and traj2.xtc look the same (apart from containing different 
coordinates).


remd.xvg for -demux contains only one line:

"1 2 1 0"

using those files with:
trjcat -f traj0.xtc traj1.xtc traj2.xtc -demux remd.xvg

produces: trajout.xtc

trajout.xtc frame 0:
   natoms= 0  step=   500  time= 1  prec=  -1.99104
   box (3x3):
  box[0]={ 8.48018e+00,  0.0e+00,  0.0e+00}
  box[1]={ 0.0e+00,  4.98527e+00,  0.0e+00}
  box[2]={ 0.0e+00,  0.0e+00,  3.49192e+00}
not available: x

so, even if there are definitely coordinates in the trajectory and 
there can not be a mistake in the frame number, since there is only 
one, it seems strange to me, that trjcat does not output anything but 
the box to the *xtc file. further, the statement "not available: x" 
seems curious to me.

thanks for any help,
merc







  


There is a perl script in src/contrib/scripts which does what you need, 
i.e. generate input to trjcat.


--
David.

David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group,
Dept. of Cell and Molecular Biology, Uppsala University.
Husargatan 3, Box 596,  75124 Uppsala, Sweden
phone:  46 18 471 4205  fax: 46 18 511 755
[EMAIL PROTECTED]   [EMAIL PROTECTED]   http://folding.bmc.uu.se

___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo

Re: [gmx-users] How can I generate a FCC unit cell?

2007-01-07 Thread David van der Spoel

Eudes Fileti wrote:

Hi gmx-users,
I need to generate a FCC unit cell (in fact a face centered cubic lattice)
in order to produce a nanocristal. I would like to know if is possible
to make this using directly GROMACS. In affirmative case, as I can make it?
Thanks in advance

___
Eudes Eterno Fileti
Centro de Ciência Naturais e Humanas
Universidade Federal do ABC
Rua Santa Adélia, 166
CEP 09210-170
skype: eefileti
___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the www 
interface or send it to [EMAIL PROTECTED]

Can't post? Read http://www.gromacs.org/mailing_lists/users.php
No, you'll have to provide starting coordinates yourself. However once 
you have a unitcell you can multiply it using genconf.


--
David.

David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group,
Dept. of Cell and Molecular Biology, Uppsala University.
Husargatan 3, Box 596,  75124 Uppsala, Sweden
phone:  46 18 471 4205  fax: 46 18 511 755
[EMAIL PROTECTED]   [EMAIL PROTECTED]   http://folding.bmc.uu.se

___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the
www interface or send it to [EMAIL PROTECTED]
Can't post? Read http://www.gromacs.org/mailing_lists/users.php


[gmx-users] How can I generate a FCC unit cell?

2007-01-07 Thread Eudes Fileti

Hi gmx-users,
I need to generate a FCC unit cell (in fact a face centered cubic lattice)
in order to produce a nanocristal. I would like to know if is possible
to make this using directly GROMACS. In affirmative case, as I can make it?
Thanks in advance

___
Eudes Eterno Fileti
Centro de Ciência Naturais e Humanas
Universidade Federal do ABC
Rua Santa Adélia, 166
CEP 09210-170
skype: eefileti
___
gmx-users mailing listgmx-users@gromacs.org
http://www.gromacs.org/mailman/listinfo/gmx-users
Please don't post (un)subscribe requests to the list. Use the
www interface or send it to [EMAIL PROTECTED]
Can't post? Read http://www.gromacs.org/mailing_lists/users.php