Re: tcl interface

From: Jérôme Hénin (jerome.henin_at_uhp-nancy.fr)
Date: Thu Nov 13 2003 - 05:16:20 CST

Hi,

The 'loadcoords' command only gives the coordinates of atoms and atom groups
declared using 'addatom' and 'addgroup'. 'loadforces' only returns the forces
that were applied at the previous timestep using the 'addforce' command.
So your TCL script should call 'adatom' or 'addgroup' to specify requested
coordinates, for example at the beginning, before the definition of
calcforces.

Cheers,
Jerome

Le Jeudi 13 Novembre 2003 12:07, C. Ecker a écrit :
> Hello,
>
> I want to add forces during the simulation using the Tcl interface. There
> appears to be a problem with loadcoords and loadforces:
>
> proc calcforces {} {
> loadcoords p
> puts "length of array p : [array size p]"
> puts "the indices are: [array names p]"
>
> ...
>
> gives the following output:
>
> length of array p : 0
> the indices are:
>
> Obviously the coordinate array p is empty ! I am a dumb beginner with namd
> and Tcl, but I think the script should work. I tried this with the files
> from the namd tutorial (ubiquitin). I am using NAMD 2.5b1.
>
> Thanks,
> Christof
>
> Humboldt-Universitaet zu Berlin
> Institut fuer Physik
> Physik von Makromolekuelen
> Newtonstraße 15
> D-12489 Berlin
>
> fon: +49-30-2093 8030
> fax: +49-30-2093 7632

-- 
Jérôme Hénin
Equipe Dynamique des Assemblages Membranaires
Université Henri Poincaré / CNRS    UMR 7565
B.P. 239	54506 Vandoeuvre-lès-Nancy Cedex
Tel : (33) 3 83 68 43 95	Fax : (33) 3 83 68 43 71

This archive was generated by hypermail 2.1.6 : Wed Feb 29 2012 - 15:37:08 CST