ADAS Subroutine d7data
SUBROUTINE D7DATA( IUNIT , NDLEV , NDTRN , & TITLED , IZ , IZ0 , IZ1 , BWNO , & IL , & IA , CSTRGA , ISA , ILA , XJA , WA & ) C----------------------------------------------------------------------- C C ****************** FORTRAN77 SUBROUTINE: D7DATA ********************* C C PURPOSE: TO FETCH LEVEL DATA FROM INPUT COPASE DATA SET. C C CALLING PROGRAM: ADAS407 C C DATA: C THE UNITS USED IN THE DATA FILE ARE TAKEN AS FOLLOWS: C C IONISATION POTENTIAL: WAVE NUMBER (CM-1) C INDEX LEVEL ENERGIES: WAVE NUMBER (CM-1) C C C SUBROUTINE: C C INPUT : (I*4) IUNIT = UNIT TO WHICH INPUT FILE IS ALLOCATED C INPUT : (I*4) NDLEV = MAXIMUM NUMBER OF LEVELS THAT CAN BE READ C INPUT : (I*4) NDTRN = MAX. NUMBER OF TRANSITIONS THAT CAN BE READ C C OUTPUT: (C*3) TITLED = ELEMENT SYMBOL. C OUTPUT: (I*4) IZ = RECOMBINED ION CHARGE READ C OUTPUT: (I*4) IZ0 = NUCLEAR CHARGE READ C OUTPUT: (I*4) IZ1 = RECOMBINING ION CHARGE READ C (NOTE: IZ1 SHOULD EQUAL IZ+1) C OUTPUT: (R*8) BWNO = IONISATION POTENTIAL (CM-1) C C OUTPUT: (I*4) IL = INPUT DATA FILE: NUMBER OF ENERGY LEVELS C C OUTPUT: (I*4) IA() = ENERGY LEVEL INDEX NUMBER C OUTPUT: (C*18) CSTRGA()= NOMENCLATURE/CONFIGURATION FOR LEVEL 'IA()' C OUTPUT: (I*4) ISA() = MULTIPLICITY FOR LEVEL 'IA()' C NOTE: (ISA-1)/2 = QUANTUM NUMBER (S) C OUTPUT: (I*4) ILA() = QUANTUM NUMBER (L) FOR LEVEL 'IA()' C OUTPUT: (R*8) XJA() = QUANTUM NUMBER (J-VALUE) FOR LEVEL 'IA()' C NOTE: (2*XJA)+1 = STATISTICAL WEIGHT C OUTPUT: (R*8) WA() = ENERGY RELATIVE TO LEVEL 1 (CM-1) FOR LEVEL C 'IA()' C C C (I*4) I4UNIT = FUNCTION (SEE ROUTINE SECTION BELOW) C (I*4) I = GENERAL USE. C (I*4) IABT = RETURN CODE FROM 'R8FCTN' (0 => NO ERROR) C OR FROM INTERROGATION OF 'C7' C (I*4) IFIRST = BYTE POSITION OF START OF NUMBER IN BUFFER C (I*4) ILAST = BYTE POSITION OF END OF NUMBER IN BUFFER C (I*4) IWORD = THE WORD POSITION OF THE REQUIRED DATA IN C A STRING TO BE INTERROGATED BY XXWORD. C (I*4) J = GENERAL USE. C (I*4) LENCST = BYTE LENGTH OF STRING CSTRGA() C (I*4) NWORDS = NUMBER OF NUMBERS STORED IN BUFFER C (I*4) ILINE = ENERGY LEVEL INDEX FOR CURRENT LINE C (I*4) IRECL = RECORD LENGTH OF INPUT DATASET (<=128) C C (C*7) C7 = USED TO PARSE VALUE FOR XJA() C (C*7) CDELIM = DELIMITERS FOR INPUT OF DATA FROM HEADERS C (C*18) C18 = USED TO PARSE VALUE TO CSTRGA() C (C*80) CLINE = CURRENT ENERGY LEVEL INDEX PARAMETER LINE C (C*128)BUFFER = GENERAL STRING BUFFER STORAGE C C (L*4) LDATA = IDENTIFIES WHETHER THE END OF AN INPUT C SECTION IN THE DATA SET HAS BEEN LOCATED. C (.TRUE. => END OF SECTION REACHED) C C ROUTINES: C ROUTINE SOURCE BRIEF DESCRIPTION C ------------------------------------------------------------- C XXWORD ADAS EXTRACT POSITION OF NUMBER IN BUFFER C I4UNIT ADAS FETCH UNIT NUMBER FOR OUTPUT OF MESSAGES C R8FCTN ADAS CONVERTS FROM CHARACTER TO REAL VARIABLE C C C ROUTINES: NONE C C AUTHOR: H. P. SUMMERS, JET C K1/1/47 C JET EXT. 4941 C C DATE: 19/05/94 C C UPDATE: 12/07/94 - H. P. SUMMERS - ALLOWED DUMMY BARE NUCLEUS FILE C TO BE READ BY DETECTING IZ0=IZ C C UNIX-IDL PORT: C WILLIAM OSBORN, TESSELLA SUPPORT SERVICES PLC. C C DATE: 25TH MARCH 1996 C C VERSION: 1.1 DATE: 25-03-96 C MODIFIED: WILLIAM OSBORN C - FIRST VERSION. C C VERSION: 1.2 DATE: 09-09-96 C MODIFIED: WILLIAM OSBORN / PAUL BRIDEN C - INSTEAD OF USING FORMAT SPECIFIER F15.0 WHEN C INTERNALLY READING A FLOATING POINT NUMBER, C CREATE THE APPROPRIATE SPECIFIER WITHIN CFORM7 C AND USE THIS. C C----------------------------------------------------------------------- C----------------------------------------------------------------------- CHARACTER*(*) CSTRGA(NDLEV) CHARACTER*3 TITLED INTEGER IA(NDLEV), IL, ILA(NDLEV) INTEGER ISA(NDLEV), IUNIT, IZ, IZ0 INTEGER IZ1, NDLEV, NDTRN REAL*8 BWNO, WA(NDLEV), XJA(NDLEV)