Télécharger trj602.eso

Retour à la liste

Numérotation des lignes :

trj602
  1. C TRJ602 SOURCE CHAT 05/01/13 03:48:14 5004
  2. SUBROUTINE TRJ602(XNOEU,X,G,IER)
  3. C
  4. C
  5. C
  6. CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
  7. C
  8. C CALCUL DES COORDONNEES DE REFERENCES DANS UN TRI6
  9. C XNOEU COORDONNEES DES SOMMETS
  10. C X REELLES
  11. C G REFERENCES
  12. C IER INDICE D'ERREUR
  13. C
  14. CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
  15. C
  16. C
  17. IMPLICIT INTEGER(I-N)
  18. IMPLICIT REAL*8 (A-H,O-Z)
  19. C
  20. DIMENSION XNOEU(2,6),X(2),XN(6),G(2),DX(2),DG(2)
  21. DIMENSION Y(2),D1XN(6),D2XN(6),A(2,2),B(2,2)
  22.  
  23. -INC PPARAM
  24. -INC CCOPTIO
  25. C
  26. C
  27. NOEL=6
  28. C IDIM=2
  29. C
  30. C
  31. G(1)=1.D0/3.D0
  32. G(2)=1.D0/3.D0
  33. C
  34. N1=15
  35. DO 10 K=1,N1
  36. C
  37. XN(1)=-(1.D0-G(1)-G(2))*(1.D0-2.D0*(1.D0-G(1)-G(2)))
  38. XN(2)= 4.D0*G(1)*(1.D0-G(1)-G(2))
  39. XN(3)=-G(1)*(1.D0-2.D0*G(1))
  40. XN(4)= 4.D0*G(1)*G(2)
  41. XN(5)=-G(2)*(1.D0-2.D0*G(2))
  42. XN(6)= 4.D0*G(2)*(1.D0-G(1)-G(2))
  43. C
  44. Y(1)=0.D0
  45. Y(2)=0.D0
  46. DO 1 I=1,NOEL
  47. Y(1)=XNOEU(1,I)*XN(I)+Y(1)
  48. Y(2)=XNOEU(2,I)*XN(I)+Y(2)
  49. 1 CONTINUE
  50. C
  51. DX(1)=X(1)-Y(1)
  52. DX(2)=X(2)-Y(2)
  53. C
  54. D1XN(1)=1.D0-4.D0*(1.D0-G(1)-G(2))
  55. D1XN(2)=4.D0*(1.D0-2.D0*G(1)-G(2))
  56. D1XN(3)=-1.D0+4.D0*G(1)
  57. D1XN(4)= 4.D0*G(2)
  58. D1XN(5)=0.D0
  59. D1XN(6)=-4.D0*G(2)
  60. C
  61. D2XN(1)=1.D0-4.D0*(1.D0-G(1)-G(2))
  62. D2XN(2)=-4.D0*G(1)
  63. D2XN(3)=0.D0
  64. D2XN(4)=4.D0*G(1)
  65. D2XN(5)=-1.D0+4.D0*G(2)
  66. D2XN(6)=4.D0*(1.D0-G(1)-2.D0*G(2))
  67. C
  68. C
  69. A(1,1)=0.D0
  70. A(1,2)=0.D0
  71. A(2,1)=0.D0
  72. A(2,2)=0.D0
  73. C
  74. DO 3 I=1,NOEL
  75. A(1,1)=D1XN(I)*XNOEU(1,I)+A(1,1)
  76. A(1,2)=D1XN(I)*XNOEU(2,I)+A(1,2)
  77. A(2,1)=D2XN(I)*XNOEU(1,I)+A(2,1)
  78. A(2,2)=D2XN(I)*XNOEU(2,I)+A(2,2)
  79. 3 CONTINUE
  80. C
  81. DEL=A(1,1)*A(2,2)-A(2,1)*A(1,2)
  82. C
  83. B(1,1)=1.D0/DEL*A(2,2)
  84. B(2,2)=1.D0/DEL*A(1,1)
  85. B(1,2)=-1.D0/DEL*A(2,1)
  86. B(2,1)=-1.D0/DEL*A(1,2)
  87. C
  88. DG(1)=B(1,1)*DX(1)+B(1,2)*DX(2)
  89. DG(2)=B(2,1)*DX(1)+B(2,2)*DX(2)
  90. C
  91. G(1)=DG(1)+G(1)
  92. G(2)=DG(2)+G(2)
  93. C
  94. DA1=ABS(DG(1))
  95. DA2=ABS(DG(2))
  96. IF(DA1.LE.0.0001.AND.DA2.LE.0.0001)GO TO 51
  97. C
  98. C
  99. 10 CONTINUE
  100. C
  101. C IF(K.GE.N1)WRITE(6,101)X(1),X(2),DA1,DA2
  102. MOTERR(1:8)='TRJ602 '
  103. REAERR(1)=X(1)
  104. REAERR(2)=X(2)
  105. REAERR(3)=0.
  106. C CALL ERREUR(-300)
  107. IER=-300
  108. C
  109. 51 CONTINUE
  110. C
  111. C G(1)=XG1
  112. C G(2)=YG1
  113. C
  114. RETURN
  115. 101 FORMAT(//,3X,' PB CONVERGENCE TRJ602 AU POINT SITUE EN '
  116. *,2(1PE12.5),/,3X,' CONVERGENCE RELATIVE ',2(1PE12.5))
  117. C
  118. END
  119.  
  120.  
  121.  

© Cast3M 2003 - Tous droits réservés.
Mentions légales