Search Site | Contact Details | FAQ

ADAS Subroutine spfman8hx

      SUBROUTINE SPFMAN8HX(Z0,Z1,Z,N0,V0,PHFRAC,TITLE,
     &     IIOTYP,IIFTYP,IIFOUT,IXMAX,ITMAX,EDAT,XDAT,TDAT,
     &     INGRUP,IIATYP,IGRP,EDGRP,SCGRP,
     &     NIGRP1,LIGRP1,WIGRP1,NJGRP1,LJGRP1,WJGRP1,EGRP1,AGRP1,CRGRP1,
     &     NIGRP2,LIGRP2,WIGRP2,NJGRP2,LJGRP2,WJGRP2,EGRP2,AGRP2,CRGRP2,
     &     IGF,IBU,IFSEL,IBT,IGH,ASCL,NCGRP1,NCGRP2,
     &     XPA,YPA,ICT,XP,YP,ICOUT,
     &     TEA4,EXCRA,
     &     NGROUP, IGROUP, NIA   , LIA    , NJA   , LJA    , NCUTA ,
     &     EMEAN , EDISPO, SCALEO, EDISP  , SCALE , WIA   ,
     &     WJA   , EIJA  , FIJA  , CORFIA , CORFA ,
     &     XA    , YA    , XSAOLD, YSAOLD , YSAOLP,
     &     XSANEW, APGA  , APGAP , YSANEW , YSANWP, APGOAP,
     &     SCEXP , XOA   , YOA   , APGOA  , ITYPEA, EMEAN4, SCEXP4,
     &     EIJA4 , FIJA4 , CORFA4, EDISP4 , SCALE4)

      IMPLICIT REAL*8(A-H,O-Z)
