Re: [AMBER] Small NAB program: Not getting desired output

From: David A Case <>
Date: Thu, 16 Oct 2014 08:11:07 -0400

On Thu, Oct 16, 2014, Himanshu Joshi wrote:

> When I redefine n=NULL before executing the wc_helix
> for molecule m2 again in the program it works fine,
> But I don't understand why it doesn't take the NULL value
> when I define it once.

nab uses the Fortran convention for passing arguments to subroutines: it
always passes arguments by reference, so they might be changed in the
underlying routine (wc_helix, in this case). You should print out "n" after
the first call, and see what is there.

If you want an empty string, use: n = ""; in place of n=NULL;
(although I guess the latter will work, but you are relying the details of how
the nab compiler implements strings.)

...hope this helps...dac

AMBER mailing list
Received on Thu Oct 16 2014 - 05:30:04 PDT
Custom Search