TALK=T;RUN(1,1)
DISPLAY
This case provides a simple demonstration of the calculation of
residence time for plane turbulent channel flow over a cavity.
The channel is 0.5m high by 3m long, and the cavity, which is
located centrally beneath the channel, is 2.5m high by 1.5m wide.
Fluid enters with a velocity of 1m/s corresponding to a Reynolds
number of 3.24E4. The turbulence is represented by means of the
standard k-e model.

The procedure for calculating the residence time corresponds
closely to the way residence times are measured in practice:

1) obtain the steady-state solution for the hydrodynamics.
2) perform a restart calculation from these solution fields so
as to make a transient analysis for a single scalar quantity
C1, which enters in a short pulse and is then convected out
of the solution domain.

The spread in time corresponds corresponds in part to the
convective and diffusive mixing processes; but numerical
diffusion is also present. The residence time is determined by
monitoring the exit concentration with time, and noting when
the exit value reaches a maximum. The PHOENICS simulation
predicts the expected residence time of 3s, as may be seen
on inspection of the PROFIL plot at the end of the RESULT
file.

ENDDIS
************************************************************
Group 1. Run Title and Number
************************************************************
************************************************************

TEXT(Residence-Time Demonstration            )

************************************************************
************************************************************

IRUNN = 1 ;LIBREF = 14
************************************************************
Group 2. Time dependence
* Set overall time and no. of steps
TFIRST =0. ;TLAST =5.
FSTEP = 1 ;LSTEP = 100
TFRAC(1)=1.0E-02 ;TFRAC(2)=0.02
TFRAC(3)=0.03 ;TFRAC(4)=0.04
TFRAC(5)=0.05 ;TFRAC(6)=0.06
TFRAC(7)=0.07 ;TFRAC(8)=0.08
TFRAC(9)=0.09 ;TFRAC(10)=0.1
TFRAC(11)=0.11 ;TFRAC(12)=0.12
TFRAC(13)=0.13 ;TFRAC(14)=0.14
TFRAC(15)=0.15 ;TFRAC(16)=0.16
TFRAC(17)=0.17 ;TFRAC(18)=0.18
TFRAC(19)=0.19 ;TFRAC(20)=0.2
TFRAC(21)=0.21 ;TFRAC(22)=0.22
TFRAC(23)=0.23 ;TFRAC(24)=0.24
TFRAC(25)=0.25 ;TFRAC(26)=0.26
TFRAC(27)=0.27 ;TFRAC(28)=0.28
TFRAC(29)=0.29 ;TFRAC(30)=0.3
TFRAC(31)=0.31 ;TFRAC(32)=0.32
TFRAC(33)=0.33 ;TFRAC(34)=0.34
TFRAC(35)=0.35 ;TFRAC(36)=0.36
TFRAC(37)=0.37 ;TFRAC(38)=0.38
TFRAC(39)=0.39 ;TFRAC(40)=0.4
TFRAC(41)=0.41 ;TFRAC(42)=0.42
TFRAC(43)=0.43 ;TFRAC(44)=0.44
TFRAC(45)=0.45 ;TFRAC(46)=0.46
TFRAC(47)=0.47 ;TFRAC(48)=0.48
TFRAC(49)=0.49 ;TFRAC(50)=0.5
TFRAC(51)=0.51 ;TFRAC(52)=0.52
TFRAC(53)=0.53 ;TFRAC(54)=0.54
TFRAC(55)=0.55 ;TFRAC(56)=0.56
TFRAC(57)=0.57 ;TFRAC(58)=0.58
TFRAC(59)=0.59 ;TFRAC(60)=0.6
TFRAC(61)=0.61 ;TFRAC(62)=0.62
TFRAC(63)=0.63 ;TFRAC(64)=0.64
TFRAC(65)=0.65 ;TFRAC(66)=0.66
TFRAC(67)=0.67 ;TFRAC(68)=0.68
TFRAC(69)=0.69 ;TFRAC(70)=0.7
TFRAC(71)=0.71 ;TFRAC(72)=0.72
TFRAC(73)=0.73 ;TFRAC(74)=0.74
TFRAC(75)=0.75 ;TFRAC(76)=0.76
TFRAC(77)=0.77 ;TFRAC(78)=0.78
TFRAC(79)=0.79 ;TFRAC(80)=0.8
TFRAC(81)=0.81 ;TFRAC(82)=0.82
TFRAC(83)=0.83 ;TFRAC(84)=0.84
TFRAC(85)=0.85 ;TFRAC(86)=0.86
TFRAC(87)=0.87 ;TFRAC(88)=0.88
TFRAC(89)=0.89 ;TFRAC(90)=0.9
TFRAC(91)=0.91 ;TFRAC(92)=0.92
TFRAC(93)=0.93 ;TFRAC(94)=0.94
TFRAC(95)=0.95 ;TFRAC(96)=0.96
TFRAC(97)=0.97 ;TFRAC(98)=0.98
TFRAC(99)=0.99 ;TFRAC(100)=1.
************************************************************
Group 3. X-Direction Grid Spacing
CARTES = T
NX = 20
XULAST =3.
XFRAC(1)=0.05 ;XFRAC(2)=0.1
XFRAC(3)=0.15 ;XFRAC(4)=0.2
XFRAC(5)=0.25 ;XFRAC(6)=0.3
XFRAC(7)=0.35 ;XFRAC(8)=0.4
XFRAC(9)=0.45 ;XFRAC(10)=0.5
XFRAC(11)=0.55 ;XFRAC(12)=0.6
XFRAC(13)=0.65 ;XFRAC(14)=0.7
XFRAC(15)=0.75 ;XFRAC(16)=0.8
XFRAC(17)=0.85 ;XFRAC(18)=0.9
XFRAC(19)=0.95 ;XFRAC(20)=1.
************************************************************
Group 4. Y-Direction Grid Spacing
NY = 20
YVLAST =3.
YFRAC(1)=0.052083 ;YFRAC(2)=0.104167
YFRAC(3)=0.15625 ;YFRAC(4)=0.208333
YFRAC(5)=0.260417 ;YFRAC(6)=0.3125
YFRAC(7)=0.364583 ;YFRAC(8)=0.416667
YFRAC(9)=0.46875 ;YFRAC(10)=0.520833
YFRAC(11)=0.572917 ;YFRAC(12)=0.625
YFRAC(13)=0.677083 ;YFRAC(14)=0.729167
YFRAC(15)=0.78125 ;YFRAC(16)=0.833333
YFRAC(17)=0.875 ;YFRAC(18)=0.916667
YFRAC(19)=0.958333 ;YFRAC(20)=1.
************************************************************
Group 5. Z-Direction Grid Spacing
PARAB = F
NZ = 1
ZWLAST =1.
ZFRAC(1)=1.
************************************************************
Group 6. Body-Fitted Coordinates
************************************************************
Group 7. Variables: STOREd,SOLVEd,NAMEd
ONEPHS = T
NAME(1)=P1 ;NAME(3)=U1
NAME(5)=V1 ;NAME(12)=KE
NAME(13)=EP ;NAME(16)=C1
NAME(146)=EPKE ;NAME(147)=EL1
NAME(148)=ENUT ;NAME(149)=DEN1
NAME(150)=PRPS
* Y in SOLUTN argument list denotes:
* 1-stored 2-solved 3-whole-field
* 4-point-by-point 5-explicit 6-harmonic averaging
SOLUTN(P1,Y,Y,Y,N,N,Y)
SOLUTN(U1,Y,N,N,N,N,Y)
SOLUTN(V1,Y,N,N,N,N,Y)
SOLUTN(KE,Y,N,N,N,N,Y)
SOLUTN(EP,Y,N,N,N,N,Y)
SOLUTN(C1,Y,Y,N,N,N,Y)
SOLUTN(EPKE,Y,N,N,N,N,Y)
SOLUTN(EL1,Y,N,N,N,N,Y)
SOLUTN(ENUT,Y,N,N,N,N,Y)
SOLUTN(DEN1,Y,N,N,N,N,Y)
SOLUTN(PRPS,Y,N,N,N,N,Y)
DEN1 = 149
VIST = 148
LEN1 = 147
PRPS = 150
************************************************************
Group 8. Terms & Devices
* Y in TERMS argument list denotes:
* 1-built-in source 2-convection 3-diffusion 4-transient
* 5-first phase variable 6-interphase transport
TERMS(P1,Y,Y,Y,N,Y,Y)
TERMS(C1,N,Y,N,Y,Y,Y)
DIFCUT =0. ;ZDIFAC =1.
GALA = F ;ADDDIF = F
NEWRH1 = T
NEWENL = T
ISOLX = -1 ;ISOLY = -1 ;ISOLZ = -1
************************************************************
Group 9. Properties used if PRPS is not
stored, and where PRPS = -1.0 if it is!
RHO1 = GRND10 ;TMP1 =0.
EL1 =0.
TSURR =0. ;TEMP0 =0.
PRESS0 =0.
DVO1DT =0. ;DRH1DP =0.
RHO1A =0. ;RHO1B =0.
RHO1C =0.
EMISS =0. ;SCATT =0.
ENUL = GRND10 ;ENUT =0.
ENULA =0. ;ENULB =0.
ENULC =0.
CP1 =1005. ;CP2 =1.
************************************************************
Group 10.Inter-Phase Transfer Processes
************************************************************
Group 11.Initial field variables (PHIs)

