GROUP 1. Run title
TEXT(FLOW AROUND A SHIP'S STERN :        B530
TITLE
  DISPLAY
  The solution domain is a cylindrical quadrant in which the hull
  half-section occupies the region near the axis.  The south
  boundary represents the hull surface and the east boundary the
  waterline. The north cylindrical boundary has a constant
  pressure specification to simulate approximately an infinite
  domain by allowing mass and axial momentum to cross it.
  The inlet plane is at midships and the outlet plane is placed
  beyond the stern. A boundary-layer inlet profile is prescribed
  at the inlet and a fixed-pressure condition is supplied at the
  exit.
    The active input commands define a viscous-flow calculation,
  using a prescribed turbulent kinematic viscosity. The skin-
  friction at the hull is evaluated by means of the logarithmic
  law.
    The grid in file GRID2 was generated by algebraic interpolation.
  ENDDIS
REAL(WIN,COEF,VALW)
INTEGER(NZWALL)
 
    GROUP 3. X-direction grid specification
NX=5
    GROUP 4. Y-direction grid specification
NY=7
    GROUP 5. Z-direction grid specification
NZ=16;NZWALL=9
    GROUP 6. Body-fitted coordinates or grid distortion
BFC=T;NONORT=T; READCO(GRID2)
    GROUP 7. Variables stored, solved & named
SOLVE(P1,U1,V1,W1)
SOLUTN(P1,Y,Y,Y,N,N,N);STORE(ENUT)
    GROUP 9. Properties of the medium (or media)
RHO1=1000.;ENUL=1.1E-6;ENUT=1.0E-4
    GROUP 11. Initialization of variable or porosity fields
WIN=1.726
FIINIT(W1)=WIN
COEF=1000.
VALW=WIN*RHO1/COEF
FIINIT(P1)=VALW
INIADD=F
    GROUP 13. Boundary conditions and special sources
INLET(INLETY1,LOW,1,NX,1,1,1,1,1,1)
VALUE(INLETY1,P1,0.655*WIN*RHO1)
VALUE(INLETY1,W1,0.655*WIN)
INLET(INLETY2,LOW,1,NX,2,2,1,1,1,1)
VALUE(INLETY2,P1,0.886*WIN*RHO1)
VALUE(INLETY2,W1,0.886*WIN)
INLET(INLET,LOW,1,NX,3,NY,1,1,1,1)
VALUE(INLET,P1,WIN*RHO1)
VALUE(INLET,W1,WIN)
 
PATCH(OUTLET,HIGH,1,NX,1,NY,NZ,NZ,1,1)
COVAL(OUTLET,P1,COEF,0.0)
COVAL(OUTLET,U1,ONLYMS,0.)
COVAL(OUTLET,V1,ONLYMS,0.)
COVAL(OUTLET,W1,ONLYMS,WIN)
 
PATCH(WATER,NORTH,1,NX,NY,NY,1,NZ,1,1)
COVAL(WATER,P1,1.0,VALW)
COVAL(WATER,W1,ONLYMS,WIN)
 
WALL (WALL,SOUTH,1,NX,1,1,1,NZWALL,1,1)
COVAL(WALL,U1,LOGLAW,0.0)
COVAL(WALL,W1,LOGLAW,0.0)
WALL (WFUNAFTW,SOUTH,2,NX,1,1,NZWALL+1,NZWALL+1,1,1)
COVAL(WFUNAFTW,U1,LOGLAW,0.0)
COVAL(WFUNAFTW,W1,LOGLAW,0.0)
WALL (WFUNAFT2,SOUTH,3,NX,1,1,NZWALL+2,NZWALL+2,1,1)
COVAL(WFUNAFT2,U1,LOGLAW,0.0)
COVAL(WFUNAFT2,W1,LOGLAW,0.0)
WALL (WFUNAFT3,SOUTH,3,NX,1,1,NZWALL+3,NZWALL+3,1,1)
COVAL(WFUNAFT3,U1,LOGLAW,0.0)
COVAL(WFUNAFT3,W1,LOGLAW,0.0)
WALL (WFUNAFT4,SOUTH,4,NX,1,1,NZWALL+4,NZWALL+4,1,1)
COVAL(WFUNAFT4,U1,LOGLAW,0.0)
COVAL(WFUNAFT4,W1,LOGLAW,0.0)
 
    GROUP 15. Termination of sweeps
LSWEEP=20
    GROUP 16. Termination of iterations
LITER(P1)=1;LITER(U1)=2;LITER(V1)=2;LITER(W1)=10
    GROUP 17. Under-relaxation devices
RELAX(P1,LINRLX,0.1)
RELAX(W1,FALSDT,0.05)
RELAX(U1,FALSDT,0.05)
RELAX(V1,FALSDT,0.05)
    GROUP 18
VARMIN(ENUT)=10.*ENUL;VARMAX(ENUT)=.1
    GROUP 21. Print-out of variables
OUTPUT(ENUT,Y,N,N,N,Y,Y)
    GROUP 22. Spot-value print-out
IYMON=2;IZMON=12;IXMON=3;TSTSWP=-1
SELREF=T; RESFAC=0.01
    GROUP 23. Field print-out and plot control
XZPR=T;IYPRF=1;IYPRL=1;NZPRIN=2
PATCH(HULL,CONTUR,1,NX,1,1,1,NZ,1,1)
PLOT(HULL,P1,0.0,20.0)
PATCH(STERN,CONTUR,1,NX,1,NY,10,10,1,1)
PLOT(STERN,P1,0.0,20.0);PLOT(STERN,WCRT,0.0,20.0)