Télécharger prija2.eso

Retour à la liste

Numérotation des lignes :

prija2
  1. C PRIJA2 SOURCE OF166741 24/12/13 21:17:12 12097
  2. SUBROUTINE PRIJA2(MELEMC,MLMCON,MLMPRI,IRN,IVN,IPN,IGAMN,IJACO)
  3. C
  4. C************************************************************************
  5. C
  6. C PROJET : CASTEM 2000
  7. C
  8. C NOM : PRIJA2
  9. C
  10. C DESCRIPTION : Voir PRIJA1
  11. C Cas deux dimensions, gaz "calorically perfect"
  12. C
  13. C LANGAGE : FORTRAN 77 + ESOPE 2000 (avec estensions CISI)
  14. C
  15. C AUTEUR : A. BECCANTINI, DM2S/SFME/LTMF
  16. C
  17. C************************************************************************
  18. C
  19. C ENTREES
  20. C
  21. C MELEMC : SPG des CHPOINTs
  22. C
  23. C MLMPRI : liste des inconnues primitives (P,v,T)
  24. C
  25. C MLMCON : liste des inconnues conservatives (rho, rhov, rhoet)
  26. C
  27. C IRN : CHPOINT CENTRE contenant la densité
  28. C
  29. C IVN : CHPOINT CENTRE contenant la vitesse
  30. C
  31. C IPN : CHPOINT CENTRE contenant la pression
  32. C
  33. C IGAM : CHPOINT CENTRE contenant le gamma
  34. C
  35. C SORTIES
  36. C
  37. C IJACO : pointeur de la MATRIK jacobienne
  38. C
  39. C************************************************************************
  40. C
  41. C HISTORIQUE (Anomalies et modifications éventuelles)
  42. C
  43. C HISTORIQUE : crée le 29.05.02
  44. C
  45. C************************************************************************
  46. C
  47. C
  48. C N.B.: On suppose qu'on a déjà controllé RO, P > 0
  49. C GAMMA \in (1,3)
  50. C Si non il faut le faire!!!
  51. C
  52. C************************************************************************
  53. C
  54. IMPLICIT INTEGER(I-N)
  55. INTEGER IRN, IVN, IPN, IGAMN, IJACO, IGEOM, ICEN
  56. & , MP, NP, NBEL, NBME, NBSOUS
  57. & , NRIGE, NMATRI, NKID, NKMT
  58. C
  59. REAL*8 RHO,UX, UY, UZ, GAMMA
  60. CHARACTER*8 TYPE
  61. C
  62. C**** LES INCLUDES
  63. C
  64.  
  65. -INC PPARAM
  66. -INC CCOPTIO
  67. -INC SMCHPOI
  68. -INC SMELEME
  69. -INC SMLMOTS
  70. -INC SMLENTI
  71. POINTEUR MPVN.MPOVAL, MPRN.MPOVAL, MPGAM.MPOVAL
  72. POINTEUR MELEMC.MELEME
  73. POINTEUR RR.IZAFM, RUX.IZAFM, RUY.IZAFM, RUZ.IZAFM, RP.IZAFM,
  74. & UXR.IZAFM, UXUX.IZAFM, UXUY.IZAFM, UXUZ.IZAFM,
  75. & UXP.IZAFM,
  76. & UYR.IZAFM, UYUX.IZAFM, UYUY.IZAFM, UYUZ.IZAFM,
  77. & UYP.IZAFM,
  78. & UZR.IZAFM, UZUX.IZAFM, UZUY.IZAFM, UZUZ.IZAFM,
  79. & UZP.IZAFM,
  80. & RETR.IZAFM, RETUX.IZAFM, RETUY.IZAFM, RETUZ.IZAFM,
  81. & RETP.IZAFM
  82. POINTEUR MLMPRI.MLMOTS, MLMCON.MLMOTS
  83. C
  84. CALL LICHT(IVN,MPVN,TYPE,IGEOM)
  85. CALL LICHT(IRN,MPRN,TYPE,IGEOM)
  86. CALL LICHT(IGAMN,MPGAM,TYPE,IGEOM)
  87. C
  88. C SEGACT MPVN*MOD
  89. C SEGACT MPPN*MOD
  90. C SEGACT MPRN*MOD
  91. C
  92. C**** Maillage des inconnues primales = Maillage des inconnues primales
  93. C = MELEMC
  94. C
  95. C
  96. NRIGE = 7
  97. NMATRI = 1
  98. NKID = 9
  99. NKMT = 7
  100. C
  101. SEGINI MATRIK
  102. IJACO = MATRIK
  103. MATRIK.IRIGEL(1,1) = MELEMC
  104. MATRIK.IRIGEL(2,1) = MELEMC
  105. C
  106. C**** Matrice non symetrique
  107. C
  108. MATRIK.IRIGEL(7,1) = 2
  109. C
  110. NBME = 25
  111. NBSOUS = 1
  112. SEGINI IMATRI
  113. MATRIK.IRIGEL(4,1) = IMATRI
  114. C
  115. SEGACT MLMPRI
  116. C-----------------------------------------------
  117. IMATRI.LISPRI(1) = MLMPRI.MOTS(1)
  118. IMATRI.LISPRI(2) = MLMPRI.MOTS(2)
  119. IMATRI.LISPRI(3) = MLMPRI.MOTS(3)
  120. IMATRI.LISPRI(4) = MLMPRI.MOTS(4)
  121. IMATRI.LISPRI(5) = MLMPRI.MOTS(5)
  122. C-----------------------------------------------
  123. IMATRI.LISPRI(6) = MLMPRI.MOTS(1)
  124. IMATRI.LISPRI(7) = MLMPRI.MOTS(2)
  125. IMATRI.LISPRI(8) = MLMPRI.MOTS(3)
  126. IMATRI.LISPRI(9) = MLMPRI.MOTS(4)
  127. IMATRI.LISPRI(10) = MLMPRI.MOTS(5)
  128. C-----------------------------------------------
  129. IMATRI.LISPRI(11) = MLMPRI.MOTS(1)
  130. IMATRI.LISPRI(12) = MLMPRI.MOTS(2)
  131. IMATRI.LISPRI(13) = MLMPRI.MOTS(3)
  132. IMATRI.LISPRI(14) = MLMPRI.MOTS(4)
  133. IMATRI.LISPRI(15) = MLMPRI.MOTS(5)
  134. C-----------------------------------------------
  135. IMATRI.LISPRI(16) = MLMPRI.MOTS(1)
  136. IMATRI.LISPRI(17) = MLMPRI.MOTS(2)
  137. IMATRI.LISPRI(18) = MLMPRI.MOTS(3)
  138. IMATRI.LISPRI(19) = MLMPRI.MOTS(4)
  139. IMATRI.LISPRI(20) = MLMPRI.MOTS(5)
  140. C-----------------------------------------------
  141. IMATRI.LISPRI(21) = MLMPRI.MOTS(1)
  142. IMATRI.LISPRI(22) = MLMPRI.MOTS(2)
  143. IMATRI.LISPRI(23) = MLMPRI.MOTS(3)
  144. IMATRI.LISPRI(24) = MLMPRI.MOTS(4)
  145. IMATRI.LISPRI(25) = MLMPRI.MOTS(5)
  146. C-----------------------------------------------
  147. SEGDES MLMPRI
  148. C
  149. SEGACT MLMCON
  150. C-----------------------------------------------
  151. IMATRI.LISDUA(1) = MLMCON.MOTS(1)
  152. IMATRI.LISDUA(2) = MLMCON.MOTS(1)
  153. IMATRI.LISDUA(3) = MLMCON.MOTS(1)
  154. IMATRI.LISDUA(4) = MLMCON.MOTS(1)
  155. IMATRI.LISDUA(5) = MLMCON.MOTS(1)
  156. C-----------------------------------------------
  157. IMATRI.LISDUA(6) = MLMCON.MOTS(2)
  158. IMATRI.LISDUA(7) = MLMCON.MOTS(2)
  159. IMATRI.LISDUA(8) = MLMCON.MOTS(2)
  160. IMATRI.LISDUA(9) = MLMCON.MOTS(2)
  161. IMATRI.LISDUA(10) = MLMCON.MOTS(2)
  162. C-----------------------------------------------
  163. IMATRI.LISDUA(11) = MLMCON.MOTS(3)
  164. IMATRI.LISDUA(12) = MLMCON.MOTS(3)
  165. IMATRI.LISDUA(13) = MLMCON.MOTS(3)
  166. IMATRI.LISDUA(14) = MLMCON.MOTS(3)
  167. IMATRI.LISDUA(15) = MLMCON.MOTS(3)
  168. C-----------------------------------------------
  169. IMATRI.LISDUA(16) = MLMCON.MOTS(4)
  170. IMATRI.LISDUA(17) = MLMCON.MOTS(4)
  171. IMATRI.LISDUA(18) = MLMCON.MOTS(4)
  172. IMATRI.LISDUA(19) = MLMCON.MOTS(4)
  173. IMATRI.LISDUA(20) = MLMCON.MOTS(4)
  174. C-----------------------------------------------
  175. IMATRI.LISDUA(21) = MLMCON.MOTS(5)
  176. IMATRI.LISDUA(22) = MLMCON.MOTS(5)
  177. IMATRI.LISDUA(23) = MLMCON.MOTS(5)
  178. IMATRI.LISDUA(24) = MLMCON.MOTS(5)
  179. IMATRI.LISDUA(25) = MLMCON.MOTS(5)
  180. C-----------------------------------------------
  181. SEGDES MLMCON
  182. C
  183. SEGACT MELEMC
  184. NBEL = MELEMC.NUM(/2)
  185. SEGDES MELEMC
  186. NBSOUS = 1
  187. NP = 1
  188. MP = 1
  189. SEGINI RR , RUX , RUY , RUZ, RP ,
  190. & UXR , UXUX , UXUY , UXUZ, UXP ,
  191. & UYR , UYUX , UYUY , UYUZ, UYP ,
  192. & UZR , UZUX , UZUY , UZUZ, UZP ,
  193. & RETR , RETUX , RETUY , RETUZ, RETP
  194. C
  195. C**** Duale = IMATRI.LISDUA(1) = 'RN'
  196. C Primale = IMATRI.LISPRI(4) = 'P'
  197. C -> IMATRI.LIZAFM(1,4) = RP
  198. C
  199. C-----------------------------------------------
  200. IMATRI.LIZAFM(1,1) = RR
  201. IMATRI.LIZAFM(1,2) = RUX
  202. IMATRI.LIZAFM(1,3) = RUY
  203. IMATRI.LIZAFM(1,4) = RUZ
  204. IMATRI.LIZAFM(1,5) = RP
  205. C-----------------------------------------------
  206. IMATRI.LIZAFM(1,6) = UXR
  207. IMATRI.LIZAFM(1,7) = UXUX
  208. IMATRI.LIZAFM(1,8) = UXUY
  209. IMATRI.LIZAFM(1,9) = UXUZ
  210. IMATRI.LIZAFM(1,10) = UXP
  211. C-----------------------------------------------
  212. IMATRI.LIZAFM(1,11) = UYR
  213. IMATRI.LIZAFM(1,12) = UYUX
  214. IMATRI.LIZAFM(1,13) = UYUY
  215. IMATRI.LIZAFM(1,14) = UYUZ
  216. IMATRI.LIZAFM(1,15) = UYP
  217. C------------------------------------------------
  218. IMATRI.LIZAFM(1,16) = UZR
  219. IMATRI.LIZAFM(1,17) = UZUX
  220. IMATRI.LIZAFM(1,18) = UZUY
  221. IMATRI.LIZAFM(1,19) = UZUZ
  222. IMATRI.LIZAFM(1,20) = UZP
  223. C-----------------------------------------------
  224. IMATRI.LIZAFM(1,21) = RETR
  225. IMATRI.LIZAFM(1,22) = RETUX
  226. IMATRI.LIZAFM(1,23) = RETUY
  227. IMATRI.LIZAFM(1,24) = RETUZ
  228. IMATRI.LIZAFM(1,25) = RETP
  229. C-----------------------------------------------
  230. C
  231. DO ICEN = 1, NBEL, 1
  232. RHO=MPRN.VPOCHA(ICEN,1)
  233. UX=MPVN.VPOCHA(ICEN,1)
  234. UY=MPVN.VPOCHA(ICEN,2)
  235. UZ=MPVN.VPOCHA(ICEN,3)
  236. GAMMA=MPGAM.VPOCHA(ICEN,1)
  237. C
  238. C********AB.AM(IFAC,IPRIM,IDUAL)
  239. C A = nom de l'inconnu duale (Ro,rUX,rUY,RET)
  240. C B = nom de l'inconnu primale (Ro,UX,UY,P)
  241. C
  242. C******* Dual RN
  243. C
  244. RR.AM(ICEN,1,1) = 1.0D0
  245. RUX.AM(ICEN,1,1) = 0.0D0
  246. RUY.AM(ICEN,1,1) = 0.0D0
  247. RUZ.AM(ICEN,1,1) = 0.0D0
  248. RP.AM(ICEN,1,1) = 0.0D0
  249. C
  250. C******* Dual RUXN
  251. C
  252. UXR.AM(ICEN,1,1) = UX
  253. UXUX.AM(ICEN,1,1) = RHO
  254. UXUY.AM(ICEN,1,1) = 0.0D0
  255. UXUZ.AM(ICEN,1,1) = 0.0D0
  256. UXP.AM(ICEN,1,1) = 0.0D0
  257. C
  258. C******* Dual RUYN
  259. C
  260. UYR.AM(ICEN,1,1) = UY
  261. UYUX.AM(ICEN,1,1) = 0.0D0
  262. UYUY.AM(ICEN,1,1) = RHO
  263. UYUZ.AM(ICEN,1,1) = 0.0D0
  264. UYP.AM(ICEN,1,1) = 0.0D0
  265. C
  266. C******* Dual RUZN
  267. C
  268. UZR.AM(ICEN,1,1) = UZ
  269. UZUX.AM(ICEN,1,1) = 0.0D0
  270. UZUY.AM(ICEN,1,1) = 0.0D0
  271. UZUZ.AM(ICEN,1,1) = RHO
  272. UZP.AM(ICEN,1,1) = 0.0D0
  273. C
  274. C********Dual RETN
  275. C
  276. RETR.AM(ICEN,1,1) = 0.5D0*((UX*UX)+(UY*UY)+(UZ*UZ))
  277. RETUX.AM(ICEN,1,1) = RHO*UX
  278. RETUY.AM(ICEN,1,1) = RHO*UY
  279. RETUZ.AM(ICEN,1,1) = RHO*UZ
  280. RETP.AM(ICEN,1,1) = 1.0D0/(GAMMA - 1.0D0)
  281. C
  282. ENDDO
  283. C
  284. SEGDES MPVN
  285. SEGDES MPRN
  286. SEGDES MPGAM
  287. C
  288. SEGDES MATRIK
  289. SEGDES IMATRI
  290. C
  291. SEGINI RR , RUX , RUY , RUZ, RP ,
  292. & UXR , UXUX , UXUY , UXUZ, UXP ,
  293. & UYR , UYUX , UYUY , UYUZ, UYP ,
  294. & UZR , UZUX , UZUY , UZUZ, UZP ,
  295. & RETR , RETUX , RETUY , RETUZ, RETP
  296. C
  297. RETURN
  298. END
  299.  
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  

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