Search Site | Contact Details | FAQ

ADAS Subroutine xxdata_13

       subroutine xxdata_13( iunit  , dsname ,
     &                       nstore , ntdim  , nddim  ,
     &                       iz0    , iz     , iz1    , esym  ,
     &                       nbsel  , isela  ,
     &                       cwavel , cfile  , ctype  , cindm ,
     &                       ita    , ida    ,
     &                       teta   , teda   ,
     &                       sxb
     &                     )
C-----------------------------------------------------------------------
C
C  ***************** FORTRAN77 SUBROUTINE: xxdata_13 *******************
C
C  PURPOSE:  To fetch data from input ionisations/photon file
C            for a given emitting ion (element and charge).
C
C  CALLING PROGRAM: ADAS503/ssxb
C
C  DATA:    Up to 'nstore' sets (data-blocks) of data may be  read from
C           the file - each block forming a complete set of ionizations
C           per photon values for given temp/density combination. Each
C           data-block  is  analysed independently of any  other  data-
C           block.
C
C           The units used in the data file are taken as follows:
C
C           Temperatures : eV
C           Densities    : cm-3
C
C  SUBROUTINE:
C
C  INPUT : (I*4)  IUNIT    = UNIT TO WHICH INPUT FILE IS ALLOCATED.
C
C          (I*4)  NSTORE   = MAXIMUM NUMBER  OF  INPUT DATA-BLOCKS  THAT
C                            CAN BE STORED.
C          (I*4)  NTDIM    = MAX NUMBER OF ELECTRON TEMPERATURES ALLOWED
C          (I*4)  NDDIM    = MAX NUMBER OF ELECTRON DENSITIES    ALLOWED
C
C  OUTPUT: (I*4)  IZ0      = READ - EMITTING ION - NUCLEAR CHARGE
C          (I*4)  IZ       = READ - EMITTING ION - CHARGE
C          (I*4)  IZ1      = READ - EMITTING ION - CHARGE + 1
C          (C*2)  ESYM     = READ - EMITTING ION - ELEMENT SYMBOL
C
C          (I*4)  NBSEL    = NUMBER OF DATA-BLOCKS ACCEPTED & READ IN.
C          (I*4)  ISELA()  = READ - DATA-SET DATA-BLOCK ENTRY INDICES
C                            DIMENSION: DATA-BLOCK INDEX
C
C          (C*10) CWAVEL() = READ - WAVELENGTH (ANGSTROMS)
C                            DIMENSION: DATA-BLOCK INDEX
C          (C*8)  CFILE()  = READ - SPECIFIC ION FILE SOURCE
C                            DIMENSION: DATA-BLOCK INDEX
C          (C*8)  CTYPE()  = READ - DATA TYPE
C                            DIMENSION: DATA-BLOCK INDEX
C          (C*2)  CINDM()  = READ - METASTABLE INDEX
C                            DIMENSION: DATA-BLOCK INDEX
C
C          (I*4)  ITA()    = READ - NUMBER OF ELECTRON TEMPERATURES
C                            DIMENSION: DATA-BLOCK INDEX
C          (I*4)  IDA()    = READ - NUMBER OF ELECTRON DENSITIES
C                            DIMENSION: DATA-BLOCK INDEX
C
C          (R*8)  TETA(,)  = READ - ELECTRON TEMPERATURES (UNITS: eV)
C                            1st DIMENSION: ELECTRON TEMPERATURE INDEX
C                            2nd DIMENSION: DATA-BLOCK INDEX
C          (R*8)  TEDA(,)  = READ - ELECTRON DENSITIES (UNITS: CM-3)
C                            1st DIMENSION: ELECTRON DENSITY INDEX
C                            2nd DIMENSION: DATA-BLOCK INDEX
C
C          (R*8)  sxb(,,)   =READ - PHOTON EMISSIVITY VALUES
C                            1st DIMENSION: ELECTRON TEMPERATURE INDEX
C                            2nd DIMENSION: ELECTRON DENSITY INDEX
C                            3rd DIMENSION: DATA-BLOCK INDEX
C
C ROUTINE: (I*4)  I4EIZ0   = FUNCTION - (SEE ROUTINES SECTION BELOW)
C          (I*4)  I4FCTN   = FUNCTION - (SEE ROUTINES SECTION BELOW)
C          (I*4)  I4UNIT   = FUNCTION - (SEE ROUTINES SECTION BELOW)
C          (I*4)  IBLK     = ARRAY INDEX: DATA-BLOCK INDEX
C          (I*4)  ITT      = ARRAY INDEX: ELECTRON TEMPERATURE INDEX
C          (I*4)  ITD      = ARRAY INDEX: ELECTRON DENSITY     INDEX
C          (I*4)  NTNUM    = NUMBER OF ELECTRON TEMPERATURES FOR CURRENT
C                            DATA-BLOCK
C          (I*4)  NDNUM    = NUMBER OF ELECTRON DENSITIES    FOR CURRENT
C                            DATA-BLOCK
C          (I*4)  IABT     = RETURN CODE FROM 'I4FCTN'
C          (I*4)  IPOS1    = GENERAL USE STRING INDEX VARIABLE
C          (I*4)  IPOS2    = GENERAL USE STRING INDEX VARIABLE
C
C          (L*4)  LBEND    = IDENTIFIES WHETHER THE LAST OF THE  INPUT
C                            DATA SUB-BLOCKS HAS BEEN LOCATED.
C                            (.TRUE. => END OF SUB-BLOCKS REACHED)
C
C          (C*1)  CSLASH   = '/' - DELIMITER FOR 'XXHKEY'
C          (C*2)  C2       = GENERAL USE TWO BYTE CHARACTER STRING
C          (C*5)  IONNAM   = EMITTING ION READ FROM DATASET
C          (C*6)  CKEY1    = 'FILMEM' - INPUT BLOCK HEADER KEY
C          (C*4)  CKEY2    = 'TYPE  ' - INPUT BLOCK HEADER KEY
C          (C*4)  CKEY3    = 'INDM  ' - INPUT BLOCK HEADER KEY
C          (C*4)  CKEY4    = 'ISEL  ' - INPUT BLOCK HEADER KEY
C          (C*80) C80      = GENERAL USE 80 BYTE  CHARACTER  STRING  FOR
C                            THE INPUT OF DATA-SET RECORDS.
C
C ROUTINES:
C          ROUTINE    SOURCE    BRIEF DESCRIPTION
C          ------------------------------------------------------------
C          XXHKEY     ADAS      OBTAIN KEY/RESPONSE STRINGS FROM TEXT
C          I4EIZ0     ADAS      INTEGER*4 FUNCTION    -
C                               RETURNS Z0 FOR GIVEN ELEMENT SYMBOL
C          I4FCTN     ADAS      INTEGER*4 FUNCTION    -
C                               CONVERT CHARACTER STRING TO INTEGER
C          I4UNIT     ADAS      INTEGER*4 FUNCTION    -
C                               FETCH UNIT NUMBER FOR OUTPUT OF MESSAGES
C
C
C-----------------------------------------------------------------------
C
C
C NOTES: Based on xxdata_15.for.
C
C
C VERSION  : 1.1
C DATE     : 17-02-2006
C MODIFIED : Martin O'Mullane
C              - First version
C
C VERSION  : 1.2
C DATE     : 21-01-2007
C MODIFIED : Allan Whiteford
C              - Changed error messages from xxdata_15 to xxdata_13.
C
C-----------------------------------------------------------------------
      CHARACTER*8         CFILE(NSTORE)
      CHARACTER*2         CINDM(NSTORE)
      CHARACTER*8         CTYPE(NSTORE)
      CHARACTER*10        CWAVEL(NSTORE)
      CHARACTER*80        DSNAME
      CHARACTER*2         ESYM
      INTEGER             IDA(NSTORE), ISELA(NSTORE)
      INTEGER             ITA(NSTORE), IUNIT,       IZ,          IZ0
      INTEGER             IZ1,         NBSEL,       NDDIM,       NSTORE
      INTEGER             NTDIM
      REAL*8              SXB(NTDIM,NDDIM,NSTORE),  TEDA(NDDIM,NSTORE)
      REAL*8              TETA(NTDIM,NSTORE)
© Copyright 1995-2018 The ADAS Project
Comments and questions to: adas-at-adas.ac.uk