TEXT(Couette Flow VX                   
TITLE
INTEGER(NXS,NXE); REAL(REYNLD,GRNVELS,WALLVEL);BOOLEAN(KEMOD)
WALLVEL=10.0; NXS=2; NXE=3;KEMOD=F
    GROUP 5. X-direction grid specification
NX=5; GRDPWR(X,NX,1.0,1.0)
    GROUP 4. Y-direction grid specification
NY=1; GRDPWR(Y,NY,1.0,1.0)
    GROUP 7. Variables stored, solved & named
SOLVE(V1,TEM1); STORE(PRPS,BLOK)
IF(KEMOD) THEN
STORE(ENUT,VIST)
ENDIF
    GROUP 8. Terms (in differential equations) & devices
TERMS(TEM1,N,N,Y,N,Y,N); TERMS(V1,N,N,Y,Y,Y,Y)
    GROUP 9. Properties of the medium (or media)
ENUL=1./100.; PRNDTL(tem1)=2.0; RHO1=1.0
IF(KEMOD) THEN
ENUT=PRKOLM; TURMOD(KEMODL)
ENDIF
IENUTA=6;ENUTA=0.01;ENUTB=4.0; ; 
    GROUP 11. Initialization of variable or porosity fields
IF(KEMOD) THEN
FIINIT(KE)=0.001; FIINIT(EP)=0.001; FIINIT(VIST)=0.001
ENDIF
CONPOR(BLOCK,-1,CELL,-(nxs+1),-nxe,-1,-ny,-1,-1)
    Material 111 is steel
COVAL(BLOCK,PRPS,0.0,111); COVAL(BLOCK,BLOK,0.0,2.0)
    GROUP 13. Boundary conditions and special sources
WALL (MOVINW,WEST,1,1,1,NY,1,NZ,1,1)
COVAL(MOVINW,V1,1.0,WALLVEL); COVAL(MOVINW,TEM1,1.0,1.0)
WALL (MOVINE,EAST,NX,NX,1,1,1,NZ,1,1)
COVAL(MOVINE,V1,1.0,-WALLVEL); COVAL(MOVINE,TEM1,1.0,-1.0)
IF(KEMOD) THEN
COVAL(MOVINW,KE,LOGLAW,LOGLAW); COVAL(MOVINW,EP,LOGLAW,LOGLAW)
COVAL(MOVINE,KE,LOGLAW,LOGLAW); COVAL(MOVINE,EP,LOGLAW,LOGLAW)
ENDIF
    GROUP 16. Termination of iterations
RESREF(V1)=1.E-5
    GROUP 17. Under-relaxation devices
RELAX(V1,LINRLX,0.5)
IF(KEMOD) THEN
RELAX(ENUT,LINRLX,0.25)
ENDIF
    GROUP 18. Limits on variables or increments to them
IF(KEMOD) THEN
VARMIN(KE)=1.E-5; VARMAX(KE)=1.0; VARMIN(EP)=1.E-5; VARMAX(EP)=1.0E5
ENDIF
    GROUP 22. Monitor print-out
IZMON=1; IXMON=NX/4; ITABL=1
    GROUP 23. Field print-out and plot control
IF(KEMOD) THEN
OUTPUT(ENUT,N,N,N,N,N,N)
ENDIF
OUTPUT(PRPS,N,N,N,N,N,N); OUTPUT(BLOK,N,N,N,N,N,N)
PATCH(WPROFIL,PROFIL,1,1,1,NY,NZ,NZ,1,1)
PLOT(WPROFIL,V1,0.0,1.0); PLOT(WPROFIL,TEM1,0.0,0.0)
IF(KEMOD) THEN
PATCH(PROFIL,PROFIL,1,1,1,NY,NZ,NZ,1,1)
PLOT(PROFIL,VIST,0.0,0.0); PLOT(PROFIL,KE,0.0,0.0)
PLOT(PROFIL,EP,0.0,0.0)
ENDIF
    GROUP 24. DUMPS FOR RESTARTS
LSWEEP=100; TSTSWP=LSWEEP/5; NPRINT=10; REYNLD=1.0/ENUL