Télécharger cli152.eso

Retour à la liste

Numérotation des lignes :

cli152
  1. C CLI152 SOURCE OF166741 24/12/13 21:15:20 12097
  2. SUBROUTINE CLI152(MELEMF,MELEMC,MELECB,MELEFC,MELRES,INORM,ICHPVO,
  3. & ICHPSU,IROC,IVITC,IPC,IGAMC,ICHLIM,ILIINC,ILIINP,IJAC,IJACO)
  4. C************************************************************************
  5. C
  6. C PROJET : CASTEM 2000
  7. C
  8. C NOM : CLI152
  9. C
  10. C DESCRIPTION : Subroutine appellée par CLIM11
  11. C
  12. C LANGAGE : FORTRAN 77 + ESOPE 2000 (avec estensions CISI)
  13. C
  14. C AUTEUR : A. BECCANTINI, DRN/DMT/SEMT/LTMF
  15. C
  16. C************************************************************************
  17. C
  18. C APPELES (Calcul) :
  19. C
  20. C************************************************************************
  21. C
  22. C HISTORIQUE (Anomalies et modifications éventuelles)
  23. C
  24. C HISTORIQUE :
  25. C
  26. C************************************************************************
  27. C
  28. IMPLICIT INTEGER(I-N)
  29. -INC PPARAM
  30. -INC CCOPTIO
  31. -INC SMLMOTS
  32. -INC SMELEME
  33. POINTEUR MELEFC.MELEME
  34. -INC SMLENTI
  35. POINTEUR MLEMC.MLENTI, MLEMCB.MLENTI,MLEMF.MLENTI
  36. -INC SMCHPOI
  37. POINTEUR MPNORM.MPOVAL, MPVOL.MPOVAL, MPSURF.MPOVAL, MPRC.MPOVAL,
  38. & MPVC.MPOVAL, MPPC.MPOVAL, MPGAMC.MPOVAL, MPLIM.MPOVAL
  39. POINTEUR RR.IZAFM, RUX.IZAFM, RUY.IZAFM, RRET.IZAFM,
  40. & UXR.IZAFM, UXUX.IZAFM, UXUY.IZAFM, UXRET.IZAFM,
  41. & UYR.IZAFM, UYUX.IZAFM, UYUY.IZAFM, UYRET.IZAFM,
  42. & RETR.IZAFM, RETUX.IZAFM, RETUY.IZAFM, RETRET.IZAFM
  43. C
  44. INTEGER MELEMF,MELEMC,MELECB,INORM,ICHPVO,ICHPSU, IROC,IVITC,IPC
  45. & ,IGAMC,ICHLIM,ICEL,NFAC,IFAC,MELRES,IJACO
  46. & ,NGF,NGC,NLF,NLC,NLCB
  47. & ,ILIINC,ILIINP,IJAC
  48. & ,MP, NBEL, NBME, NBSOUS, NKID, NKMT, NMATRI, NP, NRIGE
  49. REAL*8 VOLU,SURF,RC,PC,UXC,UYC,GAMC,CNX,CNY,CTX,CTY,PF
  50. & ,VECG(4),VECD(4),DFDUG(4,4),DFDUD(4,4)
  51. & ,NVEC(2),TVEC(2)
  52. & ,DRORO,DROUX,DROUY,DROP
  53. & ,DUXRO,DUXUX,DUXUY,DUXP
  54. & ,DUYRO,DUYUX,DUYUY,DUYP
  55. & ,DPRO,DPUX,DPUY,DPP
  56. & ,COEF1,COEF2,COEF3,GM1,COEF
  57. CHARACTER*(8) TYPE
  58. C
  59. C
  60. C**** KRIPAD pour la correspondance global/local
  61. C
  62. CALL KRIPAD(MELEMC,MLEMC)
  63. C SEGINI MLEMC
  64. CALL KRIPAD(MELECB,MLEMCB)
  65. C SEGINI MLEMCB
  66. CALL KRIPAD(MELEMF,MLEMF)
  67. C SEGINI MLEMF
  68. C
  69. C**** CHPOINTs de la table DOMAINE
  70. C
  71. CALL LICHT(INORM,MPNORM,TYPE,ICEL)
  72. CALL LICHT(ICHPVO,MPVOL,TYPE,ICEL)
  73. CALL LICHT(ICHPSU,MPSURF,TYPE,ICEL)
  74. C
  75. C**** LICHT active les MPOVALs en *MOD
  76. C
  77. C SEGACT MPNORM*MOD
  78. C SEGACT MPOVSU*MOD
  79. C SEGACT MPOVOL*MOD
  80. C
  81. C
  82. C**** CHPOINTs des variables
  83. C
  84. CALL LICHT(IROC,MPRC,TYPE,ICEL)
  85. CALL LICHT(IVITC,MPVC,TYPE,ICEL)
  86. CALL LICHT(IPC,MPPC,TYPE,ICEL)
  87. CALL LICHT(IGAMC,MPGAMC,TYPE,ICEL)
  88. CALL LICHT(ICHLIM,MPLIM,TYPE,ICEL)
  89. C
  90. C SEGACT *MOD
  91. C SEGACT *MOD
  92. C SEGACT *MOD
  93. C SEGACT *MOD
  94. C SEGACT *MOD
  95. C
  96. C
  97. C**** Boucle sur le face pour le calcul des invariants de
  98. C Riemann et du flux
  99. C
  100. SEGACT MELEFC
  101. NFAC=MELEFC.NUM(/2)
  102. C
  103. C**** Objet MATRIK
  104. C
  105. NRIGE = 7
  106. NMATRI = 1
  107. NKID = 9
  108. NKMT = 7
  109. C
  110. SEGINI MATRIK
  111. IJACO = MATRIK
  112. MATRIK.IRIGEL(1,1) = MELRES
  113. MATRIK.IRIGEL(2,1) = MELRES
  114. C
  115. C**** Matrice non symetrique
  116. C
  117. MATRIK.IRIGEL(7,1) = 2
  118. C
  119. NBME = 16
  120. NBSOUS = 1
  121. SEGINI IMATRI
  122. IF(IJAC.EQ.1)THEN
  123. MLMOTS=ILIINC
  124. ELSEIF(IJAC.EQ.2)THEN
  125. MLMOTS=ILIINP
  126. ENDIF
  127. SEGACT MLMOTS
  128. MATRIK.IRIGEL(4,1) = IMATRI
  129. C
  130. IMATRI.LISPRI(1) = MLMOTS.MOTS(1)
  131. IMATRI.LISPRI(2) = MLMOTS.MOTS(2)
  132. IMATRI.LISPRI(3) = MLMOTS.MOTS(3)
  133. IMATRI.LISPRI(4) = MLMOTS.MOTS(4)
  134. IMATRI.LISPRI(5) = MLMOTS.MOTS(1)
  135. IMATRI.LISPRI(6) = MLMOTS.MOTS(2)
  136. IMATRI.LISPRI(7) = MLMOTS.MOTS(3)
  137. IMATRI.LISPRI(8) = MLMOTS.MOTS(4)
  138. IMATRI.LISPRI(9) = MLMOTS.MOTS(1)
  139. IMATRI.LISPRI(10) = MLMOTS.MOTS(2)
  140. IMATRI.LISPRI(11) = MLMOTS.MOTS(3)
  141. IMATRI.LISPRI(12) = MLMOTS.MOTS(4)
  142. IMATRI.LISPRI(13) = MLMOTS.MOTS(1)
  143. IMATRI.LISPRI(14) = MLMOTS.MOTS(2)
  144. IMATRI.LISPRI(15) = MLMOTS.MOTS(3)
  145. IMATRI.LISPRI(16) = MLMOTS.MOTS(4)
  146. C
  147. SEGDES MLMOTS
  148. MLMOTS=ILIINC
  149. SEGACT MLMOTS
  150. C
  151. IMATRI.LISDUA(1) = MLMOTS.MOTS(1)
  152. IMATRI.LISDUA(2) = MLMOTS.MOTS(1)
  153. IMATRI.LISDUA(3) = MLMOTS.MOTS(1)
  154. IMATRI.LISDUA(4) = MLMOTS.MOTS(1)
  155. IMATRI.LISDUA(5) = MLMOTS.MOTS(2)
  156. IMATRI.LISDUA(6) = MLMOTS.MOTS(2)
  157. IMATRI.LISDUA(7) = MLMOTS.MOTS(2)
  158. IMATRI.LISDUA(8) = MLMOTS.MOTS(2)
  159. IMATRI.LISDUA(9) = MLMOTS.MOTS(3)
  160. IMATRI.LISDUA(10) = MLMOTS.MOTS(3)
  161. IMATRI.LISDUA(11) = MLMOTS.MOTS(3)
  162. IMATRI.LISDUA(12) = MLMOTS.MOTS(3)
  163. IMATRI.LISDUA(13) = MLMOTS.MOTS(4)
  164. IMATRI.LISDUA(14) = MLMOTS.MOTS(4)
  165. IMATRI.LISDUA(15) = MLMOTS.MOTS(4)
  166. IMATRI.LISDUA(16) = MLMOTS.MOTS(4)
  167. C
  168. SEGDES MLMOTS
  169. NBEL = NFAC
  170. NBSOUS = 1
  171. NP = 1
  172. MP = 1
  173. SEGINI RR , RUX , RUY , RRET ,
  174. & UXR , UXUX , UXUY , UXRET ,
  175. & UYR , UYUX , UYUY , UYRET ,
  176. & RETR , RETUX , RETUY , RETRET
  177. C
  178. C**** Duale = IMATRI.LISDUA(1) = 'RN'
  179. C Primale = IMATRI.LISPRI(1) = 'RN'
  180. C -> IMATRI.LIZAFM(1,1) = RR
  181. C
  182. IMATRI.LIZAFM(1,1) = RR
  183. IMATRI.LIZAFM(1,2) = RUX
  184. IMATRI.LIZAFM(1,3) = RUY
  185. IMATRI.LIZAFM(1,4) = RRET
  186. IMATRI.LIZAFM(1,5) = UXR
  187. IMATRI.LIZAFM(1,6) = UXUX
  188. IMATRI.LIZAFM(1,7) = UXUY
  189. IMATRI.LIZAFM(1,8) = UXRET
  190. IMATRI.LIZAFM(1,9) = UYR
  191. IMATRI.LIZAFM(1,10) = UYUX
  192. IMATRI.LIZAFM(1,11) = UYUY
  193. IMATRI.LIZAFM(1,12) = UYRET
  194. IMATRI.LIZAFM(1,13) = RETR
  195. IMATRI.LIZAFM(1,14) = RETUX
  196. IMATRI.LIZAFM(1,15) = RETUY
  197. IMATRI.LIZAFM(1,16) = RETRET
  198. C
  199. SEGDES MATRIK
  200. SEGDES IMATRI
  201. C
  202. C**** Fin definition MATRIK
  203. C
  204. DO IFAC=1,NFAC,1
  205. NGF=MELEFC.NUM(1,IFAC)
  206. NGC=MELEFC.NUM(2,IFAC)
  207. NLF=MLEMF.LECT(NGF)
  208. NLC=MLEMC.LECT(NGC)
  209. NLCB=MLEMCB.LECT(NGF)
  210. VOLU=MPVOL.VPOCHA(NLC,1)
  211. SURF=MPSURF.VPOCHA(NLF,1)
  212. C In CASTEM les normales sont sortantes
  213. CNX=MPNORM.VPOCHA(NLF,1)
  214. CNY=MPNORM.VPOCHA(NLF,2)
  215. CTX=-1.0D0*CNY
  216. CTY=CNX
  217. C Variables au centre
  218. RC=MPRC.VPOCHA(NLC,1)
  219. PC=MPPC.VPOCHA(NLC,1)
  220. UXC=MPVC.VPOCHA(NLC,1)
  221. UYC=MPVC.VPOCHA(NLC,2)
  222. GAMC=MPGAMC.VPOCHA(NLC,1)
  223. C Variables à la face
  224. PF=MPLIM.VPOCHA(NLCB,1)
  225. C
  226. C******* Jacobian with respect to primitive variables
  227. C
  228. VECG(1)=RC
  229. VECG(2)=UXC
  230. VECG(3)=UYC
  231. VECG(4)=PC
  232. VECD(1)=RC
  233. VECD(2)=UXC
  234. VECD(3)=UYC
  235. VECD(4)=PF
  236. NVEC(1)=CNX
  237. NVEC(2)=CNY
  238. TVEC(1)=CTX
  239. TVEC(2)=CTY
  240. CALL CONJP2(DFDUG,DFDUD,VECG,VECD,NVEC,TVEC,GAMC)
  241. C
  242. COEF=-1*SURF/VOLU
  243. DRORO=(DFDUG(1,1)+DFDUD(1,1))*COEF
  244. DROUX=(DFDUG(1,2)+DFDUD(1,2))*COEF
  245. DROUY=(DFDUG(1,3)+DFDUD(1,3))*COEF
  246. DROP=DFDUG(1,4)*COEF
  247. C
  248. DPRO=(DFDUG(4,1)+DFDUD(4,1))*COEF
  249. DPUX=(DFDUG(4,2)+DFDUD(4,2))*COEF
  250. DPUY=(DFDUG(4,3)+DFDUD(4,3))*COEF
  251. DPP=DFDUG(4,4)*COEF
  252. C
  253. DUXRO=(DFDUG(2,1)+DFDUD(2,1))*COEF
  254. DUXUX=(DFDUG(2,2)+DFDUD(2,2))*COEF
  255. DUXUY=(DFDUG(2,3)+DFDUD(2,3))*COEF
  256. DUXP =DFDUG(2,4)*COEF
  257. C
  258. DUYRO=(DFDUG(3,1)+DFDUD(3,1))*COEF
  259. DUYUX=(DFDUG(3,2)+DFDUD(3,2))*COEF
  260. DUYUY=(DFDUG(3,3)+DFDUD(3,3))*COEF
  261. DUYP =DFDUG(3,4)*COEF
  262. C
  263. C******* Jacobian with respect to conservative variables
  264. C
  265. IF(IJAC.EQ.1)THEN
  266. GM1=GAMC-1.0D0
  267. COEF1=-1.0D0*UXC/RC
  268. COEF2=-1.0D0*UYC/RC
  269. COEF3=0.5D0*GM1*((UXC*UXC)+(UYC*UYC))
  270. C
  271. RR.AM(IFAC,1,1)=DRORO+(DROUX*COEF1)+(DROUY*COEF2)+(DROP
  272. $ *COEF3)
  273. RUX.AM(IFAC,1,1)=(DROUX/RC)-((UXC*GM1)*DROP)
  274. RUY.AM(IFAC,1,1)=(DROUY/RC)-((UYC*GM1)*DROP)
  275. RRET.AM(IFAC,1,1)=GM1*DROP
  276. C
  277. UXR.AM(IFAC,1,1)=DUXRO+(DUXUX*COEF1)+(DUXUY*COEF2)+(DUXP
  278. $ *COEF3)
  279. UXUX.AM(IFAC,1,1)=(DUXUX/RC)-((UXC*GM1)*DUXP)
  280. UXUY.AM(IFAC,1,1)=(DUXUY/RC)-((UYC*GM1)*DUXP)
  281. UXRET.AM(IFAC,1,1)=GM1*DUXP
  282. C
  283. UYR.AM(IFAC,1,1)=DUYRO+(DUYUX*COEF1)+(DUYUY*COEF2)+(DUYP
  284. $ *COEF3)
  285. UYUX.AM(IFAC,1,1)=(DUYUX/RC)-((UXC*GM1)*DUYP)
  286. UYUY.AM(IFAC,1,1)=(DUYUY/RC)-((UYC*GM1)*DUYP)
  287. UYRET.AM(IFAC,1,1)=GM1*DUYP
  288. C
  289. RETR.AM(IFAC,1,1)=DPRO+(DPUX*COEF1)+(DPUY*COEF2)+(DPP
  290. $ *COEF3)
  291. RETUX.AM(IFAC,1,1)=(DPUX/RC)-((UXC*GM1)*DPP)
  292. RETUY.AM(IFAC,1,1)=(DPUY/RC)-((UYC*GM1)*DPP)
  293. RETRET.AM(IFAC,1,1)=GM1*DPP
  294. C
  295. ELSEIF(IJAC.EQ.2)THEN
  296. RR.AM(IFAC,1,1)=DRORO
  297. RUX.AM(IFAC,1,1)=DROUX
  298. RUY.AM(IFAC,1,1)=DROUY
  299. RRET.AM(IFAC,1,1)=DROP
  300. C
  301. UXR.AM(IFAC,1,1)=DUXRO
  302. UXUX.AM(IFAC,1,1)=DUXUX
  303. UXUY.AM(IFAC,1,1)=DUXUY
  304. UXRET.AM(IFAC,1,1)=DUXP
  305. C
  306. UYR.AM(IFAC,1,1)=DUYRO
  307. UYUX.AM(IFAC,1,1)=DUYUX
  308. UYUY.AM(IFAC,1,1)=DUYUY
  309. UYRET.AM(IFAC,1,1)=DUYP
  310. C
  311. RETR.AM(IFAC,1,1)=DPRO
  312. RETUX.AM(IFAC,1,1)=DPUX
  313. RETUY.AM(IFAC,1,1)=DPUY
  314. RETRET.AM(IFAC,1,1)=DPP
  315. ENDIF
  316. ENDDO
  317. C
  318. SEGDES MELEFC
  319. C
  320. SEGSUP MLEMC
  321. SEGSUP MLEMCB
  322. SEGSUP MLEMF
  323. C
  324. SEGDES MPNORM
  325. SEGDES MPVOL
  326. SEGDES MPSURF
  327. SEGDES MPRC
  328. SEGDES MPPC
  329. SEGDES MPVC
  330. SEGDES MPGAMC
  331. SEGDES MPLIM
  332. C
  333. SEGDES RR , RUX , RUY , RRET ,
  334. & UXR , UXUX , UXUY , UXRET ,
  335. & UYR , UYUX , UYUY , UYRET ,
  336. & RETR , RETUX , RETUY , RETRET
  337. C
  338. 9999 CONTINUE
  339. RETURN
  340. END
  341.  
  342.  
  343.  
  344.  
  345.  
  346.  
  347.  
  348.  
  349.  
  350.  
  351.  
  352.  
  353.  
  354.  
  355.  

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