PATCH(BLOCK1 ,INIVAL, 1, 5, 1, 16, 1, 1, 1, 1)
INIT(BLOCK1 ,PRPS,0. ,198. )

PATCH(BLOCK2 ,INIVAL, 16, 20, 1, 16, 1, 1, 1, 1)
INIT(BLOCK2 ,PRPS,0. ,198. )
FSWEEP = 1
NAMFI =hydr
************************************************************
Group 12. Patchwise adjustment of terms
Patches for this group are printed with those
for Group 13.
Their names begin either with GP12 or &
************************************************************
Group 13. Boundary & Special Sources

PATCH(HOCS ,CELL , 0, 0, 0, 0, 0, 0, 1, 100)
COVAL(HOCS ,C1 , FIXFLU , GRND2 )

PATCH(INLETP ,WEST , 1, 1, 17, 20, 1, 1, 1, 1)
COVAL(INLETP ,P1 , FIXFLU ,1.189 )
COVAL(INLETP ,U1 ,0. ,1. )
COVAL(INLETP ,KE ,0. ,2.5E-03 )
COVAL(INLETP ,EP ,0. ,8.2E-04 )
COVAL(INLETP ,C1 ,0. ,1. )

PATCH(INLET ,WEST , 1, 1, 17, 20, 1, 1, 2, 100)
COVAL(INLET ,P1 , FIXFLU ,1.189 )
COVAL(INLET ,U1 ,0. ,1. )
COVAL(INLET ,KE ,0. ,2.5E-03 )
COVAL(INLET ,EP ,0. ,8.2E-04 )
COVAL(INLET ,C1 ,0. ,0. )

