mt12bb.f

Go to the documentation of this file.
00001 C:\opentelemac\v7p0\sources\utils\bief\mt12bb.f
00002 !
00074                      SUBROUTINE MT12BB
00075 !                    *****************
00076 !
00077      &(  A11 , A12 , A13 , A14 ,
00078      &   A21 , A22 , A23 , A24 ,
00079      &   A31 , A32 , A33 , A34 ,
00080      &   A41 , A42 , A43 , A44 ,
00081      &   XMUL,SF,SU,SV,F,U,V,
00082      &   XEL,YEL,
00083      &   IKLE1,IKLE2,IKLE3,IKLE4,
00084      &   NELEM,NELMAX,ICOORD)
00085 !
00086 !***********************************************************************
00087 ! BIEF   V6P0                                   21/08/2010
00088 !***********************************************************************
00089 !
00090 !
00091 !
00092 !
00093 !
00094 !
00095 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00096 !| A11            |<--| ELEMENTS OF MATRIX
00097 !| A12            |<--| ELEMENTS OF MATRIX
00098 !| A13            |<--| ELEMENTS OF MATRIX
00099 !| A14            |<--| ELEMENTS OF MATRIX
00100 !| A21            |<--| ELEMENTS OF MATRIX
00101 !| A22            |<--| ELEMENTS OF MATRIX
00102 !| A23            |<--| ELEMENTS OF MATRIX
00103 !| A24            |<--| ELEMENTS OF MATRIX
00104 !| A31            |<--| ELEMENTS OF MATRIX
00105 !| A32            |<--| ELEMENTS OF MATRIX
00106 !| A33            |<--| ELEMENTS OF MATRIX
00107 !| A34            |<--| ELEMENTS OF MATRIX
00108 !| A41            |<--| ELEMENTS OF MATRIX
00109 !| A42            |<--| ELEMENTS OF MATRIX
00110 !| A43            |<--| ELEMENTS OF MATRIX
00111 !| A44            |<--| ELEMENTS OF MATRIX
00112 !| F              |-->| FUNCTION USED IN THE FORMULA
00113 !| ICOORD         |-->| 1: DERIVATIVE ALONG X, 2: ALONG Y
00114 !| IKLE1          |-->| FIRST POINTS OF TRIANGLES
00115 !| IKLE2          |-->| SECOND POINTS OF TRIANGLES
00116 !| IKLE3          |-->| THIRD POINTS OF TRIANGLES
00117 !| IKLE4          |-->| FOURTH POINTS OF TRIANGLES (QUADRATIC)
00118 !| IKLE5          |-->| FIFTH POINTS OF TRIANGLES (QUADRATIC)
00119 !| IKLE6          |-->| SIXTH POINTS OF TRIANGLES (QUADRATIC)
00120 !| NELEM          |-->| NUMBER OF ELEMENTS
00121 !| NELMAX         |-->| MAXIMUM NUMBER OF ELEMENTS
00122 !| SF             |-->| STRUCTURE OF FUNCTIONS F
00123 !| XEL            |-->| ABSCISSAE OF POINTS IN THE MESH, PER ELEMENT
00124 !| YEL            |-->| ORDINATES OF POINTS IN THE MESH, PER ELEMENT
00125 !| XMUL           |-->| MULTIPLICATION FACTOR
00126 !| F              |-->| FUNCTION USED IN THE FORMULA
00127 !| ICOORD         |-->| 1: DERIVATIVE ALONG X, 2: ALONG Y
00128 !| IKLE1          |-->| FIRST POINTS OF TRIANGLES
00129 !| IKLE2          |-->| SECOND POINTS OF TRIANGLES
00130 !| IKLE3          |-->| THIRD POINTS OF TRIANGLES
00131 !| IKLE4          |-->| QUASI-BUBBLE POINT
00132 !| NELEM          |-->| NUMBER OF ELEMENTS
00133 !| NELMAX         |-->| MAXIMUM NUMBER OF ELEMENTS
00134 !| SF             |-->| STRUCTURE OF FUNCTIONS F
00135 !| SU             |-->| BIEF_OBJ STRUCTURE OF U
00136 !| SURFAC         |-->| AREA OF TRIANGLES
00137 !| SV             |-->| BIEF_OBJ STRUCTURE OF V
00138 !| U              |-->| FUNCTION U USED IN THE FORMULA
00139 !| V              |-->| FUNCTION V USED IN THE FORMULA
00140 !| XEL            |-->| ABSCISSAE OF POINTS IN THE MESH, PER ELEMENT
00141 !| YEL            |-->| ORDINATES OF POINTS IN THE MESH, PER ELEMENT
00142 !| XMUL           |-->| MULTIPLICATION FACTOR
00143 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00144 !
00145       USE BIEF, EX_MT12BB => MT12BB
00146 !
00147       IMPLICIT NONE
00148       INTEGER LNG,LU
00149       COMMON/INFO/LNG,LU
00150 !
00151 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00152 !
00153       INTEGER, INTENT(IN) :: NELEM,NELMAX,ICOORD
00154       INTEGER, INTENT(IN) :: IKLE1(NELMAX),IKLE2(NELMAX)
00155       INTEGER, INTENT(IN) :: IKLE3(NELMAX),IKLE4(NELMAX)
00156 !
00157       DOUBLE PRECISION, INTENT(INOUT) :: A11(*),A12(*),A13(*),A14(*)
00158       DOUBLE PRECISION, INTENT(INOUT) :: A21(*),A22(*),A23(*),A24(*)
00159       DOUBLE PRECISION, INTENT(INOUT) :: A31(*),A32(*),A33(*),A34(*)
00160       DOUBLE PRECISION, INTENT(INOUT) :: A41(*),A42(*),A43(*),A44(*)
00161 !
00162       DOUBLE PRECISION, INTENT(IN) :: XMUL
00163       DOUBLE PRECISION, INTENT(IN) :: F(*),U(*),V(*)
00164 !
00165 !     STRUCTURES OF F, U, V
00166       TYPE(BIEF_OBJ), INTENT(IN) :: SF,SU,SV
00167 !
00168       DOUBLE PRECISION, INTENT(IN) :: XEL(NELMAX,3),YEL(NELMAX,3)
00169 !
00170 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00171 !
00172       INTEGER IELEM,IELMF,IELMU,IELMV
00173       DOUBLE PRECISION X2,X3,Y2,Y3,F1,F2,F3,F4
00174       DOUBLE PRECISION U1,U2,U3,U4,V1,V2,V3,V4,UX,UY
00175 !
00176 !-----------------------------------------------------------------------
00177 !
00178       IELMF=SF%ELM
00179       IELMU=SU%ELM
00180       IELMV=SV%ELM
00181 !
00182 !-----------------------------------------------------------------------
00183 !  CASE WHERE F IS OF TYPE P1
00184 !-----------------------------------------------------------------------
00185 !
00186       IF(IELMF.EQ.11) THEN
00187 !
00188       IF(IELMU.EQ.10.AND.IELMV.EQ.10) THEN
00189 !
00190 !================================
00191 !  DERIVATIVE WRT X  =
00192 !================================
00193 !
00194         IF(ICOORD.EQ.1) THEN
00195 !
00196 !   LOOP ON THE ELEMENTS
00197 !
00198         DO IELEM = 1 , NELEM
00199 !
00200 !   INITIALISES THE GEOMETRICAL VARIABLES
00201 !
00202         X2 = XEL(IELEM,2)
00203         X3 = XEL(IELEM,3)
00204         Y2 = YEL(IELEM,2)
00205         Y3 = YEL(IELEM,3)
00206 !
00207         F1  =  F(IKLE1(IELEM))
00208         F2  =  F(IKLE2(IELEM)) - F1
00209         F3  =  F(IKLE3(IELEM)) - F1
00210 !
00211         UX  =  U(IELEM)
00212         UY  =  V(IELEM)
00213 !
00214 !   EXTRADIAGONAL TERMS
00215 !
00216       A12(IELEM) = ((UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(F3*Y2-F2*Y3))
00217      & *XMUL/(18*(X2*Y3-X3*Y2))
00218 !
00219       A13(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(F3*Y2-F2*Y3))
00220      & *XMUL/(18*(X2*Y3-X3*Y2))
00221 !
00222       A14(IELEM) = ((UX*Y3-UX*Y2+UY*X2-UY*X3)*(F3*Y2-F2*Y3))
00223      & *XMUL/(6*(X2* Y3-X3*Y2))
00224 !
00225       A21(IELEM) = (-(UX*Y3+UX*Y2-UY*X2-UY*X3)*(F3*Y2-F2*Y3))
00226      & *XMUL/(18*(X2*Y3-X3*Y2))
00227 !
00228       A23(IELEM) = (-(2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(F3*Y2-F2*Y3))
00229      & *XMUL/(18*(X2*Y3-X3*Y2))
00230 !
00231       A24(IELEM) = (-(UX*Y3-UY*X3)*(F3*Y2-F2*Y3))
00232      & *XMUL/(6*(X2*Y3-X3*Y2))
00233 !
00234       A31(IELEM) = ((UX*Y3+UX*Y2-UY*X2-UY*X3)*(F3*Y2-F2*Y3))
00235      & *XMUL/(18*(X2*Y3-X3*Y2))
00236 !
00237       A32(IELEM) = (-(UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(F3*Y2-F2*Y3))
00238      & *XMUL/(18*(X2*Y3-X3*Y2))
00239 !
00240       A34(IELEM) = ((UX*Y2-UY*X2)*(F3*Y2-F2*Y3))
00241      & *XMUL/(6*(X2*Y3-X3*Y2))
00242 !
00243       A41(IELEM) = (-(UX*Y3-UX*Y2+UY*X2-UY*X3)*(F3*Y2-F2*Y3))
00244      & *XMUL/(6*(X2*Y3-X3*Y2))
00245 !
00246       A42(IELEM) = ((UX*Y3-UY*X3)*(F3*Y2-F2*Y3))
00247      & *XMUL/(6*(X2*Y3-X3*Y2))
00248 !
00249       A43(IELEM) = (-(UX*Y2-UY*X2)*(F3*Y2-F2*Y3))
00250      & *XMUL/(6*(X2*Y3-X3*Y2))
00251 !
00252 !   DIAGONAL TERMS
00253 !   THE SUM OF THE MATRIX ROWS IS 0 (VECTOR)
00254 !
00255         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00256         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00257         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00258         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00259 !
00260       ENDDO ! IELEM
00261 !
00262         ELSEIF(ICOORD.EQ.2) THEN
00263 !
00264 !================================
00265 !  DERIVATIVE WRT Y  =
00266 !================================
00267 !
00268         DO IELEM = 1 , NELEM
00269 !
00270 !   INITIALISES THE GEOMETRICAL VARIABLES
00271 !
00272         X2  =  XEL(IELEM,2)
00273         X3  =  XEL(IELEM,3)
00274         Y2  =  YEL(IELEM,2)
00275         Y3  =  YEL(IELEM,3)
00276 !
00277         F1  =  F(IKLE1(IELEM))
00278         F2  =  F(IKLE2(IELEM)) - F1
00279         F3  =  F(IKLE3(IELEM)) - F1
00280 !
00281         UX  =  U(IELEM)
00282         UY  =  V(IELEM)
00283 !
00284 !   EXTRADIAGONAL TERMS
00285 !
00286       A12(IELEM) = (-(UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(X2*F3-X3*F2))
00287      & *XMUL/(18*(X2*Y3-X3*Y2))
00288 !
00289       A13(IELEM) = (-(2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(X2*F3-X3*F2))
00290      & *XMUL/(18*(X2*Y3-X3*Y2))
00291 !
00292       A14(IELEM) = (-(UX*Y3-UX*Y2+UY*X2-UY*X3)*(X2*F3-X3*F2))
00293      & *XMUL/(6*(X2*Y3-X3*Y2))
00294 !
00295       A21(IELEM) = ((UX*Y3+UX*Y2-UY*X2-UY*X3)*(X2*F3-X3*F2))
00296      & *XMUL/(18*(X2*Y3-X3*Y2))
00297 !
00298       A23(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(X2*F3-X3*F2))
00299      & *XMUL/(18*(X2*Y3-X3*Y2))
00300 !
00301       A24(IELEM) = ((UX*Y3-UY*X3)*(X2*F3-X3*F2))
00302      & *XMUL/(6*(X2*Y3-X3*Y2))
00303 !
00304       A31(IELEM) = (-(UX*Y3+UX*Y2-UY*X2-UY*X3)*(X2*F3-X3*F2))
00305      & *XMUL/(18*(X2*Y3-X3*Y2))
00306 !
00307       A32(IELEM) = ((UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(X2*F3-X3*F2))
00308      & *XMUL/(18*(X2*Y3-X3*Y2))
00309 !
00310       A34(IELEM) = (-(UX*Y2-UY*X2)*(X2*F3-X3*F2))
00311      & *XMUL/(6*(X2*Y3-X3*Y2))
00312 !
00313       A41(IELEM) = ((UX*Y3-UX*Y2+UY*X2-UY*X3)*(X2*F3-X3*F2))
00314      & *XMUL/(6*(X2*Y3-X3*Y2))
00315 !
00316       A42(IELEM) = (-(UX*Y3-UY*X3)*(X2*F3-X3*F2))
00317      & *XMUL/(6*(X2*Y3-X3*Y2))
00318 !
00319       A43(IELEM) = ((UX*Y2-UY*X2)*(X2*F3-X3*F2))
00320      & *XMUL/(6*(X2*Y3-X3*Y2))
00321 !
00322 !   DIAGONAL TERMS
00323 !   THE SUM OF THE MATRIX ROWS IS 0 (VECTOR)
00324 !
00325         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00326         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00327         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00328         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00329 !
00330         ENDDO ! IELEM
00331 !
00332         ELSE
00333 !
00334           IF (LNG.EQ.1) WRITE(LU,200) ICOORD
00335           IF (LNG.EQ.2) WRITE(LU,201) ICOORD
00336           CALL PLANTE(0)
00337           STOP
00338         ENDIF
00339 !
00340 !
00341       ELSEIF(IELMU.EQ.12) THEN
00342 !
00343 !================================
00344 !  DERIVATIVE WRT X  =
00345 !================================
00346 !
00347         IF(ICOORD.EQ.1) THEN
00348 !
00349 !   LOOP ON THE ELEMENTS
00350 !
00351         DO IELEM = 1 , NELEM
00352 !
00353 !   INITIALISES THE GEOMETRICAL VARIABLES
00354 !
00355         X2 = XEL(IELEM,2)
00356         X3 = XEL(IELEM,3)
00357         Y2 = YEL(IELEM,2)
00358         Y3 = YEL(IELEM,3)
00359 !
00360         F1  =  F(IKLE1(IELEM))
00361         F2  =  F(IKLE2(IELEM)) - F1
00362         F3  =  F(IKLE3(IELEM)) - F1
00363 !
00364         U1  =  U(IKLE1(IELEM))
00365         U2  =  U(IKLE2(IELEM))
00366         U3  =  U(IKLE3(IELEM))
00367         U4  =  U(IKLE4(IELEM))
00368         V1  =  V(IKLE1(IELEM))
00369         V2  =  V(IKLE2(IELEM))
00370         V3  =  V(IKLE3(IELEM))
00371         V4  =  V(IKLE4(IELEM))
00372 !
00373 !   EXTRADIAGONAL TERMS
00374 !
00375       A12(IELEM) = (-(2*X2*V4+4*X2*V2+2*X2*V1-X3*V4-2*X3*V2-X3
00376      & *V1+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2+U1*Y3-2*U1*Y2)*(F3+
00377      & F2)*(Y3+Y2))*XMUL/(216*(X2*Y3-X3*Y2))
00378 !
00379       A13(IELEM) = ((2*X2*V3+X2*V4+X2*V1-4*X3*V3-2*X3*V4-2*X3*
00380      & V1+4*U3*Y3-2*U3*Y2+2*U4*Y3-U4*Y2+2*U1*Y3-U1*Y2)*(F3*
00381      & Y2-F2*Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00382 !
00383       A14(IELEM) = (3*(X2*V3+2*X2*V4+X2*V1-2*X3*V3-4*X3*V4-2*
00384      & X3*V1+2*U3*Y3-U3*Y2+4*U4*Y3-2*U4*Y2+2*U1*Y3-U1*Y2)*(
00385      & F3*Y2-F2*Y3)-(4*X2*V4+2*X2*V2+2*X2*V1-2*X3*V4-X3*V2-
00386      & X3*V1+2*U4*Y3-4*U4*Y2+U2*Y3-2*U2*Y2+U1*Y3-2*U1*Y2)*(
00387      & F3+F2)*(Y3+Y2))*XMUL/(216*(X2*Y3-X3*Y2))
00388 !
00389       A21(IELEM) = (-(X2*V4+X2*V2+2*X2*V1+X3*V4+X3*V2+2*X3*V1-U4
00390      & *Y3-U4*Y2-U2*Y3-U2*Y2-2*U1*Y3-2*U1*Y2)*(F3+F2)*(Y3+Y2))
00391      & *XMUL/(216*(X2*Y3-X3*Y2))
00392 !
00393       A23(IELEM) = (-(2*X2*V3+X2*V4+X2*V2-4*X3*V3-2*X3*V4-2*X3
00394      & *V2+4*U3*Y3-2*U3*Y2+2*U4*Y3-U4*Y2+2*U2*Y3-U2*Y2)*(F3*
00395      & Y2-F2*Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00396 !
00397       A24(IELEM) = (-(3*(X2*V3+2*X2*V4+X2*V2-2*X3*V3-4*X3*V4-
00398      & 2*X3*V2+2*U3*Y3-U3*Y2+4*U4*Y3-2*U4*Y2+2*U2*Y3-U2*Y2)*
00399      & (F3*Y2-F2*Y3)+(2*X2*V4+X2*V2+X2*V1+2*X3*V4+X3*V2+X3*V1-
00400      & 2*U4*Y3-2*U4*Y2-U2*Y3-U2*Y2-U1*Y3-U1*Y2)*(F3+F2)*(Y3+Y2)
00401      & ))*XMUL/(216*(X2*Y3-X3*Y2))
00402 !
00403       A31(IELEM) = (-(X2*V3+X2*V4+2*X2*V1+X3*V3+X3*V4+2*X3*V1-U3
00404      & *Y3-U3*Y2-U4*Y3-U4*Y2-2*U1*Y3-2*U1*Y2)*(F3*Y2-F2*Y3))*XMUL/(
00405      & 72*(X2*Y3-X3*Y2))
00406 !
00407       A32(IELEM) = (-(2*X2*V3+2*X2*V4+4*X2*V2-X3*V3-X3*V4-2*X3
00408      & *V2+U3*Y3-2*U3*Y2+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2)*(F3*
00409      & Y2-F2*Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00410 !
00411       A34(IELEM) = (-(3*X2*V3+6*X2*V4+2*X2*V2+X2*V1-X3*V2+X3*V1
00412      & -3*U3*Y2-6*U4*Y2+U2*Y3-2*U2*Y2-U1*Y3-U1*Y2)*(F3*Y2-F2*
00413      & Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00414 !
00415       A41(IELEM) = ((X2*V4+X2*V2+2*X2*V1-U4*Y2-U2*Y2-2*U1*Y2)*(
00416      & F3+F2)*(Y3+Y2)+3*(X3*V3+X3*V4+2*X3*V1-U3*Y3-U4*Y3-2*U1
00417      & *Y3)*(F3*Y2-F2*Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00418 !
00419       A42(IELEM) = (3*(X2*V3+X2*V4+2*X2*V2-X3*V3-X3*V4-2*X3*V2+
00420      & U3*Y3-U3*Y2+U4*Y3-U4*Y2+2*U2*Y3-2*U2*Y2)*(F3*Y2-F2*Y3)+
00421      & (X2*V4+2*X2*V2+X2*V1-U4*Y2-2*U2*Y2-U1*Y2)*(F3+F2)*(Y3+
00422      & Y2))*XMUL/(72*(X2*Y3-X3*Y2))
00423 !
00424       A43(IELEM) = ((2*X2*V3+X2*V4+X2*V2-X3*V2+X3*V1-2*U3*Y2-U4*
00425      & Y2+U2*Y3-U2*Y2-U1*Y3)*(F3*Y2-F2*Y3))*XMUL/(24*(X2*Y3-X3*Y2))
00426 !
00427 !   DIAGONAL TERMS
00428 !   THE SUM OF EACH COLUMN IS 0
00429 !
00430         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00431         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00432         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00433         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00434 !
00435       ENDDO ! IELEM
00436 !
00437         ELSEIF(ICOORD.EQ.2) THEN
00438 !
00439 !================================
00440 !  DERIVATIVE WRT Y  =
00441 !================================
00442 !
00443         DO IELEM = 1 , NELEM
00444 !
00445 !   INITIALISES THE GEOMETRICAL VARIABLES
00446 !
00447         X2  =  XEL(IELEM,2)
00448         X3  =  XEL(IELEM,3)
00449         Y2  =  YEL(IELEM,2)
00450         Y3  =  YEL(IELEM,3)
00451 !
00452         F1  =  F(IKLE1(IELEM))
00453         F2  =  F(IKLE2(IELEM)) - F1
00454         F3  =  F(IKLE3(IELEM)) - F1
00455 !
00456         U1  =  U(IKLE1(IELEM))
00457         U2  =  U(IKLE2(IELEM))
00458         U3  =  U(IKLE3(IELEM))
00459         U4  =  U(IKLE4(IELEM))
00460         V1  =  V(IKLE1(IELEM))
00461         V2  =  V(IKLE2(IELEM))
00462         V3  =  V(IKLE3(IELEM))
00463         V4  =  V(IKLE4(IELEM))
00464 !
00465 !   EXTRADIAGONAL TERMS
00466 !
00467       A12(IELEM) = (2*X2*V4+4*X2*V2+2*X2*V1-X3*V4-2*X3*V2-X3*
00468      & V1+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2+U1*Y3-2*U1*Y2)*(X2+
00469      & X3)*(F3+F2)*XMUL/(216*(X2*Y3-X3*Y2))
00470 !
00471       A13(IELEM) = -(2*X2*V3+X2*V4+X2*V1-4*X3*V3-2*X3*V4-2*X3
00472      & *V1+4*U3*Y3-2*U3*Y2+2*U4*Y3-U4*Y2+2*U1*Y3-U1*Y2)*(X2*
00473      & F3-X3*F2)*XMUL/(72*(X2*Y3-X3*Y2))
00474 !
00475       A14(IELEM) = -(3*(X2*V3+2*X2*V4+X2*V1-2*X3*V3-4*X3*V4-
00476      & 2*X3*V1+2*U3*Y3-U3*Y2+4*U4*Y3-2*U4*Y2+2*U1*Y3-U1*Y2)*
00477      & (X2*F3-X3*F2)-(4*X2*V4+2*X2*V2+2*X2*V1-2*X3*V4-X3*V2-
00478      & X3*V1+2*U4*Y3-4*U4*Y2+U2*Y3-2*U2*Y2+U1*Y3-2*U1*Y2)*(
00479      & X2+X3)*(F3+F2))*XMUL/(216*(X2*Y3-X3*Y2))
00480 !
00481       A21(IELEM) = (X2*V4+X2*V2+2*X2*V1+X3*V4+X3*V2+2*X3*V1-U4*
00482      & Y3-U4*Y2-U2*Y3-U2*Y2-2*U1*Y3-2*U1*Y2)*(X2+X3)*(F3+F2)*XMUL/
00483      & (216*(X2*Y3-X3*Y2))
00484 !
00485       A23(IELEM) = (2*X2*V3+X2*V4+X2*V2-4*X3*V3-2*X3*V4-2*X3*
00486      & V2+4*U3*Y3-2*U3*Y2+2*U4*Y3-U4*Y2+2*U2*Y3-U2*Y2)*(X2*
00487      & F3-X3*F2)*XMUL/(72*(X2*Y3-X3*Y2))
00488 !
00489       A24(IELEM) = (3*(X2*V3+2*X2*V4+X2*V2-2*X3*V3-4*X3*V4-2*
00490      & X3*V2+2*U3*Y3-U3*Y2+4*U4*Y3-2*U4*Y2+2*U2*Y3-U2*Y2)*(
00491      & X2*F3-X3*F2)+(2*X2*V4+X2*V2+X2*V1+2*X3*V4+X3*V2+X3*V1-
00492      & 2*U4*Y3-2*U4*Y2-U2*Y3-U2*Y2-U1*Y3-U1*Y2)*(X2+X3)*(F3+F2)
00493      & )*XMUL/(216*(X2*Y3-X3*Y2))
00494 !
00495       A31(IELEM) = (X2*V3+X2*V4+2*X2*V1+X3*V3+X3*V4+2*X3*V1-U3*
00496      & Y3-U3*Y2-U4*Y3-U4*Y2-2*U1*Y3-2*U1*Y2)*(X2*F3-X3*F2)*XMUL/(
00497      & 72*(X2*Y3-X3*Y2))
00498 !
00499       A32(IELEM) = (2*X2*V3+2*X2*V4+4*X2*V2-X3*V3-X3*V4-2*X3*
00500      & V2+U3*Y3-2*U3*Y2+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2)*(X2*
00501      & F3-X3*F2)*XMUL/(72*(X2*Y3-X3*Y2))
00502 !
00503       A34(IELEM) = (3*X2*V3+6*X2*V4+2*X2*V2+X2*V1-X3*V2+X3*V1-
00504      & 3*U3*Y2-6*U4*Y2+U2*Y3-2*U2*Y2-U1*Y3-U1*Y2)*(X2*F3-X3*F2
00505      & )*XMUL/(72*(X2*Y3-X3*Y2))
00506 !
00507       A41(IELEM) = -((X2*V4+X2*V2+2*X2*V1-U4*Y2-U2*Y2-2*U1*Y2)*
00508      & (X2+X3)*(F3+F2)+3*(X2*F3-X3*F2)*(X3*V3+X3*V4+2*X3*V1-U3
00509      & *Y3-U4*Y3-2*U1*Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00510 !
00511       A42(IELEM) = -(3*(X2*V3+X2*V4+2*X2*V2-X3*V3-X3*V4-2*X3*
00512      & V2+U3*Y3-U3*Y2+U4*Y3-U4*Y2+2*U2*Y3-2*U2*Y2)*(X2*F3-X3*
00513      & F2)+(X2*V4+2*X2*V2+X2*V1-U4*Y2-2*U2*Y2-U1*Y2)*(X2+X3)*(
00514      & F3+F2))*XMUL/(72*(X2*Y3-X3*Y2))
00515 !
00516       A43(IELEM) = -(2*X2*V3+X2*V4+X2*V2-X3*V2+X3*V1-2*U3*Y2-U4
00517      & *Y2+U2*Y3-U2*Y2-U1*Y3)*(X2*F3-X3*F2)*XMUL/(24*(X2*Y3-X3*Y2))
00518 !
00519 !   DIAGONAL TERMS
00520 !   THE SUM OF EACH COLUMN IS 0
00521 !
00522         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00523         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00524         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00525         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00526 !
00527         ENDDO ! IELEM
00528 !
00529         ELSE
00530 !
00531           IF (LNG.EQ.1) WRITE(LU,200) ICOORD
00532           IF (LNG.EQ.2) WRITE(LU,201) ICOORD
00533           CALL PLANTE(0)
00534           STOP
00535         ENDIF
00536 !
00537       ELSE
00538 !
00539         IF (LNG.EQ.1) WRITE(LU,300) IELMU
00540         IF (LNG.EQ.2) WRITE(LU,301) IELMU
00541         CALL PLANTE(0)
00542         STOP
00543 !
00544       ENDIF
00545 !
00546 !-----------------------------------------------------------------------
00547 !  CASE WHERE F IS OF TYPE QUASI-BUBBLE
00548 !-----------------------------------------------------------------------
00549 !
00550       ELSEIF(IELMF.EQ.12) THEN
00551 !
00552       IF (IELMU.EQ.10) THEN
00553 !
00554 !================================
00555 !  DERIVATIVE WRT X  =
00556 !================================
00557 !
00558         IF(ICOORD.EQ.1) THEN
00559 !
00560 !   LOOP ON THE ELEMENTS
00561 !
00562         DO IELEM = 1 , NELEM
00563 !
00564 !   INITIALISES THE GEOMETRICAL VARIABLES
00565 !
00566         X2 = XEL(IELEM,2)
00567         X3 = XEL(IELEM,3)
00568         Y2 = YEL(IELEM,2)
00569         Y3 = YEL(IELEM,3)
00570 !
00571         F1  =  F(IKLE1(IELEM))
00572         F2  =  F(IKLE2(IELEM)) - F1
00573         F3  =  F(IKLE3(IELEM)) - F1
00574         F4  =  F(IKLE4(IELEM)) - F1
00575 !
00576         UX  =  U(IELEM)
00577         UY  =  V(IELEM)
00578 !
00579 !   EXTRADIAGONAL TERMS
00580 !
00581       A12(IELEM) = ((UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(3*F4*Y2-F2*Y3-F2
00582      & *Y2))*XMUL/(18*(X2*Y3-X3*Y2))
00583 !
00584       A13(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(F3*Y3+F3*Y2-3*F4
00585      & *Y3))*XMUL/(18*(X2*Y3-X3*Y2))
00586 !
00587       A14(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(F3*Y3+F3*Y2-3*F4
00588      & *Y3)+(UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(3*F4*Y2-F2*Y3-F2*Y2))*XMUL/
00589      & (18*(X2*Y3-X3*Y2))
00590 !
00591       A21(IELEM) = (-(UX*Y3+UX*Y2-UY*X2-UY*X3)*(3*F4*Y2-F2*Y3-F2*Y2))
00592      & *XMUL/(18*(X2*Y3-X3*Y2))
00593 !
00594       A23(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(F3*Y3-2*F3*Y2-3
00595      & *F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2))*XMUL/(18*(X2*Y3-X3*Y2))
00596 !
00597       A24(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(F3*Y3-2*F3*Y2-3
00598      & *F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2)-(UX*Y3+UX*Y2-UY*X2-UY*X3)*(3
00599      & *F4*Y2-F2*Y3-F2*Y2))*XMUL/(18*(X2*Y3-X3*Y2))
00600 !
00601       A31(IELEM) = ((UX*Y3+UX*Y2-UY*X2-UY*X3)*(F3*Y3+F3*Y2-3*F4*Y3))
00602      & *XMUL/(18*(X2*Y3-X3*Y2))
00603 !
00604       A32(IELEM) = ((UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(F3*Y3-2*F3*Y2-3
00605      & *F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2))*XMUL/(18*(X2*Y3-X3*Y2))
00606 !
00607       A34(IELEM) = ((UX*Y3+UX*Y2-UY*X2-UY*X3)*(F3*Y3+F3*Y2-3*F4*Y3)+(
00608      & UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(F3*Y3-2*F3*Y2-3*F4*Y3+3*F4
00609      & *Y2+2*F2*Y3-F2*Y2))*XMUL/(18*(X2*Y3-X3*Y2))
00610 !
00611       A41(IELEM) = (-((UX*Y3-UY*X3)*(F3*Y3+F3*Y2-3*F4*Y3)-(UX*Y2-UY*
00612      & X2)*(3*F4*Y2-F2*Y3-F2*Y2)))*XMUL/(6*(X2*Y3-X3*Y2))
00613 !
00614       A42(IELEM) = (-((UX*Y3-UX*Y2+UY*X2-UY*X3)*(F3*Y3-2*F3*Y2-3*F4*
00615      & Y3+3*F4*Y2+2*F2*Y3-F2*Y2)-(UX*Y2-UY*X2)*(3*F4*Y2-F2*Y3-
00616      & F2*Y2)))*XMUL/(6*(X2*Y3-X3*Y2))
00617 !
00618       A43(IELEM) = (-((UX*Y3-UX*Y2+UY*X2-UY*X3)*(F3*Y3-2*F3*Y2-3*F4*
00619      & Y3+3*F4*Y2+2*F2*Y3-F2*Y2)+(UX*Y3-UY*X3)*(F3*Y3+F3*Y2-3*
00620      & F4*Y3)))*XMUL/(6*(X2*Y3-X3*Y2))
00621 !
00622 !
00623 !   DIAGONAL TERMS
00624 !   THE SUM OF THE MATRIX ROWS IS 0 (VECTOR)
00625 !
00626         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00627         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00628         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00629         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00630 !
00631         ENDDO ! IELEM
00632 !
00633         ELSEIF(ICOORD.EQ.2) THEN
00634 !
00635 !================================
00636 !  DERIVATIVE WRT Y  =
00637 !================================
00638 !
00639         DO IELEM = 1 , NELEM
00640 !
00641 !   INITIALISES THE GEOMETRICAL VARIABLES
00642 !
00643         X2  =  XEL(IELEM,2)
00644         X3  =  XEL(IELEM,3)
00645         Y2  =  YEL(IELEM,2)
00646         Y3  =  YEL(IELEM,3)
00647 !
00648         F1  =  F(IKLE1(IELEM))
00649         F2  =  F(IKLE2(IELEM)) - F1
00650         F3  =  F(IKLE3(IELEM)) - F1
00651         F4  =  F(IKLE4(IELEM)) - F1
00652 !
00653         UX  =  U(IELEM)
00654         UY  =  V(IELEM)
00655 !
00656 !   EXTRADIAGONAL TERMS
00657 !
00658       A12(IELEM) = (-(UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(3*X2*F4-X2*F2-
00659      & X3*F2))*XMUL/(18*(X2*Y3-X3*Y2))
00660 !
00661       A13(IELEM) = (-(2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(X2*F3+X3*F3-3*
00662      & X3*F4))*XMUL/(18*(X2*Y3-X3*Y2))
00663 !
00664       A14(IELEM) = (-((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(X2*F3+X3*F3-3*
00665      & X3*F4)+(UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(3*X2*F4-X2*F2-X3*F2)
00666      & ))*XMUL/(18*(X2*Y3-X3*Y2))
00667 !
00668       A21(IELEM) = ((UX*Y3+UX*Y2-UY*X2-UY*X3)*(3*X2*F4-X2*F2-X3*F2))
00669      & *XMUL/(18*(X2*Y3-X3*Y2))
00670 !
00671       A23(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(2*X2*F3-3*X2*F4
00672      & +X2*F2-X3*F3+3*X3*F4-2*X3*F2))*XMUL/(18*(X2*Y3-X3*Y2))
00673 !
00674       A24(IELEM) = ((2*UX*Y3-UX*Y2+UY*X2-2*UY*X3)*(2*X2*F3-3*X2*F4
00675      & +X2*F2-X3*F3+3*X3*F4-2*X3*F2)+(UX*Y3+UX*Y2-UY*X2-UY*X3)*(3
00676      & *X2*F4-X2*F2-X3*F2))*XMUL/(18*(X2*Y3-X3*Y2))
00677 !
00678       A31(IELEM) = (-(UX*Y3+UX*Y2-UY*X2-UY*X3)*(X2*F3+X3*F3-3*X3*F4))
00679      & *XMUL/(18*(X2*Y3-X3*Y2))
00680 !
00681       A32(IELEM) = ((UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(2*X2*F3-3*X2*F4
00682      & +X2*F2-X3*F3+3*X3*F4-2*X3*F2))*XMUL/(18*(X2*Y3-X3*Y2))
00683 !
00684       A34(IELEM) = (-((UX*Y3+UX*Y2-UY*X2-UY*X3)*(X2*F3+X3*F3-3*X3*F4)
00685      & -(UX*Y3-2*UX*Y2+2*UY*X2-UY*X3)*(2*X2*F3-3*X2*F4+X2*F2-X3*
00686      & F3+3*X3*F4-2*X3*F2)))*XMUL/(18*(X2*Y3-X3*Y2))
00687 !
00688       A41(IELEM) = ((UX*Y3-UY*X3)*(X2*F3+X3*F3-3*X3*F4)-(UX*Y2-UY*X2)
00689      & *(3*X2*F4-X2*F2-X3*F2))*XMUL/(6*(X2*Y3-X3*Y2))
00690 !
00691       A42(IELEM) = (-((UX*Y3-UX*Y2+UY*X2-UY*X3)*(2*X2*F3-3*X2*F4+X2*
00692      & F2-X3*F3+3*X3*F4-2*X3*F2)+(UX*Y2-UY*X2)*(3*X2*F4-X2*F2-
00693      & X3*F2)))*XMUL/(6*(X2*Y3-X3*Y2))
00694 !
00695       A43(IELEM) = (-((UX*Y3-UX*Y2+UY*X2-UY*X3)*(2*X2*F3-3*X2*F4+X2*
00696      & F2-X3*F3+3*X3*F4-2*X3*F2)-(UX*Y3-UY*X3)*(X2*F3+X3*F3-3*
00697      & X3*F4)))*XMUL/(6*(X2*Y3-X3*Y2))
00698 !
00699 !
00700 !   DIAGONAL TERMS
00701 !   THE SUM OF THE MATRIX ROWS IS 0 (VECTOR)
00702 !
00703         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00704         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00705         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00706         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00707 !
00708         ENDDO ! IELEM
00709 !
00710         ELSE
00711 !
00712           IF (LNG.EQ.1) WRITE(LU,200) ICOORD
00713           IF (LNG.EQ.2) WRITE(LU,200) ICOORD
00714           CALL PLANTE(0)
00715           STOP
00716 !
00717         ENDIF
00718 !
00719 !
00720       ELSEIF(IELMU.EQ.12) THEN
00721 !
00722 !================================
00723 !  DERIVATIVE WRT X  =
00724 !================================
00725 !
00726         IF(ICOORD.EQ.1) THEN
00727 !
00728 !   LOOP ON THE ELEMENTS
00729 !
00730         DO IELEM = 1 , NELEM
00731 !
00732 !   INITIALISES THE GEOMETRICAL VARIABLES
00733 !
00734         X2 = XEL(IELEM,2)
00735         X3 = XEL(IELEM,3)
00736         Y2 = YEL(IELEM,2)
00737         Y3 = YEL(IELEM,3)
00738 !
00739         F1  =  F(IKLE1(IELEM))
00740         F2  =  F(IKLE2(IELEM)) - F1
00741         F3  =  F(IKLE3(IELEM)) - F1
00742         F4  =  F(IKLE4(IELEM)) - F1
00743 !
00744         U1  =  U(IKLE1(IELEM))
00745         U2  =  U(IKLE2(IELEM))
00746         U3  =  U(IKLE3(IELEM))
00747         U4  =  U(IKLE4(IELEM))
00748         V1  =  V(IKLE1(IELEM))
00749         V2  =  V(IKLE2(IELEM))
00750         V3  =  V(IKLE3(IELEM))
00751         V4  =  V(IKLE4(IELEM))
00752 !
00753 !   EXTRADIAGONAL TERMS
00754 !
00755       A12(IELEM) = (-(2*X2*V4+4*X2*V2+2*X2*V1-X3*V4-2*X3*V2-X3
00756      & *V1+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2+U1*Y3-2*U1*Y2)*(Y3+
00757      & Y2)*F4)*XMUL/(72*(X2*Y3-X3*Y2))
00758 !
00759       A13(IELEM) = ((2*X2*V3+X2*V4+X2*V1-4*X3*V3-2*X3*V4-2*X3*
00760      & V1+4*U3*Y3-2*U3*Y2+2*U4*Y3-U4*Y2+2*U1*Y3-U1*Y2)*(F3*
00761      & Y3+F3*Y2-3*F4*Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00762 !
00763       A14(IELEM) = ((X2*V3+2*X2*V4+X2*V1-2*X3*V3-4*X3*V4-2*X3*
00764      & V1+2*U3*Y3-U3*Y2+4*U4*Y3-2*U4*Y2+2*U1*Y3-U1*Y2)*(F3*
00765      & Y3+F3*Y2-3*F4*Y3)-(4*X2*V4+2*X2*V2+2*X2*V1-2*X3*V4-
00766      & X3*V2-X3*V1+2*U4*Y3-4*U4*Y2+U2*Y3-2*U2*Y2+U1*Y3-2*U1*
00767      & Y2)*(Y3+Y2)*F4)*XMUL/(72*(X2*Y3-X3*Y2))
00768 !
00769       A21(IELEM) = (-(X2*V4+X2*V2+2*X2*V1+X3*V4+X3*V2+2*X3*V1-U4
00770      & *Y3-U4*Y2-U2*Y3-U2*Y2-2*U1*Y3-2*U1*Y2)*(Y3+Y2)*F4)*XMUL/(72
00771      & *(X2*Y3-X3*Y2))
00772 !
00773       A23(IELEM) = ((2*X2*V3+X2*V4+X2*V2-4*X3*V3-2*X3*V4-2*X3*
00774      & V2+4*U3*Y3-2*U3*Y2+2*U4*Y3-U4*Y2+2*U2*Y3-U2*Y2)*(F3*
00775      & Y3-2*F3*Y2-3*F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2))*XMUL/(72*(X2*
00776      & Y3-X3*Y2))
00777 !
00778       A24(IELEM) = ((X2*V3+2*X2*V4+X2*V2-2*X3*V3-4*X3*V4-2*X3*
00779      & V2+2*U3*Y3-U3*Y2+4*U4*Y3-2*U4*Y2+2*U2*Y3-U2*Y2)*(F3*
00780      & Y3-2*F3*Y2-3*F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2)-(2*X2*V4+
00781      & X2*V2+X2*V1+2*X3*V4+X3*V2+X3*V1-2*U4*Y3-2*U4*Y2-U2*Y3-
00782      & U2*Y2-U1*Y3-U1*Y2)*(Y3+Y2)*F4)*XMUL/(72*(X2*Y3-X3*Y2))
00783 !
00784       A31(IELEM) = (-(X2*V3+X2*V4+2*X2*V1+X3*V3+X3*V4+2*X3*V1-U3
00785      & *Y3-U3*Y2-U4*Y3-U4*Y2-2*U1*Y3-2*U1*Y2)*(F3*Y3+F3*Y2-3*
00786      & F4*Y3))*XMUL/(72*(X2*Y3-X3*Y2))
00787 !
00788       A32(IELEM) = ((2*X2*V3+2*X2*V4+4*X2*V2-X3*V3-X3*V4-2*X3*
00789      & V2+U3*Y3-2*U3*Y2+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2)*(F3*
00790      & Y3-2*F3*Y2-3*F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2))*XMUL/(72*(X2*
00791      & Y3-X3*Y2))
00792 !
00793       A34(IELEM) = ((2*X2*V3+4*X2*V4+2*X2*V2-X3*V3-2*X3*V4-X3*
00794      & V2+U3*Y3-2*U3*Y2+2*U4*Y3-4*U4*Y2+U2*Y3-2*U2*Y2)*(F3*
00795      & Y3-2*F3*Y2-3*F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2)-(X2*V3+2*
00796      & X2*V4+X2*V1+X3*V3+2*X3*V4+X3*V1-U3*Y3-U3*Y2-2*U4*Y3-2*
00797      & U4*Y2-U1*Y3-U1*Y2)*(F3*Y3+F3*Y2-3*F4*Y3))*XMUL/(72*(X2*Y3-X3
00798      & *Y2))
00799 !
00800       A41(IELEM) = ((X2*V4+X2*V2+2*X2*V1-U4*Y2-U2*Y2-2*U1*Y2)*(
00801      & Y3+Y2)*F4+(X3*V3+X3*V4+2*X3*V1-U3*Y3-U4*Y3-2*U1*Y3)*(F3
00802      & *Y3+F3*Y2-3*F4*Y3))*XMUL/(24*(X2*Y3-X3*Y2))
00803 !
00804       A42(IELEM) = (-((X2*V3+X2*V4+2*X2*V2-X3*V3-X3*V4-2*X3*V2+
00805      & U3*Y3-U3*Y2+U4*Y3-U4*Y2+2*U2*Y3-2*U2*Y2)*(F3*Y3-2*F3*
00806      & Y2-3*F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2)-(X2*V4+2*X2*V2+X2*
00807      & V1-U4*Y2-2*U2*Y2-U1*Y2)*(Y3+Y2)*F4))*XMUL/(24*(X2*Y3-X3*Y2))
00808 !
00809       A43(IELEM) = (-((2*X2*V3+X2*V4+X2*V2-2*X3*V3-X3*V4-X3*V2+
00810      & 2*U3*Y3-2*U3*Y2+U4*Y3-U4*Y2+U2*Y3-U2*Y2)*(F3*Y3-2*F3*Y2
00811      & -3*F4*Y3+3*F4*Y2+2*F2*Y3-F2*Y2)-(2*X3*V3+X3*V4+X3*V1-
00812      & 2*U3*Y3-U4*Y3-U1*Y3)*(F3*Y3+F3*Y2-3*F4*Y3)))*XMUL/(24*(X2*Y3
00813      & -X3*Y2))
00814 !
00815 !
00816 !   DIAGONAL TERMS
00817 !   THE SUM OF EACH COLUMN IS 0
00818 !
00819         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00820         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00821         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00822         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00823 !
00824         ENDDO ! IELEM
00825 !
00826         ELSEIF(ICOORD.EQ.2) THEN
00827 !
00828 !================================
00829 !  DERIVATIVE WRT Y  =
00830 !================================
00831 !
00832         DO IELEM = 1 , NELEM
00833 !
00834 !   INITIALISES THE GEOMETRICAL VARIABLES
00835 !
00836         X2  =  XEL(IELEM,2)
00837         X3  =  XEL(IELEM,3)
00838         Y2  =  YEL(IELEM,2)
00839         Y3  =  YEL(IELEM,3)
00840 !
00841         F1  =  F(IKLE1(IELEM))
00842         F2  =  F(IKLE2(IELEM)) - F1
00843         F3  =  F(IKLE3(IELEM)) - F1
00844         F4  =  F(IKLE4(IELEM)) - F1
00845 !
00846         U1  =  U(IKLE1(IELEM))
00847         U2  =  U(IKLE2(IELEM))
00848         U3  =  U(IKLE3(IELEM))
00849         U4  =  U(IKLE4(IELEM))
00850         V1  =  V(IKLE1(IELEM))
00851         V2  =  V(IKLE2(IELEM))
00852         V3  =  V(IKLE3(IELEM))
00853         V4  =  V(IKLE4(IELEM))
00854 !
00855 !   EXTRADIAGONAL TERMS
00856 !
00857       A12(IELEM) = ((2*X2*V4+4*X2*V2+2*X2*V1-X3*V4-2*X3*V2-X3*
00858      & V1+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2+U1*Y3-2*U1*Y2)*(X2+
00859      & X3)*F4)*XMUL/(72*(X2*Y3-X3*Y2))
00860 !
00861       A13(IELEM) = (-(X2*F3+X3*F3-3*X3*F4)*(2*X2*V3+X2*V4+X2*V1-
00862      & 4*X3*V3-2*X3*V4-2*X3*V1+4*U3*Y3-2*U3*Y2+2*U4*Y3-U4*
00863      & Y2+2*U1*Y3-U1*Y2))*XMUL/(72*(X2*Y3-X3*Y2))
00864 !
00865       A14(IELEM) = (-((X2*F3+X3*F3-3*X3*F4)*(X2*V3+2*X2*V4+X2*V1
00866      & -2*X3*V3-4*X3*V4-2*X3*V1+2*U3*Y3-U3*Y2+4*U4*Y3-2*U4
00867      & *Y2+2*U1*Y3-U1*Y2)-(4*X2*V4+2*X2*V2+2*X2*V1-2*X3*V4-
00868      & X3*V2-X3*V1+2*U4*Y3-4*U4*Y2+U2*Y3-2*U2*Y2+U1*Y3-2*U1*
00869      & Y2)*(X2+X3)*F4))*XMUL/(72*(X2*Y3-X3*Y2))
00870 !
00871       A21(IELEM) = ((X2*V4+X2*V2+2*X2*V1+X3*V4+X3*V2+2*X3*V1-U4*
00872      & Y3-U4*Y2-U2*Y3-U2*Y2-2*U1*Y3-2*U1*Y2)*(X2+X3)*F4)*XMUL/(72*
00873      & (X2*Y3-X3*Y2))
00874 !
00875       A23(IELEM) = ((2*X2*F3-3*X2*F4+X2*F2-X3*F3+3*X3*F4-2*X3*
00876      & F2)*(2*X2*V3+X2*V4+X2*V2-4*X3*V3-2*X3*V4-2*X3*V2+4*
00877      & U3*Y3-2*U3*Y2+2*U4*Y3-U4*Y2+2*U2*Y3-U2*Y2))*XMUL/(72*(X2*
00878      & Y3-X3*Y2))
00879 !
00880       A24(IELEM) = ((2*X2*F3-3*X2*F4+X2*F2-X3*F3+3*X3*F4-2*X3*
00881      & F2)*(X2*V3+2*X2*V4+X2*V2-2*X3*V3-4*X3*V4-2*X3*V2+2*
00882      & U3*Y3-U3*Y2+4*U4*Y3-2*U4*Y2+2*U2*Y3-U2*Y2)+(2*X2*V4+
00883      & X2*V2+X2*V1+2*X3*V4+X3*V2+X3*V1-2*U4*Y3-2*U4*Y2-U2*Y3-
00884      & U2*Y2-U1*Y3-U1*Y2)*(X2+X3)*F4)*XMUL/(72*(X2*Y3-X3*Y2))
00885 !
00886       A31(IELEM) = ((X2*F3+X3*F3-3*X3*F4)*(X2*V3+X2*V4+2*X2*V1+
00887      & X3*V3+X3*V4+2*X3*V1-U3*Y3-U3*Y2-U4*Y3-U4*Y2-2*U1*Y3-2*
00888      & U1*Y2))*XMUL/(72*(X2*Y3-X3*Y2))
00889 !
00890       A32(IELEM) = ((2*X2*F3-3*X2*F4+X2*F2-X3*F3+3*X3*F4-2*X3*
00891      & F2)*(2*X2*V3+2*X2*V4+4*X2*V2-X3*V3-X3*V4-2*X3*V2+U3*
00892      & Y3-2*U3*Y2+U4*Y3-2*U4*Y2+2*U2*Y3-4*U2*Y2))*XMUL/(72*(X2*
00893      & Y3-X3*Y2))
00894 !
00895       A34(IELEM) = ((2*X2*F3-3*X2*F4+X2*F2-X3*F3+3*X3*F4-2*X3*
00896      & F2)*(2*X2*V3+4*X2*V4+2*X2*V2-X3*V3-2*X3*V4-X3*V2+U3*
00897      & Y3-2*U3*Y2+2*U4*Y3-4*U4*Y2+U2*Y3-2*U2*Y2)+(X2*F3+X3*
00898      & F3-3*X3*F4)*(X2*V3+2*X2*V4+X2*V1+X3*V3+2*X3*V4+X3*V1-
00899      & U3*Y3-U3*Y2-2*U4*Y3-2*U4*Y2-U1*Y3-U1*Y2))*XMUL/(72*(X2*Y3-
00900      & X3*Y2))
00901 !
00902       A41(IELEM) = (-((X2*F3+X3*F3-3*X3*F4)*(X3*V3+X3*V4+2*X3*V1
00903      & -U3*Y3-U4*Y3-2*U1*Y3)+(X2*V4+X2*V2+2*X2*V1-U4*Y2-U2*Y2-
00904      & 2*U1*Y2)*(X2+X3)*F4))*XMUL/(24*(X2*Y3-X3*Y2))
00905 !
00906       A42(IELEM) = (-((2*X2*F3-3*X2*F4+X2*F2-X3*F3+3*X3*F4-2*
00907      & X3*F2)*(X2*V3+X2*V4+2*X2*V2-X3*V3-X3*V4-2*X3*V2+U3*Y3-
00908      & U3*Y2+U4*Y3-U4*Y2+2*U2*Y3-2*U2*Y2)+(X2*V4+2*X2*V2+X2*
00909      & V1-U4*Y2-2*U2*Y2-U1*Y2)*(X2+X3)*F4))*XMUL/(24*(X2*Y3-X3*Y2))
00910 !
00911       A43(IELEM) = (-((2*X2*F3-3*X2*F4+X2*F2-X3*F3+3*X3*F4-2*
00912      & X3*F2)*(2*X2*V3+X2*V4+X2*V2-2*X3*V3-X3*V4-X3*V2+2*U3*
00913      & Y3-2*U3*Y2+U4*Y3-U4*Y2+U2*Y3-U2*Y2)+(X2*F3+X3*F3-3*X3*
00914      & F4)*(2*X3*V3+X3*V4+X3*V1-2*U3*Y3-U4*Y3-U1*Y3)))*XMUL/(24*(
00915      & X2*Y3-X3*Y2))
00916 !
00917 !
00918 !   DIAGONAL TERMS
00919 !   THE SUM OF EACH COLUMN IS 0
00920 !
00921         A11(IELEM) = - A21(IELEM)  - A31(IELEM) - A41(IELEM)
00922         A22(IELEM) = - A12(IELEM)  - A32(IELEM) - A42(IELEM)
00923         A33(IELEM) = - A13(IELEM)  - A23(IELEM) - A43(IELEM)
00924         A44(IELEM) = - A14(IELEM)  - A24(IELEM) - A34(IELEM)
00925 !
00926         ENDDO ! IELEM
00927 !
00928         ELSE
00929 !
00930           IF (LNG.EQ.1) WRITE(LU,200) ICOORD
00931           IF (LNG.EQ.2) WRITE(LU,201) ICOORD
00932           CALL PLANTE(0)
00933           STOP
00934         ENDIF
00935 !
00936       ELSE
00937 !
00938         IF (LNG.EQ.1) WRITE(LU,300) IELMU
00939         IF (LNG.EQ.2) WRITE(LU,301) IELMU
00940         CALL PLANTE(0)
00941         STOP
00942       ENDIF
00943 !
00944 !-----------------------------------------------------------------------
00945 !
00946       ELSE
00947         IF (LNG.EQ.1) WRITE(LU,100) IELMF
00948         IF (LNG.EQ.2) WRITE(LU,101) IELMF
00949 100     FORMAT(1X,'MT12BB (BIEF) :',/,
00950      &         1X,'DISCRETISATION DE F : ',1I6,' NON PREVUE')
00951 101     FORMAT(1X,'MT12BB (BIEF) :',/,
00952      &         1X,'DISCRETIZATION OF F : ',1I6,' NOT AVAILABLE')
00953         CALL PLANTE(0)
00954         STOP
00955       ENDIF
00956 !
00957 200   FORMAT(1X,'MT12BB (BIEF) : COMPOSANTE IMPOSSIBLE ',
00958      &          1I6,' VERIFIER ICOORD')
00959 201   FORMAT(1X,'MT12BB (BIEF) : IMPOSSIBLE COMPONENT ',
00960      &          1I6,' CHECK ICOORD')
00961 !
00962 300    FORMAT(1X,'MT12BB (BIEF) :',/,
00963      &        1X,'DISCRETISATION DE U : ',1I6,' NON PREVUE')
00964 301    FORMAT(1X,'MT12BB (BIEF) :',/,
00965      &        1X,'DISCRETIZATION OF U : ',1I6,' NOT AVAILABLE')
00966 !
00967 !-----------------------------------------------------------------------
00968 !
00969       RETURN
00970       END

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