mxptel.f

Go to the documentation of this file.
00001 C:\opentelemac\v7p0\sources\utils\bief\mxptel.f
00002 !
00076                      SUBROUTINE MXPTEL
00077 !                    *****************
00078 !
00079      &(MXPTVS,MXELVS,IKLES,IELM,NPOIN,NELEM,NDP,IPOBO,LISTIN)
00080 !
00081 !***********************************************************************
00082 ! BIEF   V7P0                                   21/08/2010
00083 !***********************************************************************
00084 !
00085 !
00086 !
00087 !
00088 !
00089 !
00090 !
00091 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00092 !| IELM           |-->| TYPE OF ELEMENT
00093 !| IKLES          |-->| LIKE CONNECTIVITY TABLE BUT IN SELAFIN FORMAT
00094 !|                |   | IKLES(3,NELEM) INSTEAD OF IKLE(NELEM,3)
00095 !| IPOBO          |-->| 0 FOR INNER POINTS
00096 !|                |   | NOT 0 FOR BOUNDARY POINTS (THEIR RANK ACTUALLY)
00097 !| LISTIN         |-->| IF YES : MXELVS AND MXPTVS WILL BE PRINTED
00098 !| MXELVS         |-->| MAXIMUM NUMBER OF NEIGHBOURING ELEMENTS
00099 !| MXPTVS         |-->| MAXIMUM NUMBER OF NEIGHBOURS OF A POINT
00100 !| NDP            |-->| NUMBER OF POINTS PER ELEMENT
00101 !| NELEM          |-->| NUMBER OF ELEMENTS
00102 !| NPOIN          |-->| NUMBER OF POINTS
00103 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00104 !
00105       USE BIEF, EX_MXPTEL => MXPTEL
00106       USE INTERFACE_PARALLEL
00107 !
00108       IMPLICIT NONE
00109       INTEGER LNG,LU
00110       COMMON/INFO/LNG,LU
00111 !
00112 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00113 !
00114       INTEGER, INTENT(INOUT) :: MXPTVS,MXELVS
00115       INTEGER, INTENT(IN)    :: IELM,NDP,NPOIN,NELEM
00116       INTEGER, INTENT(IN)    :: IKLES(NDP,NELEM),IPOBO(NPOIN)
00117       LOGICAL, INTENT(IN)    :: LISTIN
00118 !
00119 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00120 !
00121       INTEGER I,J,IELEM
00122       INTEGER, ALLOCATABLE :: ITRAV(:)
00123       ALLOCATE(ITRAV(NPOIN))
00124 !
00125 !-----------------------------------------------------------------------
00126 !
00127 ! 1) INITIALISES THE NUMBER OF NEIGHBOURING ELEMENTS TO 0:
00128 !
00129       DO I = 1 , NPOIN
00130         ITRAV(I) = 0
00131       ENDDO
00132 !
00133 ! 2) COUNTS THE NUMBER OF NEIGHBOURING ELEMENTS PER ASSEMBLY OPERATION:
00134 !
00135       DO J = 1, NDP
00136         DO IELEM = 1 , NELEM
00137           ITRAV(IKLES(J,IELEM)) = ITRAV(IKLES(J,IELEM)) + 1
00138         ENDDO
00139       ENDDO
00140 !
00141 ! 3) LOOKS FOR THE MAXIMUM :
00142 !
00143       MXELVS = ITRAV(1)
00144       DO I = 2 , NPOIN
00145         MXELVS = MAX(MXELVS,ITRAV(I))
00146       ENDDO
00147 !
00148 ! 4) NUMBER OF NEIGHBOURING POINTS: NEED TO ADD 1 TO THIS NUMBER
00149 !                                   FOR BOUNDARY NODES.
00150 !    SIMULTANEOUSLY LOOKS FOR THE MAXIMUM
00151 !
00152       IF(IELM.EQ.31) THEN
00153         CALL MXPTEL31(NELEM,NPOIN,MXELVS,IKLES,MXPTVS)
00154       ELSE
00155         MXPTVS = MXELVS
00156         DO I = 1 , NPOIN
00157           IF(IPOBO(I).NE.0) MXPTVS = MAX(MXPTVS,ITRAV(I)+1)
00158         ENDDO
00159       ENDIF
00160 !
00161 !-----------------------------------------------------------------------
00162 !
00163       IF(NCSIZE.GT.1) THEN
00164         MXPTVS=P_IMAX(MXPTVS)
00165         MXELVS=P_IMAX(MXELVS)
00166       ENDIF
00167 !
00168 !-----------------------------------------------------------------------
00169 !
00170       IF(LISTIN) THEN
00171         IF(LNG.EQ.1) WRITE(LU,97) MXELVS,MXPTVS
00172         IF(LNG.EQ.2) WRITE(LU,98) MXELVS,MXPTVS
00173         IF(NCSIZE.GT.1) THEN
00174           IF(LNG.EQ.1) WRITE(LU,*) '(MAILLAGE GLOBAL)'
00175           IF(LNG.EQ.2) WRITE(LU,*) '(GLOBAL MESH)'
00176         ENDIF
00177       ENDIF
00178 97    FORMAT(1X,'MXPTEL (BIEF) : NOMBRE MAXIMUM D''ELEMENTS VOISINS D'
00179 '     &UN POINT : ',1I3,/,1X,
00180      &          '                NOMBRE MAXIMUM DE POINTS VOISINS D'
00181 'UN     &POINT : ',1I3)
00182 98    FORMAT(1X,
00183 'MXPTEL (BIEF) : MAXIMUM NUMBER OF ELEMENTS AROUND A POI     &NT: ',1I3,/,1X,
00184      &          
00185 '                MAXIMUM NUMBER OF POINTS AROUND A POINT     &: ',1I3)
00186 !
00187 !-----------------------------------------------------------------------
00188 !
00189       DEALLOCATE(ITRAV)
00190 !
00191 !-----------------------------------------------------------------------
00192 !
00193       RETURN
00194       END

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