PATCH(OUTLET ,EAST , 20, 20, 17, 20, 1, 1, 1, 100)
COVAL(OUTLET ,P1 ,1. ,0. )
XCYCLE = F
EGWF = T
WALLCO = GRND2
************************************************************
Group 14. Downstream Pressure For PARAB
************************************************************
Group 15. Terminate Sweeps
LSWEEP = 5 ;ISWC1 = 1
LITHYD = 1 ;LITFLX = 1 ;LITC = 1 ;ITHC1 = 1
SELREF = T
RESFAC =1.0E-04
************************************************************
Group 16. Terminate Iterations
LITER(P1)=20 ;LITER(C1)=20
ENDIT(P1)=1.0E-03 ;ENDIT(C1)=1.0E-03
************************************************************
Group 17. Relaxation
RELAX(P1,LINRLX,1.)
RELAX(U1,LINRLX,1.)
RELAX(V1,LINRLX,1.)
RELAX(KE,LINRLX,0.4)
RELAX(EP,LINRLX,0.4)
RELAX(C1,FALSDT,100.)
RELAX(EPKE,LINRLX,1.)
RELAX(EL1,LINRLX,1.)
RELAX(ENUT,LINRLX,1.)
RELAX(DEN1,LINRLX,1.)
RELAX(PRPS,LINRLX,1.)
OVRRLX =0.
EXPERT = F ;NNORSL = F
************************************************************
Group 18. Limits
VARMAX(P1)=1.0E+10 ;VARMIN(P1)=-1.0E+10
VARMAX(U1)=1.0E+06 ;VARMIN(U1)=-1.0E+06
VARMAX(V1)=1.0E+06 ;VARMIN(V1)=-1.0E+06
VARMAX(KE)=1.0E+10 ;VARMIN(KE)=1.0E-10
VARMAX(EP)=1.0E+10 ;VARMIN(EP)=1.0E-10
VARMAX(C1)=1. ;VARMIN(C1)=1.0E-10
VARMAX(EPKE)=1.0E+10 ;VARMIN(EPKE)=-1.0E+10
VARMAX(EL1)=1.0E+10 ;VARMIN(EL1)=-1.0E+10
VARMAX(ENUT)=1.0E+10 ;VARMIN(ENUT)=-1.0E+10
VARMAX(DEN1)=1.0E+10 ;VARMIN(DEN1)=-1.0E+10
VARMAX(PRPS)=1.0E+10 ;VARMIN(PRPS)=-1.0E+10
************************************************************
Group 19. Data transmitted to GROUND
GENK = T
PARSOL = F
ISG62 = 1
SPEDAT(SET,SCHEME,INLCS016,I,8)
SPEDAT(SET,GXMONI,TRANSIENT,L,F)
SPEDAT(SET,MATERIAL,198,L,T)
************************************************************
Group 20. Preliminary Printout
************************************************************
Group 21. Print-out of Variables
INIFLD = F ;SUBWGR = F
* Y in OUTPUT argument list denotes:
* 1-field 2-correction-eq. monitor 3-selective dumping
* 4-whole-field residual 5-spot-value table 6-residual table
OUTPUT(P1,Y,N,Y,Y,Y,Y)
OUTPUT(U1,Y,N,Y,N,N,N)
OUTPUT(V1,Y,N,Y,N,N,N)
OUTPUT(KE,Y,N,Y,N,N,N)
OUTPUT(EP,Y,N,Y,N,N,N)
OUTPUT(C1,Y,N,Y,Y,Y,Y)
OUTPUT(EPKE,Y,N,Y,N,N,N)
OUTPUT(EL1,Y,N,Y,N,N,N)
OUTPUT(ENUT,Y,N,Y,N,N,N)
OUTPUT(DEN1,Y,N,Y,N,N,N)
OUTPUT(PRPS,Y,N,Y,N,N,N)
************************************************************
Group 22. Monitor Print-Out
IXMON = 19 ;IYMON = 18 ;IZMON = 1
NPRMON = 100000 ;NPRMNT = 1 ;TSTSWP = -1
UWATCH = T ;USTEER = T
HIGHLO = F
************************************************************
Group 23.Field Print-Out & Plot Control
NPRINT = 100000 ;NUMCLS = 5
NTPRIN = 100000 ;ISTPRF = 1 ;ISTPRL = 100000
NXPRIN = -1 ;IXPRF = 1 ;IXPRL = 10000
NYPRIN = -1 ;IYPRF = 1 ;IYPRL = 10000
IPLTF = 1 ;IPLTL = -1 ;NPLT = 1
ISWPRF = 1 ;ISWPRL = 100000
ITABL = 3 ;IPROF = 1
ABSIZ =0.5 ;ORSIZ =0.4
NTZPRF = 1 ;NCOLPF = 50
ICHR = 2 ;NCOLCO = 45 ;NROWCO = 20

PATCH(C1EXIT ,PROFIL, 20, 20, 17, 17, 1, 1, 1, 100)
PLOT(C1EXIT ,C1 ,0. ,0. )
************************************************************
Group 24. Dumps For Restarts
SAVE = T ;NOWIPE = F
NSAVE =CHAM
STOP