C-----------------------------------------------------------------------
C                                                                       
C  ************  FORTRAN 77 PROGRAM:  SPFMAN8H *************************
C                                                                       
C  PURPOSE: GRAPH AND INTERPOLATE DIELECTRONIC RECOMBINATION
C    COEFFICIENTS.
C
C  INPUT DATA IS REQUIRED ON THE ION SPECIFICATION AND A SPECIFED SET
C    SET OF RECOMBINATION COEFFICIENTS V TEMPERATURE. SUPPLEMENTARY
C    DATA ON CORE ENERGIES AND OSCILLATOR STRENGTHS IS ALSO
C    REQUIRED.  THIS IS DIVIDED INTO TWO GROUPS, IE. DELTAN=0 AND 1.
C  AN ATTEMPT IS MADE TO REDUCE THE INPUT RECOMBINATION DATA
C    TO STANDARD ZERO DENSITY RECOMBINATION COEFFICIENTS.
C  THE COEFFICIENTS ARE THEN RATIOED TO THE BURGESS GENERAL FORMULA
C    VALUES BASED ON THE SUPPLEMENTARY INPUT DATA. THE SUBSEQUENT
C    STRATEGY DEPENDS ON WHETHER THERE THERE ARE ONE OR TWO GROUPS
C    PRESENT.
C        CASE 1. A REGRESSION LINE IS FITTED IN THE LOG(ALF/ALFGF)
C                EMEAN/TE PLANE TO OBTAIN AN ENERGY AND SCALE
C                FACTOR CORRECTIONS TO THE GENERAL FORMULA. WITH ONLY
C                ONE DATA VALUE A SCALE FACTOR IS INFERRED AND THE
C                THE ENERGY CORRECTION ASSUMED ZERO.
C        CASE 2. A SPLINE IS FITTED IN THE LOG(ALF/ALFGF) V EMEAN/TE
C                PLANE WITH ZERO CURVATURE END CONDITIONS.  AN ATTEMPT
C                IS MADE TO INTERPRET THE END SLOPES AND INTERCEPTS IN
C                TERMS OF SCALE FACTORS AND ENERGY CORRECTIONS FOR EACH
C                GROUP AS A WHOLE.
C  THE ALF/ALFGF V EMEAN/TE PLOTS ARE REFORMED OPTIONALLY USING THE
C    BURGESS GENERAL FORMULA WITH OR WITHOUT THE SCALE AND ENERGY
C    CORRECTIONS. THIS IS INTERPOLATED TO REQUIRED OUTPUT TEMPERATURES.
C  THE BURGESS GENERAL PROGRAM IS FITTED TO THE ADJUSTED BURGESS GENERAL
C    FORMULA BY A SINGLE FACTOR WHICH RAMPS THE LOW PARTIAL WAVE
C    CORRECTIONS UP OR DOWN.  NB. AN ADJUSTMENT IS ALSO MADE FOR THE
C    SPECIFIC ION FOR THE PHASE SPACE ACCESSIBLE FOR CAPTURE TO THE
C    THE LOWEST LEVEL FOR THE DELTAN=1 GROUP.  THIS IS THEN USED
C    IN BUNDLED N POPULATION CODES TO GIVE PROPER DENSITY CORRECTIONS.
C
C  DATA:
C         THIS PROGRAM IS NOT YET PROPERLY ANNOTATED
C
C  INPUT:
C     (R*8)  Z0    NUCLEAR CHARGE
C     (R*8)  Z1    RECOMBINING ION CHARGE
C     (R*8)  Z     RECOMBINED ION CHARGE
C     (I*4)  N0     = LOWEST ACCESSIBLE PRINCIPLE QUANTUM NO.
C     (R*8)  V0     = LOWEST ACCESSIBLE EFF. PRINCIPLE QUANTUM NO.
C     (R*8)  PHFRAC = LOWEST ACCESSIBLE PHASE OCCUPATION FACTOR
C     (C*40) TITLE  = TITLE FOR RUN
C     (I*4)  IIOTYP = INPUT RATE FORM, 1=DIELECTRONIC
C                                      2=DIEL. + RADIATIVE
C     (I*4)  IIFTYP = INPUT TEMP. FORM, 1= KELVIN
C                                       2= EV
C                                       3= SCALED (K/Z1**2)
C     (I*4)  IIFOUT = INPUT TEMP. FORM, 1= KELVIN
C                                       2= EV
C                                       3= SCALED (K/Z1**2)
C     (I*4)  IXMAX  = NUMBER OF TEMP./RATE PAIRS
C     (I*4)  ITMAX  = NUMBER OF OUTPUT TEMPS
C     (R*8)  EDAT() = USER OR ARCHIVE ENTERED INPUT TEMPERATURE
C     (R*8)  XDAT() = USER OR ARCHIVE ENTERED RATE
C     (R*8)  TDAT() = USER OR ARCHIVE ENTERED OUTPUT TEMPERATURE
C     (I*4)  INGRUP = NO OF CORE TRANSITION GROUPS
C     (I*4)  IIATYP = TRANSITION PROB. FORM, 1= A-COEFFICIENT
C                                            2= OSCILLATOR STRENGTH
C                                            3= LINE STRENGTH
C     (I*4)  IGRP() = NO OF ENTRIES FOR EACH GROUP
C     (R*4)  EDGRP()= INITIAL MEAN ENERGY DISP. FOR EACH GROUP
C     (R*4)  SCGRP()= MEAN SCALE FACTOR FOR EACH GROUP
C     (I*4)  NIGRP1()= TRANSITION GROUP 1 INFO
C     (I*4)  LIGRP1()= "
C     (R*8)  WIGRP1()= "
C     (I*4)  NJGRP1()= "
C     (I*4)  LJGRP1()= "
C     (R*8)  WJGRP1()= "
C     (R*8)  EGRP1()=  "
C     (R*8)  AGRP1()=  "
C     (R*8)  CRGRP1()= "
C     (I*4)  NCGRP1()= "
C     (I*4)  NIGRP2()= TRANSITION GROUP 2 INFO
C     (I*4)  LIGRP2()= "
C     (R*8)  WIGRP2()= "
C     (I*4)  NJGRP2()= "
C     (I*4)  LJGRP2()= "
C     (R*8)  WJGRP2()= "
C     (R*8)  EGRP2()=  "
C     (R*8)  AGRP2()=  "
C     (R*8)  CRGRP2()= "
C     (I*4)  NCGRP2()= "
C     (I*4)  IGF    = OPTIMISE BURGESS FORMULA FIT? 1=YES 0=NO
C     (I*4)  IBU    = OPTIMISE BURGESS PROGRAM FIT? 1=YES 0=NO
C     (I*4)  IFSEL  = 0=FIT TO FORMULA, 1=FIT TO INPUT DATA
C     (I*4)  IBT    = BAD POINT OPTION 1=ON 0=OFF
C     (I*4)  IGH    = GRAPHICAL DISPLAY? 1=YES 0=NO
C     (R*8)  ASCL   = GRAPH SCALING PARAMETER
C
C  OUTPUT:
C     (R*4)  XPA(,) = X VALUES FOR RATIO PLOT
C     (R*4)  YPA(,) = Y VALUES FOR RATIO PLOT (RATIOS OF DIEL. RECOM. COEFFS.)
C     (I*4)  ICT    = NUMBER OF POINTS ON RATIO PLOT
C     (R*4)  XP()   = X VALUES FOR RATIO PLOT SPLINE FIT
C     (R*4)  YP()   = X VALUES FOR RATIO PLOT SPLINE FIT
C     (I*4)  ICOUT  = NUMBER OF POINTS ON COEFFICIENT PLOT
C     (R*4)  TEA4() = X VALUES FOR COEFFICIENT PLOT (TEMP.) 
C     (R*4)  EXCRA(,) = Y VALUES FOR COEFFICIENT PLOT (COEFFS.)
C     (R*4)  EMEAN4 = MEAN EIJ USED IN GRAPH ANNOTATION
C     (R*4)  SCEXP4 = SCALE FACTOR USED IN GRAPH ANNOTATION
C     (R*4)  EIJA4  = VALUE OF EIJ USED IN GRAPH ANNOTATION
C     (R*4)  FIJA4  = VALUE OF FIJ USED IN GRAPH ANNOTATION
C     (R*4)  CORFA4 = VALUE OF CORFA USED IN GRAPH ANNOTATION
C     (R*4)  EDISP4 = VALUE OF DISPLACEMENT USED IN GRAPH ANNOTATION
C     (R*4)  SCALE4 = VALUE OF SCALE USED IN GRAPH ANNOTATION
C     (I*4)  NGROUP = NUMBER OF CORE TRANSITION GROUPS
C     (I*4)  IGROUP()=NUMBER OF ENTRIES FOR EACH GROUP
C     (I*4)  NIA(,) = NI VALUES FOR BOTH GROUPS
C     (I*4)  LIA(,) = LI VALUES FOR BOTH GROUPS
C     (I*4)  NJA(,) = NJ VALUES FOR BOTH GROUPS
C     (I*4)  LJA(,) = LJ VALUES FOR BOTH GROUPS
C     (I*4)  NCUTA(,)= NCUT VALUES FOR BOTH GROUPS
C     (R*8)  EMEAN()= MEAN ENERGY VALUES FOR EACH GROUP
C     (R*8)  EDISPO()=INITIAL ENERGY DISPLACEMENT FOR EACH GROUP
C     (R*8)  SCALEO()=INITIAL SCALE FACTOR FOR EACH GROUP
C     (R*8)  EDISP()= FINAL ENERGY DISPLACEMENT FOR EACH GROUP
C     (R*8)  SCALE()= FINAL SCALE FACTOR FOR EACH GROUP
C     (R*8)  WIA(,) = WI VALUES FOR BOTH GROUPS
C     (R*8)  EIJA(,)= EIJ VALUES FOR BOTH GROUPS
C     (R*8)  FIJA(,)= FIJ VALUES FOR BOTH GROUPS
C     (R*8)  CORFIA(,)=INITIAL CORFAC VALUES FOR BOTH GROUPS
C     (R*8)  CORFA(,)= FINAL CORFAC VALUES FOR BOTH GROUPS
C     (R*8)  XA()   = INPUT TEMPERATURES
C     (R*8)  YA()   = INPUT ALF
C     (R*8)  XSAOLD()=INITIAL X VALUES
C     (R*8)  YSAOLD()=INITIAL ALF/ALFG VALUES
C     (R*8)  YSAOLP()=INITIAL ALF/ALFP VALUES
C     (R*8)  APGA() = INITIAL ALFG
C     (R*8)  APGAP()= INITIAL ALFP
C     (R*8)  YSANEW()=FINAL ALF/ALFG VALUES
C     (R*8)  YSANEWP()=FINAL ALF/ALFP VALUES
C     (R*8)  APGOA()= FINAL ALFG
C     (R*8)  APGOAP()=FINAL ALFP
C     (R*8)  SCEXP  = PARAMETER DETERMINING X-SCALE EXPANSION
C     (R*8)  XOA()  = USER OR ARCHIVE ENTERED OUTPUT TEMPS
C     (R*8)  YOA()  = INTERPOLATED ALF VALUES CALCULATED AT XOA TEMPS.
C     (R*8)  ITYPEA(,)= TYPE OF TRANSITION (USED TO CALCULATE CORRECTION
C                                           FACTORS)
C
C  AUTHOR:
C
C  *******   H.P.SUMMERS, JET           10 JUNE 1987  ***********
C  S.P.F PANEL STRUCTURE VERSION.
C  *******   J. SPENCE, JET             30 JUNE 1987  ***********
C  S.P.F. PANEL ALTERATION TO INPUT DEFAULT CORFAC
C  *******   H.P.SUMMERS, JET           17 MAY 1988   ***********
C
C-----------------------------------------------------------------------
C
C UNIX-IDL CONVERSION:
C
C VERSION: 1.1                          DATE: 01-11-96
C MODIFIED: WILLIAM OSBORN
C               - FIRST CONVERTED.
C               - MADE INTO A SUBROUTINE. COMMENTED-OUT PANEL INPUT
C                 AND GRAPHICAL ROUTINES.
C
C  VERSION 1.2                                           DATE:  08/11/96
C  MODIFIED: WILLIAM OSBORN
C               - REMOVED UNUSED VARIABLES
C
C  VERSION: 1.3                                          DATE:  15/05/07
C  MODIFIED:  Allan Whiteford
C               - Updated comments as part of subroutine
C                 documentation production.
C
C-----------------------------------------------------------------------
C-----------------------------------------------------------------------
      CHARACTER*40        TITLE
      INTEGER             IBT,         IBU,         ICOUT,       ICT
      INTEGER             IFSEL,       IGF,         IGH
      INTEGER             IGROUP(2),   IGRP(2),     IIATYP,      IIFOUT
      INTEGER             IIFTYP,      IIOTYP,      INGRUP,      ITMAX
      INTEGER             ITYPEA(2,6), IXMAX,       LIA(2,6)
      INTEGER             LIGRP1(6),   LIGRP2(6),   LJA(2,6)
      INTEGER             LJGRP1(6),   LJGRP2(6),   N0
      INTEGER             NCGRP1(6),   NCGRP2(6),   NCUTA(2,6),  NGROUP
      INTEGER             NIA(2,6),    NIGRP1(6),   NIGRP2(6)
      INTEGER             NJA(2,6),    NJGRP1(6),   NJGRP2(6)
      REAL*8              AGRP1(6),    AGRP2(6),    APGA(10)
      REAL*8              APGAP(10),   APGOA(10),   APGOAP(10),  ASCL
      REAL*8              CORFA(2,6)
      REAL                CORFA4(2,6)
      REAL*8              CORFIA(2,6), CRGRP1(6),   CRGRP2(6)
      REAL*8              EDAT(10),    EDGRP(2),    EDISP(2)
      REAL                EDISP4(2)
      REAL*8              EDISPO(2),   EGRP1(6),    EGRP2(6)
      REAL*8              EIJA(2,6)
      REAL                EIJA4(2,6)
      REAL*8              EMEAN(2)
      REAL                EMEAN4,      EXCRA(10,15)
      REAL*8              FIJA(2,6)
      REAL                FIJA4(2,6)
      REAL*8              PHFRAC,      SCALE(2)
      REAL                SCALE4(2)
      REAL*8              SCALEO(2),   SCEXP
      REAL                SCEXP4
      REAL*8              SCGRP(2),    TDAT(10)
      REAL                TEA4(10)
      REAL*8              V0,          WIA(2,6),    WIGRP1(6)
      REAL*8              WIGRP2(6),   WJA(2,6),    WJGRP1(6)
      REAL*8              WJGRP2(6),   XA(10),      XDAT(10),    XOA(10)
      REAL                XP(10),      XPA(4,10)
      REAL*8              XSANEW(10),  XSAOLD(10),  YA(10),      YOA(10)
      REAL                YP(10),      YPA(4,10)
      REAL*8              YSANEW(10),  YSANWP(10),  YSAOLD(10)
      REAL*8              YSAOLP(10),  Z,           Z0,          Z1
© Copyright 1995-2024 The ADAS Project
Comments and questions to: adas-at-adas.ac.uk