ustrbegin
namplt profile
ustrend
PHOTON USE
p;;;;
view z
msg contours at successive iz's show effects of increasing rconst
upause 1
msg fully-burned gas, D
msg concentration of fluid d; x=distorted distance; y=multiplier-1
upause 1
do kk = 1,10
con d z kk fi;0.002
enddo
msg partly-burned gas, C
msg concentration of fluid c; x=distorted distance; y=multiplier-1
upause 1
do kk = 1,10
con c z kk fi;0.002
enddo
msg partly-burned gas, B
msg concentration of fluid b; x=distorted distance; y=multiplier-1
upause 1
do kk = 1,10
con bb z kk fi;0.002
enddo
msg fully-unburned gas, A
msg concentration of fluid a; x=distorted distance; y=multiplier-1
upause 1
do kk = 1,10
con a z kk fi;0.002
enddo
ENDUSE
DISPLAY
This case illustrates the use of PLANT for creating a source which
is dependent on both the dependent variable (PHI) and the
independent variable (X), which is a requirement for the method of
simulation of flame propagation which involves solution of
the equation:
d2 PHI / dX**2 = R*gamma/(rho*u*X)**2
where R=reaction rate, rho*u= uniform mass flux through the flame
and X = exp{integral (rho*u/gamma) dD from -infinity to D}, where
D = distance normal to the flame
The 4-fluid model of turbulent combustion is used, the
concentrations of fluids A, B, C and D being represented by the
variables C1, C2, and C4 respectively.
It also illustrates the use of the y dimension as a parametric
multiplier, thus allowing the multiplying constant of the reaction
rate to have ten (ie NY) values in a single run.
This device is often useful when parametric studies have to be
made; for it also permits PHOTON to be used for display purposes.
A PHOTON USE file is supplied in this Q1.
ENDDIS
Group 1. Run Title
TEXT(Steady turb (4fl) fl. propagation :Z252
TITLE
************************************************************
Group 2. Transience
STEADY = T
************************************************************
GRDPWR(X,100,1.0,1.0);GRDPWR(Y,10,1.0,1.0)
GRDPWR(X,100,1.0,1.0);GRDPWR(Y,100,1.0,1.0)
GRDPWR(X,20,1.0,1.0);GRDPWR(Y,4,1.0,1.0)
grdpwr(z,5,1.0,1.0)
************************************************************
Group 7. Variables: STOREd,SOLVEd,NAMEd
NPOR and HPOR are stored, and set to zero, in order that there
be no interactions between solutions at different y- and z-values
SOLVE(C1,C2,C3,C4);STORE(NPOR,HPOR)
NAME(C1)=A; NAME(C2)=BB; NAME(C3)=C; NAME(C4)=D
B is called BB, because PLANT creates variables called L0name
in its GROUND, and conflict with the already-existing EARTH
variable L0B must be avoided.
TERMS(A,N,N,Y,P,P,P);TERMS(BB,N,N,Y,N,N,N)
TERMS(C,N,N,Y,P,P,P);TERMS(D,N,N,Y,N,N,N)
************************************************************
Group 9. Properties
ENUL=1.0
************************************************************
Group 11.Initialise Var/Porosity Fields
************************************************************
FIINIT(A)=0.25;FIINIT(BB)=0.25;FIINIT(C)=0.25;FIINIT(D)=0.25
FIINIT(NPOR)=0.0;FIINIT(HPOR)=0.0
Group 13. Boundary & Special Sources
************************************************************
PATCH(MINUSINF,WEST,1,1,1,NY,1,NZ,1,1);COVAL(MINUSINF,A,FIXVAL,1.0)
COVAL(MINUSINF,BB,FIXVAL,0.0);COVAL(MINUSINF,C,FIXVAL,0.0)
COVAL(MINUSINF,D,FIXVAL,0.0)
PATCH(DOWNSTRM,EAST,NX,NX,1,NY,1,NZ,1,1);COVAL(DOWNSTRM,A,1.E5,0.0)
COVAL(DOWNSTRM,BB,1.E5,0.0);COVAL(DOWNSTRM,C,1.E5,0.0)
COVAL(DOWNSTRM,D,1.E5,1.0)
PLANT inserts reaction-rate expressions
REAL(RCONST,MCONST)
RCONST=1.0
MCONST=0.5
TEXT(4fl fl prp; rconst=:rconst:; mconst=:mconst:
PLANTBEGIN
PATCH(MICRMIX,VOLUME,1,NX,1,NY,1,NZ,1,1)
A
CO= :MCONST:*(C+D)*XG2D**(-2)*(1.0+9.0*YG2D)
COVAL(MICRMIX,A,GRND,0.0)
D
VAL= 1-A-BB-C
COVAL(MICRMIX,D,fixval,grnd)
B
CO= :MCONST:*(D+1.E-6)*XG2D**(-2)*(1.0+9.0*YG2D)
VAL= A*(2.0*C/(D+1.E-6)+1.0)
COVAL(MICRMIX,BB,GRND,GRND)
C
CO= :MCONST:*(A+1.E-6)*XG2D**(-2)*(1.0+9.0*YG2D)
VAL= D*(2.0*BB/(A+1.E-6)+1.0)
COVAL(MICRMIX,C,GRND,GRND)
PATCH(REACTION,VOLUME,1,NX,1,NY,1,NZ,1,1)
C
CO= :RCONST:*XG2D**(-2)*(1.0+9.0*YG2D)*IZSTEP
COVAL(REACTION,C,GRND,0.0)
D
VAL= :RCONST:*C*XG2D**(-2)*(1.0+9.0*YG2D)*IZSTEP
COVAL(REACTION,D,FIXFLU,GRND)
PLANTEND
VARMIN(A)=0.0;VARMAX(A)=1.0;VARMIN(BB)=0.0;VARMAX(BB)=1.0
VARMIN(C)=0.0;VARMAX(C)=1.0;VARMIN(D)=0.0;VARMAX(D)=1.0
************************************************************
LSWEEP=15
************************************************************
Group 19. EARTH Calls To GROUND Station
NAMSAT=MOSG
************************************************************
Group 21. Print-out of Variables
************************************************************
Group 22. Monitor Print-Out
TSTSWP = 1;NPLT=1;IXMON=NX/2;IYMON=NY/2
************************************************************
Group 23.Field Print-Out & Plot Control
PATCH(PROFILE,PROFIL,1,NX,NY/2,NY/2,NZ/2,NZ/2,1,1)
COVAL(PROFILE,A,0.0,1.0);COVAL(PROFILE,BB,0.0,1.0)
COVAL(PROFILE,C,0.0,1.0);COVAL(PROFILE,D,0.0,1.0)
PATCH(CONTOURS,CONTUR,1,NX,1,NY,NZ/2,NZ/2,1,1)
COVAL(CONTOURS,A,0.0,10.0);COVAL(CONTOURS,BB,0.0,10.0)
COVAL(CONTOURS,C,0.0,10.0);COVAL(CONTOURS,D,0.0,10.0)
LIBREF=252
tstswp=-1
dmpstk=t
DISTIL=T
EX(A)=2.031E-01; EX(BB)=8.915E-02; EX(C)=2.805E-02
EX(D)=6.762E-01; EX(HPOR)=9.999E-12; EX(NPOR)=9.999E-12
LIBREF=252
STOP