Search Site | Contact Details | FAQ

ADAS Subroutine dxspl3

      SUBROUTINE DXSPL3( ISWIT  , LSWIT , IZ1   ,
     &                   NDOUT  , NTOUT ,
     &                            NTIN  ,
     &                   MAXD   , ITE   ,
     &                   MAXT   , TIN   , TOUT  , EIAVAL ,
     &                   TINTRP ,
     &                   ATTY
     &                 )
C-----------------------------------------------------------------------
C
C  ****************** FORTRAN77 SUBROUTINE: DXSPL3 *********************
C
C  PURPOSE: PERFORMS THE THIRD PART OF A THREE WAY SPLINE ON INPUT DATA.
C           GENERATES  A  TABLE  OF  LOG10( COEFFTS./POWERS )  COVERING
C           'MAXT' TEMPERATURES AND 'MAXD' DENSITIES FOR THE ELEMENT
C           RECOMBINING ION CHARGE GIVEN BY 'IZ1'.
C
C  CALLING PROGRAM: D1SPLN/D4DATA
C  DATA:
C
C           THE  SOURCE  DATA ORIGINATES AS MEMBERS  OF  PARTITIONED
C           DATA SETS AS FOLLOWS:
C
C             1. JETUID.ACD<YR>.DATA
C             2. JETUID.SCD<YR>.DATA
C             3. JETUID.CCD<YR>.DATA
C             4. JETUID.PRB<YR>.DATA
C             5. JETUID.PRC<YR>.DATA
C             6. JETUID.PRB<YR>.DATA
C             7. JETUID.PRC<YR>.DATA
C             8. JETUID.PLT<YR>.DATA
C             9. JETUID.PLS<YR>.DATA
C            10. JETUID.MET<YR>.DATA
C
C           WHERE <YR> DENOTES TWO INTEGERS FOR THE YEAR SELECTED.
C
C           THE PARTICULAR TYPE OPENED (1-10) IS SELECTED BY 'ISWIT'
C           IT IS PASSED IN A MODIFIED FORM AFTER PROCESSING BY
C           DXSPL1 AND DXSPL2.
C
C
C  SUBROUTINE:
C
C  INPUT : (I*4)  ISWIT   = DATA TYPE SELECTOR (1 -> 8)
C  INPUT : (L*4)  LSWIT   = .TRUE.  => IONISATION POTENTIALS PRESENT
C                           .FALSE. => IONS. POTENTIALS NOT PRESENT
C  INPUT : (I*4)  IZ1     = OUTPUT - ELEMENT RECOMBINING ION CHARGE
C
C  INPUT : (I*4)  NDOUT   = OUTPUT - MAXIMUM NUMBER OF DENSITIES
C  INPUT : (I*4)  NTOUT   = OUTPUT - MAXIMUM NUMBER OF TEMPERATURES
C
C  INPUT : (I*4)  NTIN    = INPUT  - MAXIMUM NUMBER OF TEMPERATURES
C
C  INPUT : (I*4)  MAXD    = INPUT  - NUMBER OF REDUCED DENSITIES
C  INPUT : (I*4)  ITE     = INPUT  - NUMBER OF REDUCED TEMPERATURES
C
C  INPUT : (I*4)  MAXT    = OUTPUT - NUMBER OF REDUCED TEMPERATURES
C                                                           ( <= NTOUT )
C  INPUT : (R*8)  TIN()   = INPUT  - SET OF 'ITE' REDUCED ELECTRON TEMPS
C  INPUT : (R*8)  TOUT()  = OUTPUT - SET OF 'MAXT' ELECTRON TEMPERATURES
C                                    (UNITS: KELVIN).
C  INPUT : (R*8)  EIAVAL  = IONISATION POTENTIAL (RYDBERGS) FOR
C                           THE ION CHARGE GIVEN BY 'IZ1'.
C
C  OUTPUT: (L*4)  TINTRP() = .TRUE.  => 'ATTY(,)' VALUE FOR TEMPERATURE
C                                       INDEX INTERPOLATED.
C                          = .FALSE. => 'ATTY(,)' VALUE FOR TEMPERATURE
C                                       INDEX EXTRAPOLATED.
C                            1ST DIMENSION: TEMPERATURE INDEX
C
C  IN/OUT: (R*8)  ATTY(,) = WORKING SPACE FOR 3-WAY SPLINE ITERPOLATION
C                           (STORES LOG10 (INTERPOLATED VALUES))
C                           INPUT 'ATTY' VALUES ARE ASSIGNED TO 'YIN' &
C                           THEN 'YOUT' VALUES ARE ASSIGNED TO 'ATTY'.
C                           1ST DIMENSION: TEMPERATURE
C                           2ND DIMENSION: DENSITY
C
C          (I*4)  NTDIM1  = PARAMETER = MUST BE EQUAL TO OR GREATER THAN
C                           THE MAXIMUM NUMBER OF INPUT TEMPERATURES.
C          (I*4)  NTDIM2  = PARAMETER = MUST BE EQUAL TO OR GREATER THAN
C                           THE MAXIMUM NUMBER OF OUTPUT TEMPERATURES.
C
C          (R*8)  EIACON  = PARAMETER = -68570.7
C
C          (I*4)  IT      = ARRAY SUBSCRIPT USED FOR TEMPERATURE VALUES
C          (I*4)  ID      = ARRAY SUBSCRIPT USED FOR DENSITY VALUES
C          (I*4)  IOPT    = DEFINES THE BOUNDARY DERIVATIVES FOR THE
C                           SPLINE ROUTINE 'XXSPLE', SEE 'XXSPLE'.
C                           (VALID VALUES = 0, 1, 2, 3)
C
C          (L*4)  LSETX   = .TRUE.  => SET UP SPLINE PARAMETERS RELATING
C                                      TO 'XIN' AXIS.
C                           .FALSE. => DO NOT SET UP SPLINE PARAMETERS
C                                      RELATING TO 'XIN' AXIS.
C                                      (I.E. THEY WERE SET IN A PREVIOUS
C                                            CALL )
C                           (VALUE SET TO .FALSE. BY 'XXSPLE')
C
C          (R*8)  Z1R2    = 1.0 / (IZ1**2)
C          (R*8)  SCON1   = SCALING CONSTANT
C          (R*8)  SCON2   = SCALING CONSTANT
C          (R*8)  XOUT()  ='TOUT()' CONVERTED TO REDUCED TEMPERATURE
C          (R*8)  YIN()   ='ATTY(,)' AT FIXED DENSITY -
C                                               DIMENSION => TEMPERATURE
C          (R*8)  DF()    = SPLINE INTERPOLATED DERIVATIVES
C          (R*8)  YOUT()  = SPLINE INTERPOLATED 'ATTY(,,)' VALUES  FOR
C                           REDUCED TEMPERATURE  EQUAL TO 'XOUT()' AT A
C                           FIXED DENSITY.
C
C NOTE:
C                         SPLINE IS CARRIED OUT ON:
C                   'ATTY(,,)' VALUES AT FIXED DENSITY
C                                  VERSUS
C                          LOG10( REDUCED DENSITY )
C
C ROUTINES:
C          ROUTINE    SOURCE    BRIEF DESCRIPTION
C          ------------------------------------------------------------
C          XXSPLE     ADAS      SPLINE SUBROUTINE (WITH EXTRAP. INFO)
C          I4UNIT     ADAS      UNIT NUMBER FOR WARNING MESSAGES
C
C AUTHOR:  PAUL E. BRIDEN (TESSELLA SUPPORT SERVICES PLC)
C          K1/0/37
C          JET EXT. 2520
C
C DATE  :  13/06/91 - PE BRIDEN: ADAS91 VERSION OF 'D4SPL3'
C
C UNIX-IDL PORT:
C
C VERSION: 1.1                          DATE: 06-09-95
C MODIFIED: TIM HAMMOND (TESSELLA SUPPORT SERVICES PLC)
C               - FIRST RELEASE
C VERSION: 1.2                          DATE: 25-10-97
C MODIFIED: LORNE HORTON (JET)
C               - ADDED FURTHER CHECKS ON LOW T EXTRAPOLATIONS
C
C-----------------------------------------------------------------------
C-----------------------------------------------------------------------
      INTEGER             ISWIT,       ITE,         IZ1,         MAXD
      INTEGER             MAXT,        NDOUT,       NTIN,        NTOUT
      LOGICAL             LSWIT,       TINTRP(NTOUT)
      REAL*8              ATTY(NTOUT,NDOUT),        EIAVAL
      REAL*8              TIN(NTIN),   TOUT(NTOUT)
© Copyright 1995-2024 The ADAS Project
Comments and questions to: adas-at-adas.ac.uk