[molpro-user] Passing variables to INCLUDE cards

Brian Prascher bprascher at yahoo.com
Mon Jul 23 21:09:48 BST 2007


I am trying to write a DO loop in Molpro that will loop over a bunch of external basis set files. The following are examples of the scripts I wrote thinking they would work, but they do not. Any help would be appreciated.

B=["basis1","basis2","basis3"]
do i=1,#B
  basisfile='$B(i)'
  basis
  include,$basisfile;
  end;
  {rhf ....}
  ...
enddo

--OR--

B=["basis1","basis2","basis3"]

do i=1,#B

  basis

  include,$B(i);

  end;

  {rhf ....}

  ...

enddo

The error I get is...

 do i=1,3
   basisfile='$B(i)'
   basis
 Including file /scratch/bpp0004.14858/$basisfile
 
 File /scratch/bpp0004.14858/$basisfile does not exist
 Input error

So, it is obviously trying to pass "$basisfile" verbatim to the command line. Is there anyway around this?

Thanks,
~brian

Reply to bprascher at yahoo.com 
---
"Great spirits have always encountered violent opposition from mediocre minds."  --Albert Einstein
 
"It is far better to grasp the universe as it really is than to persist in delusion, however satisfying and reassuring."  --Carl Sagan





       
____________________________________________________________________________________
Yahoo! oneSearch: Finally, mobile search 
that gives answers, not web links. 
http://mobile.yahoo.com/mobileweb/onesearch?refer=1ONXIC




More information about the Molpro-user mailing list