<html>
<body>
<div style='font: 12pt sans-serif;'>
  
    
  
  Hi Tsjerk!
  <br />That is where I encountered NANs problem (except it was 10 eigenvectos, but for 1 NANs appears as well). I used -over option to check eigenvectors only.
  <br />
  <br />Now it seems for me that it is a bug and not my stupid typing mistake. What can really help in this case (IMHO!) is my problem in your debugger - I found that the problem appears even if I try to project trajectory of single frame gro file:
  <br />g_anaeig_d -v sss_1000_eigenvec.trr -f sss_after_mdsi_1000.gro -s sss_mdsi_1000.tpr -first 1 -last 1 -n sss.ndx -proj
  <br />so I can send you gzipped problem.
  <br />Regards,
  <br />Alex.
  <br />
  <br />
  <blockquote class="ukr_editor_quotation" style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;">
  <br />
  <br />Message: 6
  <br />Date: Fri, 30 Oct 2009 12:53:28 +0100
  <br />From: Tsjerk Wassenaar &lt;tsjerkw@gmail.com&gt;
  <br />Subject: Re: [gmx-users] NAN in g_anaeig -proj
  <br />To: Discussion list for GROMACS users &lt;gmx-users@gromacs.org&gt;
  <br />Message-ID:
  <br />&lt;8ff898150910300453n550a6358sf596cff4771c95b4@mail.gmail.com&gt;
  <br />Content-Type: text/plain; charset=ISO-8859-1
  <br />
  <br />Hi Alex,
  <br />
  <br />Sorry for not replying earlier. Still haven't had time to do checks
  <br />myself. But have you already tried to see what happens if you only
  <br />request projections?:
  <br />
  <br />g_anaeig_d -v sss_1000_eigenvec.trr -f sss_mdsi_1000.trr -s
  <br />sss_mdsi_1000.tpr -first 1 -last 1 -n sss.ndx -proj
  <br />
  <br />Cheers,
  <br />
  <br />Tsjerk
  <br />
  <br />2009/10/29 alexander yakovenko &lt;yakovenko_a@ukr.net&gt;:
  <br />&gt; Hi all!
  <br />&gt; I just wonder if anyone run (know solution) into a problem trying to project
  <br />&gt; a trajectory on the eigenvector(s) (with g_anaeig -proj ) from covariace
  <br />&gt; matrix.
  <br />&gt; All projections I have calculated are nan. However, the eigenvalues are OK
  <br />&gt; and the g_anaeig -comp -v2 -eig2 -over options works OK so eigenvectors
  <br />&gt; seems are OK  (but g_anaeig -2d fails to nan too). I am using gromacs-4.0.5
  <br />&gt; on x86-64 CentOS5 (compiled with gcc-34).
  <br />&gt; Regards,
  <br />&gt; Alex.
  <br />&gt; P.S. The sequence of commands that reveals the problem is attached bellow:
  <br />&gt;
  <br />&gt; g_covar_d -f sss_mdsi_1000.trr -s sss_mdsi_1000.tpr -n sss.ndx -o
  <br />&gt; sss_1000_eigenval.xvg -xpm sss_1000_covar.xpm -v sss_1000_eigenvec.trr -mwa
  <br />&gt; -l
  <br />&gt; ...
  <br />&gt; Option     Filename  Type         Description
  <br />&gt; ------------------------------------------------------------
  <br />&gt;   -f sss_mdsi_1000.trr  Input        Trajectory: xtc trr trj gro g96 pdb cpt
  <br />&gt;   -s sss_mdsi_1000.tpr  Input        Structure+mass(db): tpr tpb tpa gro g96
  <br />&gt;                                    pdb
  <br />&gt;   -n        sss.ndx  Input, Opt!  Index file
  <br />&gt;   -o sss_1000_eigenval.xvg  Output       xvgr/xmgr file
  <br />&gt;   -v sss_1000_eigenvec.trr  Output       Full precision trajectory: trr trj
  <br />&gt;                                    cpt
  <br />&gt;  -av    average.pdb  Output       Structure file: gro g96 pdb
  <br />&gt;   -l      covar.log  Output       Log file
  <br />&gt; -ascii    covar.dat  Output, Opt. Generic data file
  <br />&gt; -xpm sss_1000_covar.xpm  Output, Opt! X PixMap compatible matrix file
  <br />&gt; -xpma    covara.xpm  Output, Opt. X PixMap compatible matrix file
  <br />&gt;
  <br />&gt; Option       Type   Value   Description
  <br />&gt; ------------------------------------------------------
  <br />&gt; -[no]h       bool   no      Print help info and quit
  <br />&gt; -nice        int    19      Set the nicelevel
  <br />&gt; -b           time   0       First frame (ps) to read from trajectory
  <br />&gt; -e           time   0       Last frame (ps) to read from trajectory
  <br />&gt; -dt          time   0       Only use frame when t MOD dt = first time (ps)
  <br />&gt; -tu          enum   ps      Time unit: ps, fs, ns, us, ms or s
  <br />&gt; -[no]xvgr    bool   yes     Add specific codes (legends etc.) in the output
  <br />&gt;                             xvg files for the xmgrace program
  <br />&gt; -[no]fit     bool   yes     Fit to a reference structure
  <br />&gt; -[no]ref     bool   no      Use the deviation from the conformation in the
  <br />&gt;                             structure file instead of from the average
  <br />&gt; -[no]mwa     bool   yes     Mass-weighted covariance analysis
  <br />&gt; -last        int    -1      Last eigenvector to write away (-1 is till the
  <br />&gt;                             last)
  <br />&gt; -[no]pbc     bool   yes     Apply corrections for periodic boundary
  <br />&gt; conditions
  <br />&gt;
  <br />&gt; Reading file sss_mdsi_1000.tpr, VERSION 4.0.5 (double precision)
  <br />&gt; Reading file sss_mdsi_1000.tpr, VERSION 4.0.5 (double precision)
  <br />&gt;
  <br />&gt; Choose a group for the least squares fit
  <br />&gt; Group     0 (      System) has 31748 elements
  <br />&gt; ...
  <br />&gt; Group    20 ( active_site) has    54 elements
  <br />&gt; Select a group: 20
  <br />&gt; Selected 20: 'active_site'
  <br />&gt;
  <br />&gt; Choose a group for the covariance analysis
  <br />&gt; Group     0 (      System) has 31748 elements
  <br />&gt; ...
  <br />&gt; Group    20 ( active_site) has    54 elements
  <br />&gt; Select a group: 20
  <br />&gt; Selected 20: 'active_site'
  <br />&gt; Calculating the average structure ...
  <br />&gt; trn version: GMX_trn_file (double precision)
  <br />&gt; Last frame       2000 time 2000.000
  <br />&gt;
  <br />&gt; Constructing covariance matrix (162x162) ...
  <br />&gt; Last frame       2000 time 2000.000
  <br />&gt; Read 2001 frames
  <br />&gt;
  <br />&gt; Trace of the covariance matrix: 6.22756 (u nm^2)
  <br />&gt;
  <br />&gt; 100%
  <br />&gt; Diagonalizing ...
  <br />&gt;
  <br />&gt; Sum of the eigenvalues: 6.22756 (u nm^2)
  <br />&gt;
  <br />&gt; Writing eigenvalues to sss_1000_eigenval.xvg
  <br />&gt;
  <br />&gt; Writing reference, average structure &amp; eigenvectors 1--162 to
  <br />&gt; sss_1000_eigenvec.trr
  <br />&gt;
  <br />&gt; Wrote the log to covar.log
  <br />&gt;
  <br />&gt; gcq#86: "Shake Barrels Of Whisky Down My Throat" (Throwing Muses)
  <br />&gt;
  <br />&gt;
  <br />&gt;
  <br />&gt; g_anaeig_d -v sss_1000_eigenvec.trr -eig sss_1000_eigenval.xvg -v2
  <br />&gt; sss_1000_eigenvec.trr -eig2 sss_1000_eigenval.xvg -f sss_mdsi_1000.trr -s
  <br />&gt; sss_mdsi_1000.tpr -first 1 -last 10 -n sss.ndx -proj -over
  <br />&gt;
  <br />&gt; ...
  <br />&gt;
  <br />&gt; Option     Filename  Type         Description
  <br />&gt; ------------------------------------------------------------
  <br />&gt;   -v sss_1000_eigenvec.trr  Input        Full precision trajectory: trr trj
  <br />&gt;                                    cpt
  <br />&gt;  -v2 sss_1000_eigenvec.trr  Input, Opt!  Full precision trajectory: trr trj
  <br />&gt;                                    cpt
  <br />&gt;   -f sss_mdsi_1000.trr  Input, Opt!  Trajectory: xtc trr trj gro g96 pdb cpt
  <br />&gt;   -s sss_mdsi_1000.tpr  Input, Opt!  Structure+mass(db): tpr tpb tpa gro g96
  <br />&gt;                                    pdb
  <br />&gt;   -n        sss.ndx  Input, Opt!  Index file
  <br />&gt; -eig sss_1000_eigenval.xvg  Input, Opt!  xvgr/xmgr file
  <br />&gt; -eig2sss_1000_eigenval.xvg  Input, Opt!  xvgr/xmgr file
  <br />&gt; -comp   eigcomp.xvg  Output, Opt. xvgr/xmgr file
  <br />&gt; -rmsf   eigrmsf.xvg  Output, Opt. xvgr/xmgr file
  <br />&gt; -proj      proj.xvg  Output, Opt! xvgr/xmgr file
  <br />&gt;  -2d     2dproj.xvg  Output, Opt. xvgr/xmgr file
  <br />&gt;  -3d     3dproj.pdb  Output, Opt. Structure file: gro g96 pdb
  <br />&gt; -filt  filtered.xtc  Output, Opt. Trajectory: xtc trr trj gro g96 pdb cpt
  <br />&gt; -extr   extreme.pdb  Output, Opt. Trajectory: xtc trr trj gro g96 pdb cpt
  <br />&gt; -over   overlap.xvg  Output, Opt! xvgr/xmgr file
  <br />&gt; -inpr    inprod.xpm  Output, Opt. X PixMap compatible matrix file
  <br />&gt;
  <br />&gt; Option       Type   Value   Description
  <br />&gt; ------------------------------------------------------
  <br />&gt; -[no]h       bool   no      Print help info and quit
  <br />&gt; -nice        int    19      Set the nicelevel
  <br />&gt; -b           time   0       First frame (ps) to read from trajectory
  <br />&gt; -e           time   0       Last frame (ps) to read from trajectory
  <br />&gt; -dt          time   0       Only use frame when t MOD dt = first time (ps)
  <br />&gt; -tu          enum   ps      Time unit: ps, fs, ns, us, ms or s
  <br />&gt; -[no]w       bool   no      View output xvg, xpm, eps and pdb files
  <br />&gt; -[no]xvgr    bool   yes     Add specific codes (legends etc.) in the output
  <br />&gt;                             xvg files for the xmgrace program
  <br />&gt; -first       int    1       First eigenvector for analysis (-1 is select)
  <br />&gt; -last        int    10      Last eigenvector for analysis (-1 is till the
  <br />&gt;                             last)
  <br />&gt; -skip        int    1       Only analyse every nr-th frame
  <br />&gt; -max         real   0       Maximum for projection of the eigenvector on the
  <br />&gt;                             average structure, max=0 gives the extremes
  <br />&gt; -nframes     int    2       Number of frames for the extremes output
  <br />&gt; -[no]split   bool   no      Split eigenvector projections where time is zero
  <br />&gt; -[no]entropy bool   no      Compute entropy according to the Quasiharmonic
  <br />&gt;                             formula or Schlitter's method.
  <br />&gt; -temp        real   298.15  Temperature for entropy calculations
  <br />&gt; -nevskip     int    6       Number of eigenvalues to skip when computing the
  <br />&gt;                             entropy due to the quasi harmonic approximation.
  <br />&gt;                             When you do a rotational and/or translational
  <br />&gt; fit
  <br />&gt;                             prior to the covariance analysis, you get 3 or 6
  <br />&gt;                             eigenvalues that are very close to zero, and
  <br />&gt;                             which should not be taken into account when
  <br />&gt;                             computing the entropy.
  <br />&gt;
  <br />&gt; trn version: GMX_trn_file (double precision)
  <br />&gt; Read mass weighted reference structure with 54 atoms from
  <br />&gt; sss_1000_eigenvec.trr
  <br />&gt; Read mass weighted average/minimum structure with 54 atoms from
  <br />&gt; sss_1000_eigenvec.trr
  <br />&gt; Read 162 eigenvectors (for 54 atoms)
  <br />&gt;
  <br />&gt; Read 162 eigenvalues from sss_1000_eigenval.xvg
  <br />&gt; Read mass weighted reference structure with 54 atoms from
  <br />&gt; sss_1000_eigenvec.trr
  <br />&gt; Read mass weighted average/minimum structure with 54 atoms from
  <br />&gt; sss_1000_eigenvec.trr
  <br />&gt; Read 162 eigenvectors (for 54 atoms)
  <br />&gt;
  <br />&gt; Read 162 eigenvalues from sss_1000_eigenval.xvg
  <br />&gt; Reading file sss_mdsi_1000.tpr, VERSION 4.0.5 (double precision)
  <br />&gt; Reading file sss_mdsi_1000.tpr, VERSION 4.0.5 (double precision)
  <br />&gt;
  <br />&gt; Note: the structure in sss_mdsi_1000.tpr should be the same
  <br />&gt;       as the one used for the fit in g_covar
  <br />&gt;
  <br />&gt; Select the index group that was used for the least squares fit in g_covar
  <br />&gt; Group     0 (      System) has 31748 elements
  <br />&gt; ...
  <br />&gt; Group    20 ( active_site) has    54 elements
  <br />&gt; Select a group: 20
  <br />&gt; Selected 20: 'active_site'
  <br />&gt;
  <br />&gt; Select an index group of 54 elements that corresponds to the eigenvectors
  <br />&gt; Group     0 (      System) has 31748 elements
  <br />&gt; ...
  <br />&gt; Group    20 ( active_site) has    54 elements
  <br />&gt; Select a group: 20
  <br />&gt; Selected 20: 'active_site'
  <br />&gt;
  <br />&gt; RMSD (without fit) between the two average structures: 0.000 (nm)
  <br />&gt;
  <br />&gt; 10 eigenvectors selected for output: 1 2 3 4 5 6 7 8 9 10
  <br />&gt; Last frame       2000 time 2000.000
  <br />&gt;
  <br />&gt; Calculating overlap between eigenvectors of set 2 with eigenvectors
  <br />&gt; 1 2 3 4 5 6 7 8 9 10
  <br />&gt;
  <br />&gt; Will compare the covariance matrices using 162 dimensions
  <br />&gt; Trace of the two matrices: 6.22756 and 6.22756
  <br />&gt; Square root of the traces: 2.49551 and 2.49551
  <br />&gt; The overlap of the covariance matrices:
  <br />&gt;   normalized:  1.000
  <br />&gt;        shape:  1.000
  <br />&gt;
  <br />&gt; gcq#334: "Aber wenn der Quarterback kommt, um dir die Brille abzunehmen Sag
  <br />&gt; ihm: Danke die bleibt wo sie ist" (Wir sind Helden)
  <br />&gt;
  <br />&gt;
  <br />&gt;
  <br />&gt;
  <br />&gt;
  <br />&gt; _______________________________________________
  <br />&gt; gmx-users mailing list    gmx-users@gromacs.org
  <br />&gt; http://lists.gromacs.org/mailman/listinfo/gmx-users
  <br />&gt; Please search the archive at http://www.gromacs.org/search before posting!
  <br />&gt; Please don't post (un)subscribe requests to the list. Use the
  <br />&gt; www interface or send it to gmx-users-request@gromacs.org.
  <br />&gt; Can't post? Read http://www.gromacs.org/mailing_lists/users.php
  <br />&gt;
  <br />
  <br />--
  <br />Tsjerk A. Wassenaar, Ph.D.
  <br />Junior UD (post-doc)
  <br />Biomolecular NMR, Bijvoet Center
  <br />Utrecht University
  <br />Padualaan 8
  <br />3584 CH Utrecht
  <br />The Netherlands
  <br />P: +31-30-2539931
  <br />F: +31-30-2537623
  <br />
  <br />------------------------------
  <br />
  <br />_______________________________________________
  <br />gmx-users mailing list
  <br />gmx-users@gromacs.org
  <br />http://lists.gromacs.org/mailman/listinfo/gmx-users
  <br />Please search the archive at http://www.gromacs.org/search before posting!
  <br />
  <br />End of gmx-users Digest, Vol 66, Issue 195
  <br />******************************************
  <br />
  <br /></blockquote>
  <br />
  <br />Alexander Yakovenko
  <br />Institute of Molecular Biology &amp; Genetic of NAS of Ukraine
  <br />03143
  <br />acad.Zabolotnogo str. 150
  <br />Kiev
  <br />Ukraine
  <br />______________________________________________
  <br />E-mail: yakovenko_a@ukr.net
  <br />
  <br />
  <a href="http://www.ukr.net/2Bucwn/footer/804b93">Íå ìîæåøü íàéòè ðàáîòó?
  <br />1,5 òûñÿ÷è íîâûõ âàêàíñèé åæåäíåâíî íà JOB.ukr.net</a>.


</div></body>
</html>