/*ParseAtom parse the FeII command */ #include #include "cddefines.h" #include "lgmatch.h" #include "ffmtread.h" #include "nonumb.h" #include "pop371.h" #include "parse.h" void ParseAtom(char *chCard ) { # ifdef DEBUG_FUN fputs( "<+>ParseAtom()\n", debug_fp ); # endif if( lgMatch("FEII",chCard) ) { /* turn on the large verner atom */ FeII.lgFeIION = TRUE; /* levels keyword is to adjust number of levels. But this only has effect * BEFORE space is allocated for the FeII arrays */ if( lgMatch("LEVE",chCard) ) { /* do option only if space not yet allocated */ if( !lgFeIIMalloc ) { long int i=5; int lgEOL; /* number of levels for hydrogen at, 2s is this plus one */ nFeIILevel = (long int)FFmtRead(chCard,&i,76,&lgEOL); if( lgEOL ) { /* hit eol with no number - this is a problem */ NoNumb(chCard); } if( nFeIILevel <16 ) { fprintf( ioQQQ, " This would be too few levels, must have at least 16.\n" ); puts( "[Stop in ParseAtom]" ); exit(1); } else if( nFeIILevel > NFE2LEVN ) { fprintf( ioQQQ, " This would be too many levels.\n" ); puts( "[Stop in ParseAtom]" ); exit(1); } } } /* slow keyword means do not try to avoid evaluating atom */ if( lgMatch("SLOW",chCard) ) { FeII.lgSlow = TRUE; } /* print keyword print comment for each call to pop371 */ if( lgMatch("PRIN",chCard) ) { FeII.lgPrint = TRUE; } /* print keyword print comment for each call to pop371 */ if( lgMatch("SIMU",chCard) ) { /* option to only simulate calls to pop371 */ FeII.lgSimulate = TRUE; } } else { fprintf( ioQQQ, " The name of the atom, currently FeII, must appear.\n" ); fprintf( ioQQQ, " Sorry.\n" ); puts( "[Stop in ParseAtom]" ); exit(1); } # ifdef DEBUG_FUN fputs( " <->ParseAtom()\n", debug_fp ); # endif return; }