#N101
#cls
TEXT(point source, best schemes & CLDA)
TITLE
  DISPLAY
  
  This case shows that, for the diagonal-flow point-source
  problem of case n121, the CLDA is better that any other.
  
  Alter the ratio of v1 to U1 to compare them at other angles.
  ENDDIS
REAL(RATIO);RATIO=1.0
mesg(Ratio =:ratio: Insert other value if required
READVDU(RATIO,REAL,RATIO)
FLOLY=2.0*RATIO/(1.0+RATIO)
FLOLX=2.0/(1.0+RATIO)
FIINIT(U1)=FLOLX; FIINIT(V1)=FLOLY
FLOLY
FLOLX                                
  ENDDIS
PATCH(SOURCE,VOLUME,3,3,3,3,1,NZ,1,LSTEP)
DO II=NPH1,NPHI
  Insert zero values at south and west inlets
 COVAL(INL1,:II:,FLOLX,0.0);COVAL(INL2,:II:,FLOLY,0.0)
  Insert fixed source in cell at IX=3, IY=3
 COVAL(SOURCE,:II:,FIXFLU,40.0)
ENDDO

  Switch off the poorly-perfoming schemes
SOLUTN(3SOL,Y,N,N,N,N,N); SOLUTN(CSOL,Y,N,N,N,N,N)
SOLUTN(FSOL,Y,N,N,N,N,N); SOLUTN(LSOL,Y,N,N,N,N,N)
SOLUTN(OSOL,Y,N,N,N,N,N); SOLUTN(QSOL,Y,N,N,N,N,N)
SOLUTN(VSOL,Y,N,N,N,N,N)

  Introduce the Conservative Low-Dispersion Algorithm
SOLVE(CWES,CEAS,CSOU,CNOR)
SOLUTN(CWES,P,P,N,Y,P,P); SOLUTN(CEAS,P,P,N,Y,P,P)
SOLUTN(CNOR,P,P,N,Y,P,P); SOLUTN(CSOU,P,P,N,Y,P,P)
 
TERMS(CWES,N,N,N,N,Y,Y); TERMS(CEAS,N,N,N,N,Y,Y)
TERMS(CSOU,N,N,N,N,Y,Y); TERMS(CNOR,N,N,N,N,Y,Y)
 
PATCH(CLDA,CELL,1,NX,1,NY,1,NZ,1,LSTEP)
COVAL(CLDA,CNOR,GRND,GRND); COVAL(CLDA,CSOU,GRND,GRND)
COVAL(CLDA,CEAS,GRND,GRND); COVAL(CLDA,CWES,GRND,GRND)
  
  and corresponding boundary conditions
COVAL(INL1,CWES,FLOLX,0.0);COVAL(INL2,CWES,FLOLY,0.0)

 COVAL(SOURCE,CWES,FIXFLU,20.0*flolx)
 
COVAL(INL1,CEAS,FLOLX,0.0);COVAL(INL2,CEAS,FLOLY,0.0)
COVAL(INL1,CNOR,FLOLX,0.0);COVAL(INL2,CNOR,FLOLY,0.0)
COVAL(INL1,CSOU,FLOLX,0.0);COVAL(INL2,CSOU,FLOLY,0.0)
 COVAL(SOURCE,CSOU,FIXFLU,20.0*floly)
  Provide for line-printer profile output at IY=3*NY/4
PATCH(NOREDGE1,PROFIL,1,NX,3*NY/4,3*NY/4,1,NZ,1,LSTEP)
DO II=NPH1,NPH1+7
 COVAL(NOREDGE1,:II:,0.0,1.0)
ENDDO
PATCH(NOREDG2,PROFIL,1,NX,3*NY/4,3*NY/4,1,NZ,1,LSTEP)
DO II=NPH1+8,NPHI
 COVAL(NOREDG2,:II:,0.0,1.0)
ENDDO
COVAL(NOREDG2,CNOR,0.0,1.0)
nxprin=1;ixprf=2;ixprl=6; nyprin=1;iyprf=2;iyprl=6
STOP