```
TALK=T;RUN(1,1)
DISPLAY
provided by l001.htm
Stirred reactor with a 1D population distribution, and
reactedness, ranging from zero to 1, as the population-
distinguishing attribute.
___________
It is supposed that two streams of fluid         |           |
enter a reactor which is sufficiently       A ====>          |
well-stirred for space-wise differences          |  stirred  |
of conditions to be negligible, but not          |  \\\|/// C===>
sufficiently for micro-mixing to be              |  reactor  |
complete.                                   B ====>          |
|___________|
The two streams have the same elemental
composition; but one may be more reacted than the other.

The flow is steady, and the total mass flow rate per unit volume
is 1 kg/s m**3 .
The chemical reaction rate is supposed to depend upon reactedness
in accordance with the formula:

rate (in kg/s m**3)  = const * (1 - R) / R ** ratexp

where R =      reactedness,
ratexp = a prescribed constant
const  = conrea / integral [{(1 - R) / R ** ratexp} dR]
conrea = a second prescribed constant.

The micro-mixing rate (as defined in MFM theory) is taken as
conmix kg/s m**3 times the product of the mass fractions of
interacting fluids, in accordance with the "promiscuous Mendelian"
hypothesis, where conmix is again a prescribed constant.

(1) the fluid-population distribution in the reactor, and
(2) the population-average reactedness
(3) the root-mean-square of the reactedness fluctuations
These values depend upon 7 dimensionless parameters, namely:-

(a) the prescribed constants: RATEXP, CONREA & CONMIX;
(b) the relative proportions of the two mass flow rates,
namely FLOWA and FLOWB (= 1 - FLOWA);
(c) the reactednesses of the two streams, RA and RB;

and on the number of fluids in terms of which the population
distribution is to be described, NFLR.

In the following Q1, the values employed are as follows:

RATEXP  CONREA  CONMIX  FLOWA  RA     RB     NFLR
5.0     10.0    10.0    0.5    0.0    1.0    25

The opportunity is provided to change NFLR interactively in
the satellite, and CONREA and CONMIX during the EARTH run.

Cases 1-1 and 102 allow choice of FLOWA and RATEXP.
ENDDIS
DISPLAY
Notes:

(1) four macros are provided in order reduce the repetiveness of
MFM q1s.

(2) they are named mfm, mfm1, mfm2 and mfm3, and are normally
called in that order at the top of the q1 file, which then
appears  as:

#mfm
settings of nflr, nflf, etc
#mfm1
settings of
#mfm2
#mfm3

(3) the character variable mfm is declared and set in the
always-loaded core-library macro 014.htm, which, in its turn,
declares and sets the character variables mfm1, mfm2, mfm3.

(4) the values are:
mfm  = \$L004
mfm1 = \$L003
mfm2 = \$L002
mfm3 = \$L001
ENDDIS
************************************************************
Group 1. Run Title and Number
************************************************************
************************************************************

TEXT(WSR, 1D Population; RATEXP=5.           )

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

IRUNN = 1 ;LIBREF = 100
************************************************************
Group 2. Time dependence
************************************************************
Group 3. X-Direction Grid Spacing
CARTES = T
NX = 1
XULAST =1.
XFRAC(1)=1.
************************************************************
Group 4. Y-Direction Grid Spacing
NY = 1
YVLAST =1.
YFRAC(1)=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(123)=F1
NAME(124)=F2 ;NAME(125)=F3
NAME(126)=F4 ;NAME(127)=F5
NAME(128)=F6 ;NAME(129)=F7
NAME(130)=F8 ;NAME(131)=F9
NAME(132)=F10 ;NAME(133)=F11
NAME(134)=F12 ;NAME(135)=F13
NAME(136)=F14 ;NAME(137)=F15
NAME(138)=F16 ;NAME(139)=F17
NAME(140)=F18 ;NAME(141)=F19
NAME(142)=F20 ;NAME(143)=F21
NAME(144)=F22 ;NAME(145)=F23
NAME(146)=F24 ;NAME(147)=F25
NAME(148)=MNSQ ;NAME(149)=AVER
NAME(150)=RATE
* 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,N,N,N,Y)
SOLUTN(F1,Y,Y,N,N,N,Y)
SOLUTN(F2,Y,Y,N,N,N,Y)
SOLUTN(F3,Y,Y,N,N,N,Y)
SOLUTN(F4,Y,Y,N,N,N,Y)
SOLUTN(F5,Y,Y,N,N,N,Y)
SOLUTN(F6,Y,Y,N,N,N,Y)
SOLUTN(F7,Y,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MS(F15,N,Y,Y,Y,N,Y)
TERMS(F16,N,Y,Y,Y,Y,Y)
TERMS(F17,N,Y,Y,Y,N,Y)
TERMS(F18,N,Y,Y,Y,Y,Y)
TERMS(F19,N,Y,Y,Y,N,Y)
TERMS(F20,N,Y,Y,Y,Y,Y)
TERMS(F21,N,Y,Y,Y,N,Y)
TERMS(F22,N,Y,Y,Y,Y,Y)
TERMS(F23,N,Y,Y,Y,N,Y)
TERMS(F24,N,Y,Y,Y,Y,Y)
TERMS(F25,N,Y,Y,Y,N,Y)
DIFCUT =0.5 ;ZDIFAC =1.
GALA = F ;ADDDIF = F
ISOLX = -1 ;ISOLY = -1 ;ISOLZ = -1
************************************************************
Group 9. Properties used if PRPS is not
stored, and where PRPS = -1.0 if it is!
RHO1 =1. ;TMP1 =0.
EL1 =0.
TSURR =0. ;TEMP0 =0.
PRESS0 =0.
DVO1DT =0. ;DRH1DP =0.
EMISS =0. ;SCATT =0.
ENUL =1.0E-05 ;ENUT =0.
PRNDTL(F1)=1. ;PRNDTL(F2)=1.
PRNDTL(F3)=1. ;PRNDTL(F4)=1.
PRNDTL(F5)=1. ;PRNDTL(F6)=1.
PRNDTL(F7)=1. ;PRNDTL(F8)=1.
PRNDTL(F9)=1. ;PRNDTL(F10)=1.
PRNDTL(F11)=1. ;PRNDTL(F12)=1.
PRNDTL(F13)=1. ;PRNDTL(F14)=1.
PRNDTL(F15)=1. ;PRNDTL(F16)=1.
PRNDTL(F17)=1. ;PRNDTL(F18)=1.
PRNDTL(F19)=1. ;PRNDTL(F20)=1.
PRNDTL(F21)=1. ;PRNDTL(F22)=1.
PRNDTL(F23)=1. ;PRNDTL(F24)=1.
PRNDTL(F25)=1.
PRT(F1)=1. ;PRT(F2)=1.
PRT(F3)=1. ;PRT(F4)=1.
PRT(F5)=1. ;PRT(F6)=1.
PRT(F7)=1. ;PRT(F8)=1.
PRT(F9)=1. ;PRT(F10)=1.
PRT(F11)=1. ;PRT(F12)=1.
PRT(F13)=1. ;PRT(F14)=1.
PRT(F15)=1. ;PRT(F16)=1.
PRT(F17)=1. ;PRT(F18)=1.
PRT(F19)=1. ;PRT(F20)=1.
PRT(F21)=1. ;PRT(F22)=1.
PRT(F23)=1. ;PRT(F24)=1.
PRT(F25)=1.
CP1 =1. ;CP2 =1.
************************************************************
Group 10.Inter-Phase Transfer Processes
************************************************************
Group 11.Initial field variables (PHIs)
FIINIT(P1)=1.0E-10 ;FIINIT(F1)=1.0E-10
FIINIT(F2)=1.0E-10 ;FIINIT(F3)=1.0E-10
FIINIT(F4)=1.0E-10 ;FIINIT(F5)=1.0E-10
FIINIT(F6)=1.0E-10 ;FIINIT(F7)=1.0E-10
FIINIT(F8)=1.0E-10 ;FIINIT(F9)=1.0E-10
FIINIT(F10)=1.0E-10 ;FIINIT(F11)=1.0E-10
FIINIT(F12)=1.0E-10 ;FIINIT(F13)=1.0E-10
FIINIT(F14)=1.0E-10 ;FIINIT(F15)=1.0E-10
FIINIT(F16)=1.0E-10 ;FIINIT(F17)=1.0E-10
FIINIT(F18)=1.0E-10 ;FIINIT(F19)=1.0E-10
FIINIT(F20)=1.0E-10 ;FIINIT(F21)=1.0E-10
FIINIT(F22)=1.0E-10 ;FIINIT(F23)=1.0E-10
FIINIT(F24)=1.0E-10 ;FIINIT(F25)=1.
FIINIT(MNSQ)=1.0E-10 ;FIINIT(AVER)=1.0E-10
FIINIT(RATE)=1.
No PATCHes yet used for this Group
FSWEEP = 1
NAMFI =CHAM
************************************************************
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(INFLOWA ,CELL , 1, 1, 1, 1, 1, 1, 1, 1)
COVAL(INFLOWA ,P1 , FIXFLU ,0.5 )
COVAL(INFLOWA ,F1 ,0. ,1. )

PATCH(INFLOWB ,CELL , 1, 1, 1, 1, 1, 1, 1, 1)
COVAL(INFLOWB ,P1 , FIXFLU ,0.5 )
COVAL(INFLOWB ,F25 ,0. ,1. )

PATCH(OUTFLOW ,VOLUME, 1, 1, 1, 1, 1, 1, 1, 1)
COVAL(OUTFLOW ,P1 ,1. ,0. )
XCYCLE = F
EGWF = T
WALLCO = GRND2
************************************************************
Group 14. Downstream Pressure For PARAB
************************************************************
Group 15. Terminate Sweeps
LSWEEP = 400 ;ISWC1 = 1
LITHYD = 1 ;LITFLX = 1 ;LITC = 1 ;ITHC1 = 1
SELREF = T
RESFAC =1.0E-20
************************************************************
Group 16. Terminate Iterations
LITER(P1)=20 ;LITER(F1)=20
LITER(F2)=20 ;LITER(F3)=20
LITER(F4)=20 ;LITER(F5)=20
LITER(F6)=20 ;LITER(F7)=20
LITER(F8)=20 ;LITER(F9)=20
LITER(F10)=20 ;LITER(F11)=20
LITER(F12)=20 ;LITER(F13)=20
LITER(F14)=20 ;LITER(F15)=20
LITER(F16)=20 ;LITER(F17)=20
LITER(F18)=20 ;LITER(F19)=20
LITER(F20)=20 ;LITER(F21)=20
LITER(F22)=20 ;LITER(F23)=20
LITER(F24)=20 ;LITER(F25)=20
ENDIT(P1)=1.0E-03 ;ENDIT(F1)=1.0E-03
ENDIT(F2)=1.0E-03 ;ENDIT(F3)=1.0E-03
ENDIT(F4)=1.0E-03 ;ENDIT(F5)=1.0E-03
ENDIT(F6)=1.0E-03 ;ENDIT(F7)=1.0E-03
ENDIT(F8)=1.0E-03 ;ENDIT(F9)=1.0E-03
ENDIT(F10)=1.0E-03 ;ENDIT(F11)=1.0E-03
ENDIT(F12)=1.0E-03 ;ENDIT(F13)=1.0E-03
ENDIT(F14)=1.0E-03 ;ENDIT(F15)=1.0E-03
ENDIT(F16)=1.0E-03 ;ENDIT(F17)=1.0E-03
ENDIT(F18)=1.0E-03 ;ENDIT(F19)=1.0E-03
ENDIT(F20)=1.0E-03 ;ENDIT(F21)=1.0E-03
ENDIT(F22)=1.0E-03 ;ENDIT(F23)=1.0E-03
ENDIT(F24)=1.0E-03 ;ENDIT(F25)=1.0E-03
************************************************************
Group 17. Relaxation
RELAX(P1,LINRLX,1.)
RELAX(F1,LINRLX,0.5)
RELAX(F2,LINRLX,0.5)
RELAX(F3,LINRLX,0.5)
RELAX(F4,LINRLX,0.5)
RELAX(F5,LINRLX,0.5)
RELAX(F6,LINRLX,0.5)
RELAX(F7,LINRLX,0.5)
RELAX(F8,LINRLX,0.5)
RELAX(F9,LINRLX,0.5)
RELAX(F10,LINRLX,0.5)
RELAX(F11,LINRLX,0.5)
RELAX(F12,LINRLX,0.5)
RELAX(F13,LINRLX,0.5)
RELAX(F14,LINRLX,0.5)
RELAX(F15,LINRLX,0.5)
RELAX(F16,LINRLX,0.5)
RELAX(F17,LINRLX,0.5)
RELAX(F18,LINRLX,0.5)
RELAX(F19,LINRLX,0.5)
RELAX(F20,LINRLX,0.5)
RELAX(F21,LINRLX,0.5)
RELAX(F22,LINRLX,0.5)
RELAX(F23,LINRLX,0.5)
RELAX(F24,LINRLX,0.5)
RELAX(F25,LINRLX,0.5)
RELAX(MNSQ,LINRLX,1.)
RELAX(AVER,LINRLX,1.)
RELAX(RATE,LINRLX,1.)
OVRRLX =0.
EXPERT = F ;NNORSL = F
************************************************************
Group 18. Limits
VARMAX(P1)=1.0E+10 ;VARMIN(P1)=-1.0E+10
VARMAX(F1)=1. ;VARMIN(F1)=0.
VARMAX(F2)=1. ;VARMIN(F2)=0.
VARMAX(F3)=1. ;VARMIN(F3)=0.
VARMAX(F4)=1. ;VARMIN(F4)=0.
VARMAX(F5)=1. ;VARMIN(F5)=0.
VARMAX(F6)=1. ;VARMIN(F6)=0.
VARMAX(F7)=1. ;VARMIN(F7)=0.
VARMAX(F8)=1. ;VARMIN(F8)=0.
VARMAX(F9)=1. ;VARMIN(F9)=0.
VARMAX(F10)=1. ;VARMIN(F10)=0.
VARMAX(F11)=1. ;VARMIN(F11)=0.
VARMAX(F12)=1. ;VARMIN(F12)=0.
VARMAX(F13)=1. ;VARMIN(F13)=0.
VARMAX(F14)=1. ;VARMIN(F14)=0.
VARMAX(F15)=1. ;VARMIN(F15)=0.
VARMAX(F16)=1. ;VARMIN(F16)=0.
VARMAX(F17)=1. ;VARMIN(F17)=0.
VARMAX(F18)=1. ;VARMIN(F18)=0.
VARMAX(F19)=1. ;VARMIN(F19)=0.
VARMAX(F20)=1. ;VARMIN(F20)=0.
VARMAX(F21)=1. ;VARMIN(F21)=0.
VARMAX(F22)=1. ;VARMIN(F22)=0.
VARMAX(F23)=1. ;VARMIN(F23)=0.
VARMAX(F24)=1. ;VARMIN(F24)=0.
VARMAX(F25)=1. ;VARMIN(F25)=0.
VARMAX(MNSQ)=1. ;VARMIN(MNSQ)=0.
VARMAX(AVER)=1. ;VARMIN(AVER)=0.
VARMAX(RATE)=1.0E+10 ;VARMIN(RATE)=-1.0E+10
************************************************************
Group 19. Data transmitted to GROUND
PARSOL = F
ISG62 = 1
SPEDAT(SET,MFM,MFMMOD,C,MFM)
SPEDAT(SET,MFM,NFLUIDS,I,25)
SPEDAT(SET,MFM,NFLR,I,25)
SPEDAT(SET,MFM,NFLF,I,1)
SPEDAT(SET,MFM,CONREA,R,10.)
SPEDAT(SET,MFM,CONMIX,R,10.)
SPEDAT(SET,MFM,RATEXP,R,5.)
SPEDAT(SET,MFM,HIGHF,R,1.)
SPEDAT(SET,MFM,LOWF,R,0.)
SPEDAT(SET,MFM,VISCON,R,0.)
************************************************************
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(F1,Y,N,Y,Y,Y,Y)
OUTPUT(F2,Y,N,Y,Y,Y,Y)
OUTPUT(F3,Y,N,Y,Y,Y,Y)
OUTPUT(F4,Y,N,Y,Y,Y,Y)
OUTPUT(F5,Y,N,Y,Y,Y,Y)
OUTPUT(F6,Y,N,Y,Y,Y,Y)
OUTPUT(F7,Y,N,Y,Y,Y,Y)
OUTPUT(F8,Y,N,Y,Y,Y,Y)
OUTPUT(F9,Y,N,Y,Y,Y,Y)
OUTPUT(F10,Y,N,Y,Y,Y,Y)
OUTPUT(F11,Y,N,Y,Y,Y,Y)
OUTPUT(F12,Y,N,Y,Y,Y,Y)
OUTPUT(F13,Y,N,Y,Y,Y,Y)
OUTPUT(F14,Y,N,Y,Y,Y,Y)
OUTPUT(F15,Y,N,Y,Y,Y,Y)
OUTPUT(F16,Y,N,Y,Y,Y,Y)
OUTPUT(F17,Y,N,Y,Y,Y,Y)
OUTPUT(F18,Y,N,Y,Y,Y,Y)
OUTPUT(F19,Y,N,Y,Y,Y,Y)
OUTPUT(F20,Y,N,Y,Y,Y,Y)
OUTPUT(F21,Y,N,Y,Y,Y,Y)
OUTPUT(F22,Y,N,Y,Y,Y,Y)
OUTPUT(F23,Y,N,Y,Y,Y,Y)
OUTPUT(F24,Y,N,Y,Y,Y,Y)
OUTPUT(F25,Y,N,Y,Y,Y,Y)
OUTPUT(MNSQ,Y,N,Y,N,N,N)
OUTPUT(AVER,Y,N,Y,N,N,N)
OUTPUT(RATE,Y,N,Y,N,N,N)
************************************************************
Group 22. Monitor Print-Out
IXMON = 1 ;IYMON = 1 ;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
IPLTF = 1 ;IPLTL = -1 ;NPLT = -1
ISWPRF = 1 ;ISWPRL = 100000
ITABL = 0 ;IPROF = 1
ABSIZ =0.5 ;ORSIZ =0.4
NTZPRF = 1 ;NCOLPF = 50
ICHR = 2 ;NCOLCO = 45 ;NROWCO = 20
No PATCHes yet used for this Group
************************************************************
Group 24. Dumps For Restarts
SAVE = T ;NOWIPE = F
NSAVE =CHAM
STOP
```