CCM Test: Lid driven laminar flow in a skewed 2D-cavern. ************************************************************** DISPLAY The problem consider plane incompressible a laminar flow induced in a skewed 2D-cavity by the moving lid. The main objective of this case is to test CCM-method on the non- orthogonal grids. User can change the skew angle by modifying TET. This problem had been used as testcase in I. Demirdzic, Z. Lilek and M. Peric, "Fluid flow and heat transfer test problems for non-orthogonal grids; bench-mark solutions", Int.J.Numer.Methods Fluids, 15, 329-354 (1992) for two angles (TET= 30 and 45) and two Reynolds numbers (Re= 100 and Re= 1000). User can switch from the default colocated computational algorithm (CCM) to the staggered one (STAG) by setting LCCM = F. --------------------------------------------------------- ENDDIS L(PAUSE ************************************************************** BOOLEAN(LCCM,LNORT); LCCM = T ************************************************************** PHOTON USE p ; ; ; ; ; msg Computational Domain: gr k 1 msg Press Any Key to Continue... pause cl set vec av off msg Velocity Vectors: vec k 1 sh msg Press Any Key to Continue... pause cl msg Contours of Pressure: con p1 k 1 fi;0.005 msg Press Any Key to Continue... pause cl msg Contours of Temperature: con temp k 1 fi;0.005 msg Press Eto exit PHOTON ... ENDUSE ************************************************************** GROUP 1. Run title and other preliminaries REAL(REYNU,UIN,DCAV,TET,PI,XCR,YCR,DTHYD) ** Problem definition: ***** The following grid sizes had been used: ***** 32x32; 64x64; 128x128 and 256x256. REYNU= 1000.; UIN= 1.0; DCAV= 1.0; TET = 45.0 PI = 3.1415; TET= PI*TET/180.; ENUL= UIN*DCAV/REYNU NX = 32; NY = 32; NZ = 1 IF(LCCM) THEN + TEXT(CCM : Re= 1000.; TET= 45. + LNORT = T ELSE + TEXT(STAG: Re= 1000.; TET= 45. + NONORT= T ENDIF TITLE GROUP 6. Body-fitted coordinates or grid distortion BFC = T; GSET(D,NX,NY,1,DCAV,DCAV,DCAV) GSET(P,P1,0.0,0.0, 0.0); GSET(P,P2,DCAV, 0.0,0.0) XCR = DCAV+DCAV*COS(TET); YCR = DCAV*SIN(TET) GSET(P,P3,XCR,YCR,0.0); GSET(P,P4,XCR-DCAV,YCR,0.0) GSET(L,L12,P1,P2,NX,S1.5); GSET(L,L23,P2,P3,NY,S1.5) GSET(L,L34,P3,P4,NX,S1.5); GSET(L,L41,P4,P1,NY,S1.5) GSET(F,F1,P1,-,P2,-,P3,-,P4,-); GSET(M,F1,+I+J,1,1,1) GSET(C,K:NZ+1:,F,K1,1,NX,1,NY,+,0.0,0.0,DCAV,INC,1.0) GVIEW(Z); VIEW GROUP 7. Variables stored, solved & named NAME(H1)= TEMP; SOLVE(P1,U1,V1,TEMP) IF(LCCM) THEN L($F150) ENDIF GROUP 8. Terms (in differential equations) & devices TERMS(TEMP,N,Y,Y,Y,Y,Y) GROUP 9. Properties of the medium (or media) RHO1= LINSCAL; RHO1A= 1.189; RHO1B= -0.2; cp1=1.0 GROUP 11. Initialization of variable or porosity fields FIINIT(TEMP)= 0.0 GROUP 13. Boundary conditions and special sources ** Walls. PATCH(WS,SWALL,1, NX,1, 1, 1,1,1,1) PATCH(WN,NWALL,1, NX,NY,NY,1,1,1,1) PATCH(WW,WWALL,1, 1, 1, NY,1,1,1,1) PATCH(WE,EWALL,NX,NX,1, NY,1,1,1,1) COVAL(WS,TEMP,1.0,0.0); COVAL(WN,TEMP,1.0,1.0) COVAL(WW,TEMP,1.0,0.0); COVAL(WE,TEMP,1.0,0.0) IF(LCCM) THEN + COVAL(WS,UC1,1.0,0.0); COVAL(WS,VC1,1.0,0.0) + COVAL(WN,UC1,1.0,UIN); COVAL(WN,VC1,1.0,UIN*COS(TET)) + COVAL(WW,UC1,1.0,0.0); COVAL(WW,VC1,1.0,0.0) + COVAL(WE,UC1,1.0,0.0); COVAL(WE,VC1,1.0,0.0) ELSE + COVAL(WS,U1, 1.0,0.0); COVAL(WS,V1, 1.0,0.0) + COVAL(WN,U1, 1.0,UIN); COVAL(WN,V1, 1.0,UIN*COS(TET)) + COVAL(WW,U1, 1.0,0.0); COVAL(WW,V1, 1.0,0.0) + COVAL(WE,U1, 1.0,0.0); COVAL(WE,V1, 1.0,0.0) ENDIF ** Pressure relief PATCH(FIXPRS,CELL,NX/2,NX/2,NY/2,NY/2,1,1,1,1) COVAL(FIXPRS,P1,FIXP,0.0) GROUP 15. Termination of sweeps LSWEEP = 200; TSTSWP = -1 GROUP 16. Termination of iterations SELREF = T; RESFAC = 1.E-3 GROUP 17. Under-relaxation devices RELAX( P1,LINRLX,0.1); DTHYD = DCAV/NX/UIN RELAX(TEMP,FALSDT,DTHYD) IF(LCCM) THEN + RELAX(UC1,FALSDT,10.*DTHYD); RELAX(VC1,FALSDT,10.*DTHYD) ELSE + RELAX(U1 ,FALSDT,10.*DTHYD); RELAX(V1, FALSDT,10.*DTHYD) ENDIF GROUP 19. Data communicated by satellite to GROUND IF(LCCM) THEN * LSG4 activates non-orthogonality treatment in CCM/MBFGE. + LSG4= LNORT * LSG7 activates high order convection schemes in CCM/MBFGE. + lsg7 deactivated= T SCHMBEGIN VARNAM UC1 SCHEME SUPERB VARNAM VC1 SCHEME SUPERB VARNAM TEMP SCHEME SUPERB SCHMEND ENDIF GROUP 22. Spot-value print-out IXMON= NX/2+1; IYMON= NY/2+1; IZMON= 1