photon use
  p;;;;;;
 
  view z
 
  vec z m sh
  pause;vec off;red
  msg pressure contours on central plane
  con p1 z m fi;0.001;pause;con off;red
  msg temperature contours on central plane
  con h1 z m fi;0.001;pause;con off;red
  msg turbulence-energy contours on central plane
  con ke z m fi;0.001;pause;con off;red
  msg effective viscosity contours on central plane
  con enut z m fi;0.001;pause;con off;red
  view x;  gr ou x 1; gr ou x m;  gr ou y m
  msg temperature contours at outlet
  con h1 x m fi;0.001;pause;con off;red
  msg velocity vectors in outlet plane
  set ref vec 0.3;vec x m sh
  msg magnify by 5 in order to see more detail
  upause 2;  mag gr 5
   0.17687E+04 0.61228E+03 CR
 
  msg the left-hand boundary is the symmetry plane
  enduse
 ************************************************************
  Group 1. Run Title
 TEXT(Secondary Flow In Curved Duct     
 TITLE
   DISPLAY
 
   The steady flow of a turbulent fluid in a smooth-walled square-
   sectioned duct exhibits "secondary flow", ie radially-outward
   flow near the plane of symmetry and radially-inward flow near
   the plane walls.
 
   The k-epsilon turbulence model is used, with the KELIN=3
   linearization feature; and heat transfer is also computed.
 
   PHOTON USE commands are supplied.
 
   ENDDIS
 REAL(UIN,HEIGHT,WIDTH,LENGTH,KEIN,EPIN,FLOWTIME,DTFVEL)
 REAL(DISSTIME)
 
 UIN=1.0;HEIGHT=0.02;WIDTH=0.01;RINNER=0.05;LENGTH=3.159*RINNER
 NX=20;NY=10;NZ=5
 
 KEIN=0.001*UIN**2; EPIN=KEIN**1.5/(0.1*WIDTH)
 DISSTIME=KEIN/EPIN; FLOWTIME=LENGTH/UIN; DTFVEL=FLOWTIME
 
 mesga(uin=:uin:, height=:height:, width=:width:, length=:length:
 mesg(kein=:kein:, epin=:epin:
 mesg(flowtime=:flowtime:, disstime=:disstime:
 mesgb(dtfls vel=:dtfvel:
 mesgm(nx=:nx:  OK? If not, insert other value
 readvdu(nx,int,nx)
 mesgm(ny=:ny:  OK? If not, insert other value
 readvdu(ny,int,ny)
 mesgm(nz=:nz:  OK? If not, insert other value
 readvdu(nz,int,nz)
  Group 2. Transience
 STEADY  =    T
  Groups 3, 4, 5  Grid Information
    * Overall number of cells, RSET(M,NX,NY,NZ,tolerance)
 RSET(M,nx,ny,nz,1.E-05)
    * Overall domain extent, RSET(D,name,XULAST,YVLAST,ZWLAST)
 RSET(D,CHAM,3.159,height,width)
CARTES=F
  Group 7. Variables: STOREd,SOLVEd,NAMEd
 ONEPHS  =    T
    * Non-default variable names
 NAME(48) =ENUT ; NAME(49) =DEN1
    * Solved variables list
 SOLVE(P1  ,U1  ,V1  ,W1  ,KE  ,EP  ,H1  )
    * Stored variables list
 STORE(DEN1,ENUT);SOLUTN(P1  ,Y,Y,Y,N,N,N)
  Group 8. Terms & Devices
 TERMS( H1,N,P,P,P,P,P)
 NEWENT  =    T
  group 9. properties
 RHO1    = 1.189
 EL1     = STRAIN
 ENUL    = 1.589E-05 ;ENUT   = PRKOLM
 PRNDTL(H1  ) =  7.360E-01
 PRT   (EP  ) =  1.314
    GROUP 10. Inter-phase-transfer processes and properties
  group 11.initialise var/porosity fields
 FIINIT(U1)=UIN
 FIINIT(KE  ) =  KEIN;FIINIT(EP  ) =  EPIN
 FIINIT(H1  ) =  0.0;FIINIT(ENUT) =  KEIN**2/EPIN
 INIADD  =    T
  group 13. boundary & special sources
 
 PATCH (KESOURCE,PHASEM,1,20,1,20,1,10,1,1)
 COVAL (KESOURCE,KE  ,KESOURCE ,KESOURCE )
 COVAL (KESOURCE,EP  ,KESOURCE ,KESOURCE )
 
 PATCH(INFLOW,WEST,1,1,1,NY,1,NZ,1,1)
 COVAL(INFLOW,P1,FIXFLU,UIN*RHO1);COVAL(INFLOW,U1,ONLYMS,UIN)
 COVAL(INFLOW,KE,ONLYMS,KEIN);COVAL(INFLOW,EP,ONLYMS,EPIN)
 COVAL(INFLOW,H1,ONLYMS,1.0)
 
 PATCH(OUTFLOW,WEST,NX,NX,1,NY,1,NZ,1,1)
 COVAL(OUTFLOW,P1,1.E-3,0.0)
 
IF(NZ.GT.1) THEN
 PATCH(LOWWALL,LWALL,1,NX,1,NY,1,1,1,1)
 COVAL(LOWWALL,U1,LOGLAW,0.0);COVAL(LOWWALL,V1,LOGLAW,0.0)
 COVAL(LOWWALL,KE,LOGLAW,0.0);COVAL(LOWWALL,EP,LOGLAW,0.0)
 COVAL(LOWWALL,H1,LOGLAW,0.0)
ENDIF
 
IF(NY.GT.1) THEN
 PATCH(SOUWALL,SWALL,1,NX,1,1,1,NZ,1,1)
 COVAL(SOUWALL,U1,LOGLAW,0.0);COVAL(SOUWALL,W1,LOGLAW,0.0)
 COVAL(SOUWALL,KE,LOGLAW,LOGLAW);COVAL(SOUWALL,EP,LOGLAW,LOGLAW)
 COVAL(SOUWALL,H1,LOGLAW,0.0)
 
 PATCH(NORWALL,NWALL,1,NX,NY,NY,1,NZ,1,1)
 COVAL(NORWALL,U1,LOGLAW,0.0);COVAL(NORWALL,W1,LOGLAW,0.0)
 COVAL(NORWALL,KE,LOGLAW,LOGLAW);COVAL(NORWALL,EP,LOGLAW,LOGLAW)
 COVAL(NORWALL,H1,LOGLAW,0.0)
ENDIF
    GROUP 14. Downstream pressure for PARAB=.TRUE.
  Group 15. Terminate Sweeps
 LSWEEP=50;SELREF=T; RESFAC  = 1.E-05 * nx * ny * nz
  Group 17. Relaxation
 RELAX(U1,FALSDT,DTFVEL);RELAX(V1,FALSDT,DTFVEL)
 RELAX(W1,FALSDT,0.1*DTFVEL)
 KELIN=3;RELAX(KE,LINRLX,0.5);RELAX(EP,LINRLX,1.0)
  Group 19. EARTH Calls To GROUND Station
 GENK    =    T
  Group 22. Monitor Print-Out
TSTSWP=-1;IXMON=NX-1;IYMON=NY/2;IZMON=NZ/2
  Group 24. Dumps For Restarts