filter_h.f

Go to the documentation of this file.
00001 C:\opentelemac\v7p0\sources\telemac2d\filter_h.f
00002 !
00062                      SUBROUTINE FILTER_H
00063 !                    *******************
00064 !
00065      &(VEC,T1,MESH,MSK,MASKEL,N,FLODEL,YAFLODEL,DT,W1,UNSV2D)
00066 !
00067 !***********************************************************************
00068 ! TELEMAC2D   V6P1                                   21/08/2010
00069 !***********************************************************************
00070 !
00071 !
00072 !
00073 !
00074 !
00075 !
00076 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00077 !| DT             |-->| TIME STEP IN SECONDS
00078 !| FLODEL         |<->| FLUXES ALONG SEGMENTS
00079 !| MASKEL         |-->| MASKING OF ELEMENTS
00080 !|                |   | =1. : NORMAL   =0. : MASKED ELEMENT
00081 !| MSK            |-->| IF YES, THERE IS MASKED ELEMENTS.
00082 !| N              |-->| OPERATION WILL BE REPEATED N TIMES.
00083 !| T1             |-->| WORK ARRAY IN A BIEF_OBJ STRUCTURE
00084 !| UNSV2D         |-->| 1/(INTEGRAL OF TEST FUNCTIONS)
00085 !| VEC            |<->| VECTOR TO BE FILTERED
00086 !| W1             |<->| WORK ARRAY
00087 !| YAFLODEL       |-->| LOGICAL INDICATING IF FLODEL MUST BE UPDATED
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)           :: N
00099       DOUBLE PRECISION, INTENT(IN)  :: DT
00100       LOGICAL, INTENT(IN)           :: MSK,YAFLODEL
00101       TYPE(BIEF_MESH), INTENT(INOUT):: MESH
00102       TYPE(BIEF_OBJ), INTENT(INOUT) :: VEC,T1,FLODEL,W1
00103       TYPE(BIEF_OBJ), INTENT(IN)    :: MASKEL,UNSV2D
00104 !
00105 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00106 !
00107       INTEGER I,NELEM
00108 !
00109 !-----------------------------------------------------------------------
00110 !
00111       IF(YAFLODEL) CALL OV('X=C     ',W1%R,W1%R,W1%R,0.D0,3*MESH%NELMAX)
00112 !
00113       DO I=1,N
00114 !
00115 !-----------------------------------------------------------------------
00116 !
00117 !     COMPUTES FLUXES DUE TO SMOOTHING (SEE RELEASE NOTES 5.9)
00118 !
00119       IF(YAFLODEL) THEN
00120         NELEM=MESH%NELEM
00121         CALL SMOOTHING_FLUX(-1.D0/DT,VEC,VEC%R,MESH%SURFAC%R,
00122      &                      MESH%IKLE%I(      1  :  NELEM),
00123      &                      MESH%IKLE%I(NELEM+1  :2*NELEM),
00124      &                      MESH%IKLE%I(2*NELEM+1:3*NELEM),
00125      &                      NELEM,MESH%NELMAX,W1%R)
00126       ENDIF
00127 !
00128 !-----------------------------------------------------------------------
00129 !
00130 !     COMPUTES THE MATRIX/VECTOR PRODUCT OF MASS X VEC
00131 !
00132       CALL VECTOR(T1 ,'=','MASVEC          ',VEC%ELM,
00133      &            1.D0,VEC,VEC,VEC,VEC,VEC,VEC,MESH,MSK,MASKEL)
00134       IF(NCSIZE.GT.1) CALL PARCOM(T1,2,MESH)
00135 !
00136 !-----------------------------------------------------------------------
00137 !
00138 !     DIVIDES BY THE MASS OF THE BASES: F = M * F / (ASSEMBLED M)
00139 !
00140       CALL OS('X=YZ    ',X=VEC,Y=T1,Z=UNSV2D)
00141 !
00142 !-----------------------------------------------------------------------
00143 !
00144       ENDDO ! I
00145 !
00146 !     TAKES FLUXES DUE TO THE SMOOTHING OF NEGATIVE DEPTHS INTO ACCOUNT
00147 !     FLODEL NOT INITIALISED
00148 !
00149       IF(YAFLODEL) THEN
00150 !
00151         CALL FLUX_EF_VF(FLODEL%R,W1%R,MESH%NSEG,MESH%NELEM,
00152      &                  MESH%ELTSEG%I,MESH%ORISEG%I,
00153      &                  MESH%IKLE%I,.FALSE.,0)
00154 !
00155       ENDIF
00156 !
00157 !-----------------------------------------------------------------------
00158 !
00159       RETURN
00160       END

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