Page 1 of 1

CHAIN Application fails to execute

Posted: Tue May 26, 2009 6:08 am
by Chaup
Hello, I have tried to change parameters in a copy of the Nitrogen example in the CHAIN application of stanmod. Unfortunately whenever I change any parameter it fails to run and I get no output data. Not sure what is the problem here. Sometimes if I change parameters from the txt file it works but this is not always successful and very slow way of doing it. Every time it fails to run, it seems my input data is corrupted and I must copy over again with the Nitrogen example to get it to execute. You help is most appreciated.

Posted: Tue May 26, 2009 1:39 pm
by Jirka
When I wrote GUI for CHAIN I assumed that the computational module reads input using free format (i.e., it is not important where numbers on a particular line are, as long as they are in the right sequence). It is apparently not the case and the format is exactly given. That's why the GUI does not conform with required format and you need to modify the input file manually. SOrry for that.

J.

Posted: Wed May 27, 2009 12:20 am
by Chaup
Thanks Jirka for your timely response,
can you suggest an appropriate format I should be manually entering my parameters? I am opening the input file in notepad and this normally leads to a non-execution after a few changes.

Posted: Wed May 27, 2009 12:28 am
by Jirka
The input format in CHAIN is as follows:

iVer = iGetFileVersion(5,1)
READ(5,1001) TITLE
read(5,*)
READ(5,1000) NS,NR,NB,KSURF,KDB,KPR,V,D,WC,TP
read(5,*)
READ(5,1002) (R(I),I=1,4),(DONE(I),I=1,4)
read(5,*)
READ(5,1002) (ZERO(I),I=1,4),(GAMMA(I),I=1,4)
read(5,*)
READ(5,1002) XI,DX,XM,TI,DT,TM
read(5,*)
READ(5,1002) (B(I),I=1,10)

1000 FORMAT(6I5,5F10.0)
1001 FORMAT(A60)
1002 FORMAT(10F10.0)

Posted: Thu May 28, 2009 12:04 am
by Chaup
Thanks so much Jirka, I think I might have this all figured out now!