GROUP 1.  Run identifiers and other preliminaries.
TEXT(Batch Reactor Test Case            :D107
TITLE
  DISPLAY
   This q1 file simulates an batch chemical vapour
   deposition reactor as shown below; the  reactor is
   axisymmetric and contains twelve wafers on the axis.
   It is a test case developed to indicate the use of
   super wafers. This case should be looked at
   in combination with library case D108.
   Laminar, steady-state flow is assumed.
  ENDDIS
 
 
   ^
   |
   |  Y
   |
    ------>  Z
 
                               HOT WALL
   ________________________________________________________________
   **|                                                          |**
   **|                                                          |**
   --  _    _    _    _    _    _    _    _    _    _    _    _  --
   I  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  O
   N  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  U
      |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  |*|  T
   ----------------------------------------------------------------
                             CENTRE LINE
 
   ************************************************************
   *
   *  GROUP 2.  Time-dependence and related parameters.
   *
   *  Steady-state simulation
STEADY=T
   *
   ************************************************************
   *
   *  GROUP 3.  x-direction grid specification.
   *
CARTES=F
   *
   *  Total number of REGIONS in X direction 1
   *  Total number of cells in X direction 1
   *  Total length in X direction 0.01 RAD
   *
NREGX=1;REGEXT(X,1)
IREGX=1;GRDPWR(X,1,0.01,1)
   *
   ************************************************************
   *
   *  GROUP 4.  y-direction grid specification.
   *
   *  Total number of REGIONS in Y direction 3
   *  Total number of cells in Y direction 11
   *  Total length in Y direction   1.0700E-01 m
   *
NREGY=3;REGEXT(Y,1)
IREGY=1;GRDPWR(Y,5,0.05,1)
IREGY=2;GRDPWR(Y,1,0.01,1)
IREGY=3;GRDPWR(Y,4,0.04,1)
   *
   ************************************************************
   *
   *  GROUP 5.  z-direction grid specification.
   *
   *  Total number of REGIONS in Z direction 9
   *  Total number of cells in Z direction 45
   *  Total length in Z direction   2.23E-01 m
   *
NREGZ=27;REGEXT(Z,1)
IREGZ=1;GRDPWR(Z,2,0.02,1)
IREGZ=2;GRDPWR(Z,3,0.03,1)
IREGZ=3;GRDPWR(Z,1,0.01,1)
IREGZ=4;GRDPWR(Z,3,0.03,1)
IREGZ=5;GRDPWR(Z,1,0.01,1)
IREGZ=6;GRDPWR(Z,3,0.03,1)
IREGZ=7;GRDPWR(Z,1,0.01,1)
IREGZ=8;GRDPWR(Z,3,0.03,1)
IREGZ=9;GRDPWR(Z,1,0.01,1)
IREGZ=10;GRDPWR(Z,3,0.03,1)
IREGZ=11;GRDPWR(Z,1,0.01,1)
IREGZ=12;GRDPWR(Z,3,0.03,1)
IREGZ=13;GRDPWR(Z,1,0.01,1)
IREGZ=14;GRDPWR(Z,3,0.03,1)
IREGZ=15;GRDPWR(Z,1,0.01,1)
IREGZ=16;GRDPWR(Z,3,0.03,1)
IREGZ=17;GRDPWR(Z,1,0.01,1)
IREGZ=18;GRDPWR(Z,3,0.03,1)
IREGZ=19;GRDPWR(Z,1,0.01,1)
IREGZ=20;GRDPWR(Z,3,0.03,1)
IREGZ=21;GRDPWR(Z,1,0.01,1)
IREGZ=22;GRDPWR(Z,3,0.03,1)
IREGZ=23;GRDPWR(Z,1,0.01,1)
IREGZ=24;GRDPWR(Z,3,0.03,1)
IREGZ=25;GRDPWR(Z,1,0.01,1)
IREGZ=26;GRDPWR(Z,3,0.03,1)
IREGZ=27;GRDPWR(Z,2,0.02,1)
   *
   ************************************************************
   *
   *  GROUP 6.  Body-fitting and other grid distortions.
   *
   ************************************************************
   *
   *  GROUP 7.  Variables (including porosities) named,
   *            stored & solved.
   *
SOLVE(P1,V1,W1,TEM1)
SOLUTN(P1,Y,Y,Y,N,N,N)
SOLUTN(TEM1,Y,Y,Y,N,N,Y)
 
    ** Specify species
    ** Numbers refer to the integer indices in species database
NAME(C1) = S177
NAME(C2) = S80
NAME(C3) = S97
 
    ** Note that one mass fraction is STOREd and the rest SOLVEd
STORE(S177)
SOLVE(S80)
SOLVE(S97)
 
    ** Use wholefield solver and harmonic averaging
    ** for mass fractions
SOLUTN(S80,Y,Y,Y,N,N,Y)
SOLUTN(S97,Y,Y,Y,N,N,Y)
 
    ** Additional STOREd varaibles
STORE(RHO1)
STORE(VPOR)
STORE(EMIS)
STORE(CNDT)
STORE(SPHT)
 
    ** Deposition rate
STORE(DEPO)
 
STORE(PRPS,BLOK,ENUL)
   *
   ************************************************************
   *
   *  GROUP 8.  Terms (in differential equations) and devices.
   *
   * Activate block-correction
IVARBK=-1;ISOLBK=1
ISOLX=0;ISOLY=0;ISOLZ=0
    ** Activate user sources to include additional source terms
USOURC=T;UDIFNE=T;DIFCUT=0.0
   *
   ************************************************************
   *
   *  GROUP 9.  Properties of the medium (or media).
   *
    ** Diffusivities for species MUST be set to -GRND8
    ** Diffusion law is selected by SPEDAT below
PRNDTL(S177) = -GRND8
PRNDTL(S80)  = -GRND8
PRNDTL(S97)  = -GRND8
 
   *  Reference pressure (N/m^2)
PRESS0=133.0
 
   *  Take values from the property library
; 
; 
 
 
    ** For material definition, values MUST be set to GRND8
    ** Property option is selected by SPEDAT below
CSG10 = 'q1'
  MATFLG=T;IMAT=2
    70      GRND8   GRND8   GRND8   GRND8   1.000
    0.0 0.0 0.0
    0.0 0.0 0.0
    0.0 0.0 0.0
    0.0 0.0 0.0
    154    1.926E4   1.0   134.0   178.0   0.0
   *
   ************************************************************
   *
   *  GROUP 10. Interphase-transfer processes and properties.
   *
   ************************************************************
   *
   *  GROUP 11. Initialization of fields of variables,
   *            porosities, etc.
   *
INIADD=F
FIINIT( P1 ) = 0.0
FIINIT( W1 ) = 0.0
FIINIT( V1 ) = 0.0
FIINIT(TEM1) = 293
FIINIT( S177 ) = 0.94
FIINIT( S80 ) = 0.06
FIINIT( S97 ) = 1.0E-10
 
FIINIT(BLOK) = 1.0
FIINIT(VPOR) = 1.0
FIINIT(PRPS) = 70
FIINIT(EMIS) = 0.0
 
    ** Participating blockages are used
    ** A PRPS value of 154 refers to tungsten which is a built-in
    ** material
   * Blockages
CONPOR(BLK1,0,CELL,-#1,-#1,-#3,-#3,-#1,-#1)
 
CONPOR(BLK2,0,CELL,-#1,-#1,-#3,-#3,-#27,-#27)
 
CONPOR(BLK3,-1,CELL,-#1,-#1,-#1,-#1,-#3,-#3)
COVAL(BLK3,PRPS,0.0,154)
COVAL(BLK3,BLOK,0.0,2)
 
CONPOR(BLK4,-1,CELL,-#1,-#1,-#1,-#1,-#5,-#5)
COVAL(BLK4,PRPS,0.0,154)
COVAL(BLK4,BLOK,0.0,3)
 
CONPOR(BLK5,-1,CELL,-#1,-#1,-#1,-#1,-#7,-#7)
COVAL(BLK5,PRPS,0.0,154)
COVAL(BLK5,BLOK,0.0,4)
 
CONPOR(BLK6,-1,CELL,-#1,-#1,-#1,-#1,-#9,-#9)
COVAL(BLK6,PRPS,0.0,154)
COVAL(BLK6,BLOK,0.0,5)
 
CONPOR(BLK7,-1,CELL,-#1,-#1,-#1,-#1,-#11,-#11)
COVAL(BLK7,PRPS,0.0,154)
COVAL(BLK7,BLOK,0.0,6)
 
CONPOR(BLK8,-1,CELL,-#1,-#1,-#1,-#1,-#13,-#13)
COVAL(BLK8,PRPS,0.0,154)
COVAL(BLK8,BLOK,0.0,7)
 
CONPOR(BLK9,-1,CELL,-#1,-#1,-#1,-#1,-#15,-#15)
COVAL(BLK9,PRPS,0.0,154)
COVAL(BLK9,BLOK,0.0,8)
 
CONPOR(BK10,-1,CELL,-#1,-#1,-#1,-#1,-#17,-#17)
COVAL(BK10,PRPS,0.0,154)
COVAL(BK10,BLOK,0.0,9)
 
CONPOR(BK11,-1,CELL,-#1,-#1,-#1,-#1,-#19,-#19)
COVAL(BK11,PRPS,0.0,154)
COVAL(BK11,BLOK,0.0,10)
 
CONPOR(BK12,-1,CELL,-#1,-#1,-#1,-#1,-#21,-#21)
COVAL(BK12,PRPS,0.0,154)
COVAL(BK12,BLOK,0.0,11)
 
CONPOR(BK13,-1,CELL,-#1,-#1,-#1,-#1,-#23,-#23)
COVAL(BK13,PRPS,0.0,154)
COVAL(BK13,BLOK,0.0,12)
 
CONPOR(BK15,-1,CELL,-#1,-#1,-#1,-#1,-#25,-#25)
COVAL(BK15,PRPS,0.0,154)
COVAL(BK15,BLOK,0.0,13)
   *
   ************************************************************
   *
   *  GROUP 12. Convection and diffusion adjustments
   *
   ************************************************************
   *
   *  GROUP 13. Boundary conditions and special sources
   *
REAL(RHOIN,UAV)
RHOIN = 1.7E-3
UAV   = 1.345*3.
 
   * INLET boundary condition
INLET(INLET,LOW,#1,#1,#1,#2,#1,#1,#1,#NREGT)
VALUE(INLET,W1,UAV)
VALUE(INLET,TEM1,290)
VALUE(INLET,P1,UAV*RHOIN)
VALUE(INLET,S177,0.94)
VALUE(INLET,S80,0.06)
VALUE(INLET,S97,0.000)
 
   * OUTLET boundary condition
OUTLET(OUT,HIGH,#1,#1,#1,#2,#27,#27,#1,#NREGT)
VALUE(OUT,V1,SAME)
VALUE(OUT,W1,SAME)
VALUE(OUT,P1,0)
VALUE(OUT,TEM1,SAME)
VALUE(OUT,S177,SAME)
VALUE(OUT,S80,SAME)
VALUE(OUT,S97,SAME)
 
   * Outer wall assumed to be at 733K
PATCH(WALL,NWALL,#1,#1,#3,#3,#2,#26,#1,#NREGT)
COVAL(WALL,TEM1,1.0,733)
COVAL(WALL,W1,1.0,0.0)
 
   * Gas phase chemistry source term
PATCH(CHEM,VOLUME,1,NX,1,NY,1,NZ,1,LSTEP)
COVAL(CHEM,TEM1,GRND1,GRND1)
COVAL(CHEM,S80,GRND1,GRND1)
COVAL(CHEM,S97,GRND1,GRND1)
 
    ** For surface chemistry, COVALs must be specified for ALL
    ** species, P1 and TEM1. Additionally, CO for P1 set to 1.0
    ** to indicate simple single wafer. CO of > 1.0 is used to
    ** represent multiple (batch) wafers.
   * Surface chemistry source term
   * Wafer 1
PATCH(SURF1,HIGH,#1,#1,#1,#1,#2,#2,#1,#NREGT)
COVAL(SURF1,S80,FIXFLU,GRND1)
COVAL(SURF1,S97,FIXFLU,GRND1)
COVAL(SURF1,P1,1.000,GRND1)
COVAL(SURF1,TEM1,FIXFLU,GRND1)
PATCH(SURF2,LOW,#1,#1,#1,#1,#4,#4,#1,#NREGT)
COVAL(SURF2,S80,FIXFLU,GRND1)
COVAL(SURF2,S97,FIXFLU,GRND1)
COVAL(SURF2,P1,1.000,GRND1)
COVAL(SURF2,TEM1,FIXFLU,GRND1)
PATCH(SURF3,SOUTH,#1,#1,#2,#2,#3,#3,#1,#NREGT)
COVAL(SURF3,S80,FIXFLU,GRND1)
COVAL(SURF3,S97,FIXFLU,GRND1)
COVAL(SURF3,P1,1.000,GRND1)
COVAL(SURF3,TEM1,FIXFLU,GRND1)
 
   * Wafer 2
PATCH(SURF4,HIGH,#1,#1,#1,#1,#4,#4,#1,#NREGT)
COVAL(SURF4,S80,FIXFLU,GRND1)
COVAL(SURF4,S97,FIXFLU,GRND1)
COVAL(SURF4,P1,1.000,GRND1)
COVAL(SURF4,TEM1,FIXFLU,GRND1)
PATCH(SURF5,LOW,#1,#1,#1,#1,#6,#6,#1,#NREGT)
COVAL(SURF5,S80,FIXFLU,GRND1)
COVAL(SURF5,S97,FIXFLU,GRND1)
COVAL(SURF5,P1,1.000,GRND1)
COVAL(SURF5,TEM1,FIXFLU,GRND1)
PATCH(SURF6,SOUTH,#1,#1,#2,#2,#5,#5,#1,#NREGT)
COVAL(SURF6,S80,FIXFLU,GRND1)
COVAL(SURF6,S97,FIXFLU,GRND1)
COVAL(SURF6,P1,1.000,GRND1)
COVAL(SURF6,TEM1,FIXFLU,GRND1)
 
   * Wafer 3
PATCH(SURF7,HIGH,#1,#1,#1,#1,#6,#6,#1,#NREGT)
COVAL(SURF7,S80,FIXFLU,GRND1)
COVAL(SURF7,S97,FIXFLU,GRND1)
COVAL(SURF7,P1,1.000,GRND1)
COVAL(SURF7,TEM1,FIXFLU,GRND1)
PATCH(SURF8,LOW,#1,#1,#1,#1,#8,#8,#1,#NREGT)
COVAL(SURF8,S80,FIXFLU,GRND1)
COVAL(SURF8,S97,FIXFLU,GRND1)
COVAL(SURF8,P1,1.000,GRND1)
COVAL(SURF8,TEM1,FIXFLU,GRND1)
PATCH(SURF9,SOUTH,#1,#1,#2,#2,#7,#7,#1,#NREGT)
COVAL(SURF9,S80,FIXFLU,GRND1)
COVAL(SURF9,S97,FIXFLU,GRND1)
COVAL(SURF9,P1,1.000,GRND1)
COVAL(SURF9,TEM1,FIXFLU,GRND1)
 
   * Wafer 4
PATCH(SURF10,HIGH,#1,#1,#1,#1,#8,#8,#1,#NREGT)
COVAL(SURF10,S80,FIXFLU,GRND1)
COVAL(SURF10,S97,FIXFLU,GRND1)
COVAL(SURF10,P1,1.000,GRND1)
COVAL(SURF10,TEM1,FIXFLU,GRND1)
PATCH(SURF11,LOW,#1,#1,#1,#1,#10,#10,#1,#NREGT)
COVAL(SURF11,S80,FIXFLU,GRND1)
COVAL(SURF11,S97,FIXFLU,GRND1)
COVAL(SURF11,P1,1.000,GRND1)
COVAL(SURF11,TEM1,FIXFLU,GRND1)
PATCH(SURF12,SOUTH,#1,#1,#2,#2,#9,#9,#1,#NREGT)
COVAL(SURF12,S80,FIXFLU,GRND1)
COVAL(SURF12,S97,FIXFLU,GRND1)
COVAL(SURF12,P1,1.000,GRND1)
COVAL(SURF12,TEM1,FIXFLU,GRND1)
 
   * Wafer 5
PATCH(SURF13,HIGH,#1,#1,#1,#1,#10,#10,#1,#NREGT)
COVAL(SURF13,S80,FIXFLU,GRND1)
COVAL(SURF13,S97,FIXFLU,GRND1)
COVAL(SURF13,P1,1.000,GRND1)
COVAL(SURF13,TEM1,FIXFLU,GRND1)
PATCH(SURF14,LOW,#1,#1,#1,#1,#12,#12,#1,#NREGT)
COVAL(SURF14,S80,FIXFLU,GRND1)
COVAL(SURF14,S97,FIXFLU,GRND1)
COVAL(SURF14,P1,1.000,GRND1)
COVAL(SURF14,TEM1,FIXFLU,GRND1)
PATCH(SURF15,SOUTH,#1,#1,#2,#2,#11,#11,#1,#NREGT)
COVAL(SURF15,S80,FIXFLU,GRND1)
COVAL(SURF15,S97,FIXFLU,GRND1)
COVAL(SURF15,P1,1.000,GRND1)
COVAL(SURF15,TEM1,FIXFLU,GRND1)
 
   * Wafer 6
PATCH(SURF16,HIGH,#1,#1,#1,#1,#12,#12,#1,#NREGT)
COVAL(SURF16,S80,FIXFLU,GRND1)
COVAL(SURF16,S97,FIXFLU,GRND1)
COVAL(SURF16,P1,1.000,GRND1)
COVAL(SURF16,TEM1,FIXFLU,GRND1)
PATCH(SURF17,LOW,#1,#1,#1,#1,#14,#14,#1,#NREGT)
COVAL(SURF17,S80,FIXFLU,GRND1)
COVAL(SURF17,S97,FIXFLU,GRND1)
COVAL(SURF17,P1,1.000,GRND1)
COVAL(SURF17,TEM1,FIXFLU,GRND1)
PATCH(SURF18,SOUTH,#1,#1,#2,#2,#13,#13,#1,#NREGT)
COVAL(SURF18,S80,FIXFLU,GRND1)
COVAL(SURF18,S97,FIXFLU,GRND1)
COVAL(SURF18,P1,1.000,GRND1)
COVAL(SURF18,TEM1,FIXFLU,GRND1)
 
   * Wafer 7
PATCH(SURF19,HIGH,#1,#1,#1,#1,#14,#14,#1,#NREGT)
COVAL(SURF19,S80,FIXFLU,GRND1)
COVAL(SURF19,S97,FIXFLU,GRND1)
COVAL(SURF19,P1,1.000,GRND1)
COVAL(SURF19,TEM1,FIXFLU,GRND1)
PATCH(SURF20,LOW,#1,#1,#1,#1,#16,#16,#1,#NREGT)
COVAL(SURF20,S80,FIXFLU,GRND1)
COVAL(SURF20,S97,FIXFLU,GRND1)
COVAL(SURF20,P1,1.000,GRND1)
COVAL(SURF20,TEM1,FIXFLU,GRND1)
PATCH(SURF21,SOUTH,#1,#1,#2,#2,#15,#15,#1,#NREGT)
COVAL(SURF21,S80,FIXFLU,GRND1)
COVAL(SURF21,S97,FIXFLU,GRND1)
COVAL(SURF21,P1,1.000,GRND1)
COVAL(SURF21,TEM1,FIXFLU,GRND1)
 
   * Wafer 8
PATCH(SURF22,HIGH,#1,#1,#1,#1,#16,#16,#1,#NREGT)
COVAL(SURF22,S80,FIXFLU,GRND1)
COVAL(SURF22,S97,FIXFLU,GRND1)
COVAL(SURF22,P1,1.000,GRND1)
COVAL(SURF22,TEM1,FIXFLU,GRND1)
PATCH(SURF23,LOW,#1,#1,#1,#1,#18,#18,#1,#NREGT)
COVAL(SURF23,S80,FIXFLU,GRND1)
COVAL(SURF23,S97,FIXFLU,GRND1)
COVAL(SURF23,P1,1.000,GRND1)
COVAL(SURF23,TEM1,FIXFLU,GRND1)
PATCH(SURF24,SOUTH,#1,#1,#2,#2,#17,#17,#1,#NREGT)
COVAL(SURF24,S80,FIXFLU,GRND1)
COVAL(SURF24,S97,FIXFLU,GRND1)
COVAL(SURF24,P1,1.000,GRND1)
COVAL(SURF24,TEM1,FIXFLU,GRND1)
 
   * Wafer 9
PATCH(SURF25,HIGH,#1,#1,#1,#1,#18,#18,#1,#NREGT)
COVAL(SURF25,S80,FIXFLU,GRND1)
COVAL(SURF25,S97,FIXFLU,GRND1)
COVAL(SURF25,P1,1.000,GRND1)
COVAL(SURF25,TEM1,FIXFLU,GRND1)
PATCH(SURF26,LOW,#1,#1,#1,#1,#20,#20,#1,#NREGT)
COVAL(SURF26,S80,FIXFLU,GRND1)
COVAL(SURF26,S97,FIXFLU,GRND1)
COVAL(SURF26,P1,1.000,GRND1)
COVAL(SURF26,TEM1,FIXFLU,GRND1)
PATCH(SURF27,SOUTH,#1,#1,#2,#2,#19,#19,#1,#NREGT)
COVAL(SURF27,S80,FIXFLU,GRND1)
COVAL(SURF27,S97,FIXFLU,GRND1)
COVAL(SURF27,P1,1.000,GRND1)
COVAL(SURF27,TEM1,FIXFLU,GRND1)
 
   * Wafer 10
PATCH(SURF28,HIGH,#1,#1,#1,#1,#20,#20,#1,#NREGT)
COVAL(SURF28,S80,FIXFLU,GRND1)
COVAL(SURF28,S97,FIXFLU,GRND1)
COVAL(SURF28,P1,1.000,GRND1)
COVAL(SURF28,TEM1,FIXFLU,GRND1)
PATCH(SURF29,LOW,#1,#1,#1,#1,#22,#22,#1,#NREGT)
COVAL(SURF29,S80,FIXFLU,GRND1)
COVAL(SURF29,S97,FIXFLU,GRND1)
COVAL(SURF29,P1,1.000,GRND1)
COVAL(SURF29,TEM1,FIXFLU,GRND1)
PATCH(SURF30,SOUTH,#1,#1,#2,#2,#21,#21,#1,#NREGT)
COVAL(SURF30,S80,FIXFLU,GRND1)
COVAL(SURF30,S97,FIXFLU,GRND1)
COVAL(SURF30,P1,1.000,GRND1)
COVAL(SURF30,TEM1,FIXFLU,GRND1)
 
   * Wafer 11
PATCH(SURF31,HIGH,#1,#1,#1,#1,#22,#22,#1,#NREGT)
COVAL(SURF31,S80,FIXFLU,GRND1)
COVAL(SURF31,S97,FIXFLU,GRND1)
COVAL(SURF31,P1,1.000,GRND1)
COVAL(SURF31,TEM1,FIXFLU,GRND1)
PATCH(SURF32,LOW,#1,#1,#1,#1,#24,#24,#1,#NREGT)
COVAL(SURF32,S80,FIXFLU,GRND1)
COVAL(SURF32,S97,FIXFLU,GRND1)
COVAL(SURF32,P1,1.000,GRND1)
COVAL(SURF32,TEM1,FIXFLU,GRND1)
PATCH(SURF33,SOUTH,#1,#1,#2,#2,#23,#23,#1,#NREGT)
COVAL(SURF33,S80,FIXFLU,GRND1)
COVAL(SURF33,S97,FIXFLU,GRND1)
COVAL(SURF33,P1,1.000,GRND1)
COVAL(SURF33,TEM1,FIXFLU,GRND1)
 
   * Wafer 12
PATCH(SURF34,HIGH,#1,#1,#1,#1,#24,#24,#1,#NREGT)
COVAL(SURF34,S80,FIXFLU,GRND1)
COVAL(SURF34,S97,FIXFLU,GRND1)
COVAL(SURF34,P1,1.000,GRND1)
COVAL(SURF34,TEM1,FIXFLU,GRND1)
PATCH(SURF35,LOW,#1,#1,#1,#1,#26,#26,#1,#NREGT)
COVAL(SURF35,S80,FIXFLU,GRND1)
COVAL(SURF35,S97,FIXFLU,GRND1)
COVAL(SURF35,P1,1.000,GRND1)
COVAL(SURF35,TEM1,FIXFLU,GRND1)
PATCH(SURF36,SOUTH,#1,#1,#2,#2,#25,#25,#1,#NREGT)
COVAL(SURF36,S80,FIXFLU,GRND1)
COVAL(SURF36,S97,FIXFLU,GRND1)
COVAL(SURF36,P1,1.000,GRND1)
COVAL(SURF36,TEM1,FIXFLU,GRND1)
 
   * Automatic underrelaxation for chemistry
PATCH(RELT,PHASEM,1,NX,1,NY,1,NZ,1,LSTEP)
COVAL(RELT,S80,GRND1,SAME)
COVAL(RELT,S97,GRND1,SAME)
 
   * Radiation zones
    ** S2SR=T activates surface-to-surface radiation
S2SR=T
IF(S2SR) THEN
PATCH(@RI001,LOW,#1,#1,#1,#2,#1,#1,#1,#NREGT)
COVAL(@RI001,TEM1,0.0,290)
COVAL(@RI001,EMIS,198,0.0)
 
PATCH(@RI002,NORTH,#1,#1,#2,#2,#1,#1,#1,#NREGT)
COVAL(@RI002,TEM1,0.0,290)
COVAL(@RI002,EMIS,111,0.0)
 
PATCH(@RI003,LOW,#1,#1,#3,#3,#2,#2,#1,#NREGT)
COVAL(@RI003,TEM1,0.0,400)
COVAL(@RI003,EMIS,111,0.0)
 
PATCH(@RI004,NORTH,#1,#1,#3,#3,#2,#26,#1,#NREGT)
COVAL(@RI004,TEM1,0.0,733)
COVAL(@RI004,EMIS,111,0.0)
 
PATCH(@RI005,HIGH,#1,#1,#3,#3,#26,#26,#1,#NREGT)
COVAL(@RI005,TEM1,0.0,400)
COVAL(@RI005,EMIS,111,0.0)
 
PATCH(@RI006,NORTH,#1,#1,#2,#2,#27,#27,#1,#NREGT)
COVAL(@RI006,TEM1,0.0,290)
COVAL(@RI006,EMIS,111,0.0)
 
PATCH(@RI007,HIGH,#1,#1,#1,#2,#27,#27,#1,#NREGT)
COVAL(@RI007,TEM1,0.0,290)
COVAL(@RI007,EMIS,198,0.0)
 
PATCH(@RI008,LOW,#1,#1,#1,#1,#3,#3,#1,#NREGT)
COVAL(@RI008,TEM1,GRND1,GRND1)
COVAL(@RI008,EMIS,154,0.0)
 
PATCH(@RI009,HIGH,#1,#1,#1,#1,#3,#3,#1,#NREGT)
COVAL(@RI009,TEM1,GRND1,GRND1)
COVAL(@RI009,EMIS,154,0.0)
 
PATCH(@RI010,NORTH,#1,#1,#1,#1,#3,#3,#1,#NREGT)
COVAL(@RI010,TEM1,GRND1,GRND1)
COVAL(@RI010,EMIS,154,0.0)
 
PATCH(@RI011,LOW,#1,#1,#1,#1,#5,#5,#1,#NREGT)
COVAL(@RI011,TEM1,GRND1,GRND1)
COVAL(@RI011,EMIS,154,0.0)
 
PATCH(@RI012,HIGH,#1,#1,#1,#1,#5,#5,#1,#NREGT)
COVAL(@RI012,TEM1,GRND1,GRND1)
COVAL(@RI012,EMIS,154,0.0)
 
PATCH(@RI013,NORTH,#1,#1,#1,#1,#5,#5,#1,#NREGT)
COVAL(@RI013,TEM1,GRND1,GRND1)
COVAL(@RI013,EMIS,154,0.0)
 
PATCH(@RI014,LOW,#1,#1,#1,#1,#7,#7,#1,#NREGT)
COVAL(@RI014,TEM1,GRND1,GRND1)
COVAL(@RI014,EMIS,154,0.0)
 
PATCH(@RI015,HIGH,#1,#1,#1,#1,#7,#7,#1,#NREGT)
COVAL(@RI015,TEM1,GRND1,GRND1)
COVAL(@RI015,EMIS,154,0.0)
 
PATCH(@RI016,NORTH,#1,#1,#1,#1,#7,#7,#1,#NREGT)
COVAL(@RI016,TEM1,GRND1,GRND1)
COVAL(@RI016,EMIS,154,0.0)
 
PATCH(@RI017,LOW,#1,#1,#1,#1,#9,#9,#1,#NREGT)
COVAL(@RI017,TEM1,GRND1,GRND1)
COVAL(@RI017,EMIS,154,0.0)
 
PATCH(@RI018,HIGH,#1,#1,#1,#1,#9,#9,#1,#NREGT)
COVAL(@RI018,TEM1,GRND1,GRND1)
COVAL(@RI018,EMIS,154,0.0)
 
PATCH(@RI019,NORTH,#1,#1,#1,#1,#9,#9,#1,#NREGT)
COVAL(@RI019,TEM1,GRND1,GRND1)
COVAL(@RI019,EMIS,154,0.0)
 
PATCH(@RI020,LOW,#1,#1,#1,#1,#11,#11,#1,#NREGT)
COVAL(@RI020,TEM1,GRND1,GRND1)
COVAL(@RI020,EMIS,154,0.0)
 
PATCH(@RI021,HIGH,#1,#1,#1,#1,#11,#11,#1,#NREGT)
COVAL(@RI021,TEM1,GRND1,GRND1)
COVAL(@RI021,EMIS,154,0.0)
 
PATCH(@RI022,NORTH,#1,#1,#1,#1,#11,#11,#1,#NREGT)
COVAL(@RI022,TEM1,GRND1,GRND1)
COVAL(@RI022,EMIS,154,0.0)
 
PATCH(@RI023,LOW,#1,#1,#1,#1,#13,#13,#1,#NREGT)
COVAL(@RI023,TEM1,GRND1,GRND1)
COVAL(@RI023,EMIS,154,0.0)
 
PATCH(@RI024,HIGH,#1,#1,#1,#1,#13,#13,#1,#NREGT)
COVAL(@RI024,TEM1,GRND1,GRND1)
COVAL(@RI024,EMIS,154,0.0)
 
PATCH(@RI025,NORTH,#1,#1,#1,#1,#13,#13,#1,#NREGT)
COVAL(@RI025,TEM1,GRND1,GRND1)
COVAL(@RI025,EMIS,154,0.0)
 
PATCH(@RI026,LOW,#1,#1,#1,#1,#15,#15,#1,#NREGT)
COVAL(@RI026,TEM1,GRND1,GRND1)
COVAL(@RI026,EMIS,154,0.0)
 
PATCH(@RI027,HIGH,#1,#1,#1,#1,#15,#15,#1,#NREGT)
COVAL(@RI027,TEM1,GRND1,GRND1)
COVAL(@RI027,EMIS,154,0.0)
 
PATCH(@RI028,NORTH,#1,#1,#1,#1,#15,#15,#1,#NREGT)
COVAL(@RI028,TEM1,GRND1,GRND1)
COVAL(@RI028,EMIS,154,0.0)
 
PATCH(@RI029,LOW,#1,#1,#1,#1,#17,#17,#1,#NREGT)
COVAL(@RI029,TEM1,GRND1,GRND1)
COVAL(@RI029,EMIS,154,0.0)
 
PATCH(@RI030,HIGH,#1,#1,#1,#1,#17,#17,#1,#NREGT)
COVAL(@RI030,TEM1,GRND1,GRND1)
COVAL(@RI030,EMIS,154,0.0)
 
PATCH(@RI031,NORTH,#1,#1,#1,#1,#17,#17,#1,#NREGT)
COVAL(@RI031,TEM1,GRND1,GRND1)
COVAL(@RI031,EMIS,154,0.0)
 
PATCH(@RI032,LOW,#1,#1,#1,#1,#19,#19,#1,#NREGT)
COVAL(@RI032,TEM1,GRND1,GRND1)
COVAL(@RI032,EMIS,154,0.0)
 
PATCH(@RI033,HIGH,#1,#1,#1,#1,#19,#19,#1,#NREGT)
COVAL(@RI033,TEM1,GRND1,GRND1)
COVAL(@RI033,EMIS,154,0.0)
 
PATCH(@RI034,NORTH,#1,#1,#1,#1,#19,#19,#1,#NREGT)
COVAL(@RI034,TEM1,GRND1,GRND1)
COVAL(@RI034,EMIS,154,0.0)
 
PATCH(@RI035,LOW,#1,#1,#1,#1,#21,#21,#1,#NREGT)
COVAL(@RI035,TEM1,GRND1,GRND1)
COVAL(@RI035,EMIS,154,0.0)
 
PATCH(@RI036,HIGH,#1,#1,#1,#1,#21,#21,#1,#NREGT)
COVAL(@RI036,TEM1,GRND1,GRND1)
COVAL(@RI036,EMIS,154,0.0)
 
PATCH(@RI037,NORTH,#1,#1,#1,#1,#21,#21,#1,#NREGT)
COVAL(@RI037,TEM1,GRND1,GRND1)
COVAL(@RI037,EMIS,154,0.0)
 
PATCH(@RI038,LOW,#1,#1,#1,#1,#23,#23,#1,#NREGT)
COVAL(@RI038,TEM1,GRND1,GRND1)
COVAL(@RI038,EMIS,154,0.0)
 
PATCH(@RI039,HIGH,#1,#1,#1,#1,#23,#23,#1,#NREGT)
COVAL(@RI039,TEM1,GRND1,GRND1)
COVAL(@RI039,EMIS,154,0.0)
 
PATCH(@RI040,NORTH,#1,#1,#1,#1,#23,#23,#1,#NREGT)
COVAL(@RI040,TEM1,GRND1,GRND1)
COVAL(@RI040,EMIS,154,0.0)
 
PATCH(@RI041,LOW,#1,#1,#1,#1,#25,#25,#1,#NREGT)
COVAL(@RI041,TEM1,GRND1,GRND1)
COVAL(@RI041,EMIS,154,0.0)
 
PATCH(@RI042,HIGH,#1,#1,#1,#1,#25,#25,#1,#NREGT)
COVAL(@RI042,TEM1,GRND1,GRND1)
COVAL(@RI042,EMIS,154,0.0)
 
PATCH(@RI043,NORTH,#1,#1,#1,#1,#25,#25,#1,#NREGT)
COVAL(@RI043,TEM1,GRND1,GRND1)
COVAL(@RI043,EMIS,154,0.0)
ENDIF
 
   ** Additional TEM1 relaxation in solids for use
   ** when GRND2 used as CO in radiation patches
   PATCH(RELSOL1,PHASEM,#1,#1,#1,#3,#6,#6,1,LSTEP)
   COVAL(RELSOL1,TEM1,5.E2,SAME)
   PATCH(RELSOL3,PHASEM,#1,#1,#2,#2,#4,#4,1,LSTEP)
   COVAL(RELSOL3,TEM1,5.E2,SAME)
 
   ************************************************************
   *
   *  GROUP 14. Downstream pressure (for free parabolic flow).
   *
   ************************************************************
   *
   *  GROUP 15. Termination criteria for sweeps and
   *            outer iterations.
   *
   *  Number of sweeps
LSWEEP=200
   *
   ************************************************************
   *
   *  GROUP 16. Termination criteria for inner iterations.
   *
SELREF=T; RESFAC=1.0000E-03
   *
   ************************************************************
   *
   *  GROUP 17. Under-relaxation and related devices.
   *
RELAX(TEM1,LINRLX,0.3)
RELAX(P1,LINRLX,0.8)
RELAX(V1,FALSDT,2.0E-04)
RELAX(W1,FALSDT,2.0E-04)
 
    ** Extra underrelaxation for concentrations, independent
    ** of chemistry
REAL(TREL)
TREL=1.0
RELAX(S80,FALSDT,TREL)
RELAX(S97,FALSDT,TREL)
   *
   ************************************************************
   *
   *  GROUP 18. Limits on variables values or increments
   *            to them.
   *
    ** Minimum value for species set to 1.0E-20
VARMIN( S177 ) = 1.0E-20;   VARMAX( S177 ) = 1.0
VARMIN( S80 )  = 1.0E-20;   VARMAX( S80 )  = 1.0
VARMIN( S97 )  = 1.0E-20;   VARMAX( S97 )  = 1.0
VARMIN(TEM1)  = 260.0;     VARMAX(TEM1)  = 1000.0
    ** Protection to prevent negative absolute pressures during
    ** convergence
VARMIN(P1)   = -0.8 * PRESS0
   *
   ************************************************************
   *
   *  GROUP 19. Data communicated by SATELLITE to GROUND
   *
    ** SPEDAT used for passing options and additional information
    ** to GROUND.
    ** MCDOPT = 2     Wilke Multi-component Diffusion Law
    ** BINOPT = 4     Bin. diff. coeff. based on actual temperature
    ** MCPROP = 3     Multi-component properties based on local gas
    **                mixture and local gas temperature
    ** CHMRLX = 0.5   Relaxation factor for RELT patch
    ** NGREAC/NSEARC  Number of gas/surface reactions
    ** GREAC/SREAC    Integer index of gas/surface species in
    **                chemistry database
SPEDAT(SET,CVD,MCDOPT,I,2)
SPEDAT(SET,CVD,BINOPT,I,4)
SPEDAT(SET,CVD,MCPROP,I,3)
SPEDAT(SET,CVD,CHMRLX,R,0.5)
SPEDAT(SET,CVD,NGREAC,I,0)
SPEDAT(SET,CVD,NSREAC,I,1)
SPEDAT(SET,CVD,SREAC(1),I,17)
SPEDAT(SET,CVD,RADCVD,L,T)
NAMGRD=CVD
   *
   ************************************************************
   *
   *  GROUP 20. Control of preliminary printout
   *
   ************************************************************
   *
   *  GROUP 21. Frequency and extent of field printout.
   *
   ************************************************************
   *
   *  GROUP 22. Location of spot-value & frequency of
   *            residual printout.
   *
IYMON=7
IZMON=13
TSTSWP=-1
   *
   ************************************************************
   *
   *  GROUP 23. Variable-by-variable field printout and plot
   *            and/or tabulation of spot-values and residuals.
   *
   ************************************************************
   *
   *  GROUP 24. Preparation for continuation runs.
   *
   ************************************************************
   RESTRT(ALL)
   RSTPRP=T