coefro.f

Go to the documentation of this file.
00001 C:\opentelemac\v7p0\sources\telemac2d\coefro.f
00002 !
00064                      SUBROUTINE COEFRO
00065 !                    *****************
00066 !
00067      &(CF,H,U,V,KARMAN,KFROT,CHESTR,GRAV,MESH,T1)
00068 !
00069 !***********************************************************************
00070 ! TELEMAC2D   V6P1                                   21/08/2010
00071 !***********************************************************************
00072 !
00073 !
00074 !
00075 !
00076 !
00077 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00078 !| CF             |<--| ADIMENSIONAL FRICTION COEFFICIENT
00079 !| CHESTR         |-->| FRICTION COEFFICIENTS
00080 !| GRAV           |-->| GRAVITY
00081 !| H              |-->| WATER DEPTH
00082 !| KARMAN         |-->| VON KARMAN CONSTANT
00083 !| KFROT          |-->| FRICTION LAW ON BOTTOM
00084 !| MESH           |-->| MESH STRUCTURE
00085 !| T1             |<->| WORK BIEF_OBJ STRUCTURE
00086 !| U              |-->| X-COMPONENT OF VELOCITY
00087 !| V              |-->| Y-COMPONENT OF VELOCITY
00088 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00089 !
00090       USE BIEF
00091 !
00092       IMPLICIT NONE
00093       INTEGER LNG,LU
00094       COMMON/INFO/LNG,LU
00095 !
00096 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00097 !
00098       INTEGER, INTENT(IN)            :: KFROT
00099       DOUBLE PRECISION, INTENT(IN)   :: GRAV,KARMAN
00100       TYPE(BIEF_OBJ), INTENT(INOUT)  :: CF,T1
00101       TYPE(BIEF_OBJ), INTENT(IN)     :: CHESTR,H,U,V
00102       TYPE(BIEF_MESH), INTENT(INOUT) :: MESH
00103 !
00104 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00105 !
00106       INTEGER NPOIN,N,IELMC,IELMH
00107 !
00108       DOUBLE PRECISION TIERS,HC,UNORM,AUX,INLOG,TRENTESURE
00109       DOUBLE PRECISION, POINTER :: HH(:)
00110 !
00111       INTRINSIC SQRT,MAX,LOG
00112 !
00113 !-----------------------------------------------------------------------
00114 !
00115       IELMC = CF%ELM
00116       IELMH = H%ELM
00117 !
00118 !  DEPTH WITH THE SAME DISCRETISATION AS CF
00119 !  IN CASES WHERE IT IS NEEDED.
00120 !
00121       IF(KFROT.NE.0.AND.KFROT.NE.2) THEN
00122 !
00123         IF(IELMC.EQ.IELMH) THEN
00124           HH=>H%R
00125         ELSE
00126           CALL OS( 'X=Y     ' , X=T1 , Y=H )
00127           CALL CHGDIS( T1 , IELMH , IELMC , MESH )
00128           HH=T1%R
00129         ENDIF
00130 !
00131       ENDIF
00132 !
00133       NPOIN = CF%DIM1
00134 !
00135 !-----------------------------------------------------------------------
00136 !
00137       TIERS  = 1.D0/3.D0
00138 !
00139 !  FRICTION COEFFICIENT
00140 !
00141 !     LAWS OF FRICTION:
00142 !
00143 !     KFROT = 0:  NO FRICTION
00144 !     KFROT = 1:  HAALAND
00145 !     KFROT = 2:  CHEZY
00146 !     KFROT = 3:  STRICKLER
00147 !     KFROT = 4:  MANNING
00148 !     KFROT = 5:  NIKURADSE
00149 !
00150 !     *******************
00151       IF(KFROT.EQ.0) THEN
00152 !     *******************
00153 !
00154         DO N=1,NPOIN
00155           CF%R(N) = 0.D0
00156         ENDDO
00157 !
00158 !     ***********************
00159       ELSEIF(KFROT.EQ.1) THEN
00160 !     ***********************
00161 !
00162         DO N=1,NPOIN
00163           HC = MAX(HH(N),1.D-4)
00164           UNORM = MAX(SQRT(U%R(N)**2+V%R(N)**2),1.D-6)
00165 !                       1.D-6: LAMINAR VISCOSITY OF THE WATER
00166           INLOG =(6.9D0*1.D-6/4.D0/HC/UNORM)**3+
00167      &                                  (CHESTR%R(N)/14.8D0/HC)**3.33
00168           INLOG = MIN(1.D0-1.D-6,INLOG)
00169           AUX   = -0.6D0*LOG(INLOG)/LOG(10.D0)
00170           CF%R(N) = 0.25D0 / AUX**2
00171         ENDDO
00172 !
00173 !     ***********************
00174       ELSEIF(KFROT.EQ.2) THEN
00175 !     ***********************
00176 !
00177         DO N=1,NPOIN
00178           CF%R(N) = 2 * GRAV / CHESTR%R(N)**2
00179         ENDDO
00180 !
00181 !     ***********************
00182       ELSEIF(KFROT.EQ.3) THEN
00183 !     ***********************
00184 !
00185         DO N=1,NPOIN
00186           HC = MAX(HH(N),1.D-4)
00187           CF%R(N) = 2 * GRAV / CHESTR%R(N)**2 / HC**TIERS
00188         ENDDO
00189 !
00190 !     ***********************
00191       ELSEIF(KFROT.EQ.4) THEN
00192 !     ***********************
00193 !
00194         DO N=1,NPOIN
00195           HC = MAX(HH(N),1.D-4)
00196           CF%R(N) = 2 * CHESTR%R(N)**2 * GRAV / HC**TIERS
00197         ENDDO
00198 !
00199 !     ***********************
00200       ELSEIF(KFROT.EQ.5) THEN
00201 !     ***********************
00202 !
00203         TRENTESURE=30.D0/EXP(1.D0)
00204         DO N=1,NPOIN
00205           HC = MAX(HH(N),1.D-4)
00206           CF%R(N) = 2.D0 / (LOG( TRENTESURE*HC/CHESTR%R(N))/KARMAN )**2
00207         ENDDO
00208 !
00209 !     ****
00210       ELSE
00211 !     ****
00212 !
00213         IF(LNG.EQ.1) WRITE(LU,300) KFROT
00214         IF(LNG.EQ.2) WRITE(LU,301) KFROT
00215 300     FORMAT(1X,'COEFRO : LOI DE FROTTEMENT INCONNUE :',1I6)
00216 301     FORMAT(1X,'COEFRO: UNKNOWN LAW OF BOTTOM FRICTION: ',1I6)
00217         CALL PLANTE(1)
00218         STOP
00219 !
00220 !     *****
00221       ENDIF
00222 !     *****
00223 !
00224 !-----------------------------------------------------------------------
00225 !
00226       RETURN
00227       END

Generated on Fri Aug 31 2013 18:12:58 by S.E.Bourban (HRW) using doxygen 1.7.0