Télécharger cli153.eso

Retour à la liste

Numérotation des lignes :

cli153
  1. C CLI153 SOURCE OF166741 24/12/13 21:15:21 12097
  2. SUBROUTINE CLI153(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 : CLI153
  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. & RUZ.IZAFM, UXUZ.IZAFM, UYUZ.IZAFM, RETUZ.IZAFM,
  44. & UZR.IZAFM, UZUX.IZAFM, UZUY.IZAFM, UZRET.IZAFM,
  45. & UZUZ.IZAFM
  46.  
  47. INTEGER MELEMF,MELEMC,MELECB,INORM,ICHPVO,ICHPSU, IROC,IVITC,IPC
  48. & ,IGAMC,ICHLIM,ICEL,NFAC,IFAC,MELRES,IJACO
  49. & ,NGF,NGC,NLF,NLC,NLCB
  50. & ,ILIINC,ILIINP,IJAC
  51. & ,MP, NBEL, NBME, NBSOUS, NKID, NKMT, NMATRI, NP, NRIGE
  52. REAL*8 VOLU,SURF,RC,PC,UXC,UYC,GAMC,CNX,CNY,CTX,CTY,PF
  53. & ,CNZ,CTZ,CT2X,CT2Y,CT2Z,UZC
  54. & ,VECG(5),VECD(5),DFDUG(5,5),DFDUD(5,5)
  55. & ,NVEC(3),TVEC(3),TVEC2(3)
  56. & ,DRORO,DROUX,DROUY,DROP
  57. & ,DUXRO,DUXUX,DUXUY,DUXP
  58. & ,DUYRO,DUYUX,DUYUY,DUYP
  59. & ,DPRO,DPUX,DPUY,DPP
  60. & ,DROUZ,DUXUZ,DUYUZ,DPUZ
  61. & ,DUZRO,DUZUX,DUZUY,DUZUZ,DUZP
  62. & ,COEF1,COEF2,COEF3,GM1,COEF,COEF4
  63. CHARACTER*(8) TYPE
  64. C
  65. C
  66. C**** KRIPAD pour la correspondance global/local
  67. C
  68. CALL KRIPAD(MELEMC,MLEMC)
  69. C SEGINI MLEMC
  70. CALL KRIPAD(MELECB,MLEMCB)
  71. C SEGINI MLEMCB
  72. CALL KRIPAD(MELEMF,MLEMF)
  73. C SEGINI MLEMF
  74. C
  75. C**** CHPOINTs de la table DOMAINE
  76. C
  77. CALL LICHT(INORM,MPNORM,TYPE,ICEL)
  78. CALL LICHT(ICHPVO,MPVOL,TYPE,ICEL)
  79. CALL LICHT(ICHPSU,MPSURF,TYPE,ICEL)
  80. C
  81. C**** LICHT active les MPOVALs en *MOD
  82. C
  83. C SEGACT MPNORM*MOD
  84. C SEGACT MPOVSU*MOD
  85. C SEGACT MPOVOL*MOD
  86. C
  87. C
  88. C**** CHPOINTs des variables
  89. C
  90. CALL LICHT(IROC,MPRC,TYPE,ICEL)
  91. CALL LICHT(IVITC,MPVC,TYPE,ICEL)
  92. CALL LICHT(IPC,MPPC,TYPE,ICEL)
  93. CALL LICHT(IGAMC,MPGAMC,TYPE,ICEL)
  94. CALL LICHT(ICHLIM,MPLIM,TYPE,ICEL)
  95. C
  96. C SEGACT *MOD
  97. C SEGACT *MOD
  98. C SEGACT *MOD
  99. C SEGACT *MOD
  100. C SEGACT *MOD
  101. C
  102. C
  103. C**** Boucle sur le face pour le calcul des invariants de
  104. C Riemann et du flux
  105. C
  106. SEGACT MELEFC
  107. NFAC=MELEFC.NUM(/2)
  108. C
  109. C**** Objet MATRIK
  110. C
  111. NRIGE = 7
  112. NMATRI = 1
  113. NKID = 9
  114. NKMT = 7
  115. C
  116. SEGINI MATRIK
  117. IJACO = MATRIK
  118. MATRIK.IRIGEL(1,1) = MELRES
  119. MATRIK.IRIGEL(2,1) = MELRES
  120. C
  121. C**** Matrice non symetrique
  122. C
  123. MATRIK.IRIGEL(7,1) = 2
  124. C
  125. NBME = 25
  126. NBSOUS = 1
  127. SEGINI IMATRI
  128. IF(IJAC.EQ.1)THEN
  129. MLMOTS=ILIINC
  130. ELSEIF(IJAC.EQ.2)THEN
  131. MLMOTS=ILIINP
  132. ENDIF
  133. SEGACT MLMOTS
  134. MATRIK.IRIGEL(4,1) = IMATRI
  135. C
  136. IMATRI.LISPRI(1) = MLMOTS.MOTS(1)
  137. IMATRI.LISPRI(2) = MLMOTS.MOTS(2)
  138. IMATRI.LISPRI(3) = MLMOTS.MOTS(3)
  139. IMATRI.LISPRI(4) = MLMOTS.MOTS(4)
  140. IMATRI.LISPRI(5) = MLMOTS.MOTS(5)
  141. C
  142. IMATRI.LISPRI(6) = MLMOTS.MOTS(1)
  143. IMATRI.LISPRI(7) = MLMOTS.MOTS(2)
  144. IMATRI.LISPRI(8) = MLMOTS.MOTS(3)
  145. IMATRI.LISPRI(9) = MLMOTS.MOTS(4)
  146. IMATRI.LISPRI(10) = MLMOTS.MOTS(5)
  147. C
  148. IMATRI.LISPRI(11) = MLMOTS.MOTS(1)
  149. IMATRI.LISPRI(12) = MLMOTS.MOTS(2)
  150. IMATRI.LISPRI(13) = MLMOTS.MOTS(3)
  151. IMATRI.LISPRI(14) = MLMOTS.MOTS(4)
  152. IMATRI.LISPRI(15) = MLMOTS.MOTS(5)
  153. C
  154. IMATRI.LISPRI(16) = MLMOTS.MOTS(1)
  155. IMATRI.LISPRI(17) = MLMOTS.MOTS(2)
  156. IMATRI.LISPRI(18) = MLMOTS.MOTS(3)
  157. IMATRI.LISPRI(19) = MLMOTS.MOTS(4)
  158. IMATRI.LISPRI(20) = MLMOTS.MOTS(5)
  159. C
  160. IMATRI.LISPRI(21) = MLMOTS.MOTS(1)
  161. IMATRI.LISPRI(22) = MLMOTS.MOTS(2)
  162. IMATRI.LISPRI(23) = MLMOTS.MOTS(3)
  163. IMATRI.LISPRI(24) = MLMOTS.MOTS(4)
  164. IMATRI.LISPRI(25) = MLMOTS.MOTS(5)
  165. C
  166. SEGDES MLMOTS
  167. MLMOTS=ILIINC
  168. SEGACT MLMOTS
  169. C
  170. C
  171. IMATRI.LISDUA(1) = MLMOTS.MOTS(1)
  172. IMATRI.LISDUA(2) = MLMOTS.MOTS(1)
  173. IMATRI.LISDUA(3) = MLMOTS.MOTS(1)
  174. IMATRI.LISDUA(4) = MLMOTS.MOTS(1)
  175. IMATRI.LISDUA(5) = MLMOTS.MOTS(1)
  176. C
  177. IMATRI.LISDUA(6) = MLMOTS.MOTS(2)
  178. IMATRI.LISDUA(7) = MLMOTS.MOTS(2)
  179. IMATRI.LISDUA(8) = MLMOTS.MOTS(2)
  180. IMATRI.LISDUA(9) = MLMOTS.MOTS(2)
  181. IMATRI.LISDUA(10) = MLMOTS.MOTS(2)
  182. C
  183. IMATRI.LISDUA(11) = MLMOTS.MOTS(3)
  184. IMATRI.LISDUA(12) = MLMOTS.MOTS(3)
  185. IMATRI.LISDUA(13) = MLMOTS.MOTS(3)
  186. IMATRI.LISDUA(14) = MLMOTS.MOTS(3)
  187. IMATRI.LISDUA(15) = MLMOTS.MOTS(3)
  188. C
  189. IMATRI.LISDUA(16) = MLMOTS.MOTS(4)
  190. IMATRI.LISDUA(17) = MLMOTS.MOTS(4)
  191. IMATRI.LISDUA(18) = MLMOTS.MOTS(4)
  192. IMATRI.LISDUA(19) = MLMOTS.MOTS(4)
  193. IMATRI.LISDUA(20) = MLMOTS.MOTS(4)
  194. C
  195. IMATRI.LISDUA(21) = MLMOTS.MOTS(5)
  196. IMATRI.LISDUA(22) = MLMOTS.MOTS(5)
  197. IMATRI.LISDUA(23) = MLMOTS.MOTS(5)
  198. IMATRI.LISDUA(24) = MLMOTS.MOTS(5)
  199. IMATRI.LISDUA(25) = MLMOTS.MOTS(5)
  200. C
  201. SEGDES MLMOTS
  202. NBEL = NFAC
  203. NBSOUS = 1
  204. NP = 1
  205. MP = 1
  206. SEGINI RR , RUX , RUY , RUZ ,RRET ,
  207. & UXR , UXUX , UXUY , UXUZ ,UXRET ,
  208. & UYR , UYUX , UYUY , UYUZ , UYRET ,
  209. & UZR , UZUX , UZUY , UZUZ , UZRET ,
  210. & RETR , RETUX , RETUY, RETUZ , RETRET
  211. C
  212. C**** Duale = IMATRI.LISDUA(1) = 'RN'
  213. C Primale = IMATRI.LISPRI(1) = 'RN'
  214. C -> IMATRI.LIZAFM(1,1) = RR
  215. C
  216. IMATRI.LIZAFM(1,1) = RR
  217. IMATRI.LIZAFM(1,2) = RUX
  218. IMATRI.LIZAFM(1,3) = RUY
  219. IMATRI.LIZAFM(1,4) = RUZ
  220. IMATRI.LIZAFM(1,5) = RRET
  221. C
  222. IMATRI.LIZAFM(1,6) = UXR
  223. IMATRI.LIZAFM(1,7) = UXUX
  224. IMATRI.LIZAFM(1,8) = UXUY
  225. IMATRI.LIZAFM(1,9) = UXUZ
  226. IMATRI.LIZAFM(1,10) = UXRET
  227. C
  228. IMATRI.LIZAFM(1,11) = UYR
  229. IMATRI.LIZAFM(1,12) = UYUX
  230. IMATRI.LIZAFM(1,13) = UYUY
  231. IMATRI.LIZAFM(1,14) = UYUZ
  232. IMATRI.LIZAFM(1,15) = UYRET
  233. C
  234. IMATRI.LIZAFM(1,16) = UZR
  235. IMATRI.LIZAFM(1,17) = UZUX
  236. IMATRI.LIZAFM(1,18) = UZUY
  237. IMATRI.LIZAFM(1,19) = UZUZ
  238. IMATRI.LIZAFM(1,20) = UZRET
  239. C
  240. IMATRI.LIZAFM(1,21) = RETR
  241. IMATRI.LIZAFM(1,22) = RETUX
  242. IMATRI.LIZAFM(1,23) = RETUY
  243. IMATRI.LIZAFM(1,24) = RETUZ
  244. IMATRI.LIZAFM(1,25) = RETRET
  245. C
  246. SEGDES MATRIK
  247. SEGDES IMATRI
  248. C
  249. C**** Fin definition MATRIK
  250. C
  251. DO IFAC=1,NFAC,1
  252. NGF=MELEFC.NUM(1,IFAC)
  253. NGC=MELEFC.NUM(2,IFAC)
  254. NLF=MLEMF.LECT(NGF)
  255. NLC=MLEMC.LECT(NGC)
  256. NLCB=MLEMCB.LECT(NGF)
  257. VOLU=MPVOL.VPOCHA(NLC,1)
  258. SURF=MPSURF.VPOCHA(NLF,1)
  259. C In CASTEM les normales sont sortantes
  260. CNX=MPNORM.VPOCHA(NLF,1)
  261. CNY=MPNORM.VPOCHA(NLF,2)
  262. CNZ=MPNORM.VPOCHA(NLF,3)
  263. CTX=MPNORM.VPOCHA(NLF,4)
  264. CTY=MPNORM.VPOCHA(NLF,5)
  265. CTZ=MPNORM.VPOCHA(NLF,6)
  266. CT2X=MPNORM.VPOCHA(NLF,7)
  267. CT2Y=MPNORM.VPOCHA(NLF,8)
  268. CT2Z=MPNORM.VPOCHA(NLF,9)
  269. C Variables au centre
  270. RC=MPRC.VPOCHA(NLC,1)
  271. PC=MPPC.VPOCHA(NLC,1)
  272. UXC=MPVC.VPOCHA(NLC,1)
  273. UYC=MPVC.VPOCHA(NLC,2)
  274. UZC=MPVC.VPOCHA(NLC,3)
  275. GAMC=MPGAMC.VPOCHA(NLC,1)
  276. C Variables à la face
  277. PF=MPLIM.VPOCHA(NLCB,1)
  278. C
  279. C******* Jacobian with respect to primitive variables
  280. C
  281. VECG(1)=RC
  282. VECG(2)=UXC
  283. VECG(3)=UYC
  284. VECG(4)=UZC
  285. VECG(5)=PC
  286. C
  287. VECD(1)=RC
  288. VECD(2)=UXC
  289. VECD(3)=UYC
  290. VECD(4)=UZC
  291. VECD(5)=PF
  292. C
  293. NVEC(1)=CNX
  294. NVEC(2)=CNY
  295. NVEC(3)=CNZ
  296. TVEC(1)=CTX
  297. TVEC(2)=CTY
  298. TVEC(3)=CTZ
  299. TVEC2(1)=CT2X
  300. TVEC2(2)=CT2Y
  301. TVEC2(3)=CT2Z
  302. C
  303. CALL CONJP4(DFDUG,DFDUD,VECG,VECD,NVEC,TVEC,TVEC2,GAMC)
  304. C
  305. COEF=-1*SURF/VOLU
  306. DRORO=(DFDUG(1,1)+DFDUD(1,1))*COEF
  307. DROUX=(DFDUG(1,2)+DFDUD(1,2))*COEF
  308. DROUY=(DFDUG(1,3)+DFDUD(1,3))*COEF
  309. DROUZ=(DFDUG(1,4)+DFDUD(1,4))*COEF
  310. DROP=DFDUG(1,5)*COEF
  311. C
  312. DPRO=(DFDUG(5,1)+DFDUD(5,1))*COEF
  313. DPUX=(DFDUG(5,2)+DFDUD(5,2))*COEF
  314. DPUY=(DFDUG(5,3)+DFDUD(5,3))*COEF
  315. DPUZ=(DFDUG(5,4)+DFDUD(5,4))*COEF
  316. DPP=DFDUG(5,5)*COEF
  317. C
  318. DUXRO=(DFDUG(2,1)+DFDUD(2,1))*COEF
  319. DUXUX=(DFDUG(2,2)+DFDUD(2,2))*COEF
  320. DUXUY=(DFDUG(2,3)+DFDUD(2,3))*COEF
  321. DUXUZ=(DFDUG(2,4)+DFDUD(2,4))*COEF
  322. DUXP =DFDUG(2,5)*COEF
  323. C
  324. DUYRO=(DFDUG(3,1)+DFDUD(3,1))*COEF
  325. DUYUX=(DFDUG(3,2)+DFDUD(3,2))*COEF
  326. DUYUY=(DFDUG(3,3)+DFDUD(3,3))*COEF
  327. DUYUZ=(DFDUG(3,4)+DFDUD(3,4))*COEF
  328. DUYP =DFDUG(3,5)*COEF
  329. C
  330. DUZRO=(DFDUG(4,1)+DFDUD(4,1))*COEF
  331. DUZUX=(DFDUG(4,2)+DFDUD(4,2))*COEF
  332. DUZUY=(DFDUG(4,3)+DFDUD(4,3))*COEF
  333. DUZUZ=(DFDUG(4,4)+DFDUD(4,4))*COEF
  334. DUZP =DFDUG(4,5)*COEF
  335. C
  336. C******* Jacobian with respect to conservative variables
  337. C
  338. IF(IJAC.EQ.1)THEN
  339. GM1=GAMC-1.0D0
  340. C
  341. COEF1=-1.0D0*UXC/RC
  342. COEF2=-1.0D0*UYC/RC
  343. COEF3=-1.0D0*UZC/RC
  344. COEF4=0.5D0*GM1*((UXC*UXC)+(UYC*UYC)+(UZC*UZC))
  345. C
  346. RR.AM(IFAC,1,1)=DRORO+(DROUX*COEF1)+(DROUY*COEF2)+(DROUZ
  347. $ *COEF3)+(DROP*COEF4)
  348. RUX.AM(IFAC,1,1)=(DROUX/RC)-((UXC*GM1)*DROP)
  349. RUY.AM(IFAC,1,1)=(DROUY/RC)-((UYC*GM1)*DROP)
  350. RUZ.AM(IFAC,1,1)=(DROUZ/RC)-((UZC*GM1)*DROP)
  351. RRET.AM(IFAC,1,1)=GM1*DROP
  352. C
  353. UXR.AM(IFAC,1,1)=DUXRO+(DUXUX*COEF1)+(DUXUY*COEF2)+(DUXUZ
  354. $ *COEF3)+(DUXP*COEF4)
  355. UXUX.AM(IFAC,1,1)=(DUXUX/RC)-((UXC*GM1)*DUXP)
  356. UXUY.AM(IFAC,1,1)=(DUXUY/RC)-((UYC*GM1)*DUXP)
  357. UXUZ.AM(IFAC,1,1)=(DUXUZ/RC)-((UZC*GM1)*DUXP)
  358. UXRET.AM(IFAC,1,1)=GM1*DUXP
  359. C
  360. UYR.AM(IFAC,1,1)=DUYRO+(DUYUX*COEF1)+(DUYUY*COEF2)+(DUYUZ
  361. $ *COEF3)+(DUYP*COEF4)
  362. UYUX.AM(IFAC,1,1)=(DUYUX/RC)-((UXC*GM1)*DUYP)
  363. UYUY.AM(IFAC,1,1)=(DUYUY/RC)-((UYC*GM1)*DUYP)
  364. UYUZ.AM(IFAC,1,1)=(DUYUZ/RC)-((UZC*GM1)*DUYP)
  365. UYRET.AM(IFAC,1,1)=GM1*DUYP
  366. C
  367. UZR.AM(IFAC,1,1)=DUZRO+(DUZUX*COEF1)+(DUZUY*COEF2)+(DUZUZ
  368. $ *COEF3)+(DUZP*COEF4)
  369. UZUX.AM(IFAC,1,1)=(DUZUX/RC)-((UXC*GM1)*DUZP)
  370. UZUY.AM(IFAC,1,1)=(DUZUY/RC)-((UYC*GM1)*DUZP)
  371. UZUZ.AM(IFAC,1,1)=(DUZUZ/RC)-((UZC*GM1)*DUZP)
  372. UZRET.AM(IFAC,1,1)=GM1*DUZP
  373. C
  374. RETR.AM(IFAC,1,1)=DPRO+(DPUX*COEF1)+(DPUY*COEF2)+(DPUZ
  375. $ *COEF3)+(DPP*COEF4)
  376. RETUX.AM(IFAC,1,1)=(DPUX/RC)-((UXC*GM1)*DPP)
  377. RETUY.AM(IFAC,1,1)=(DPUY/RC)-((UYC*GM1)*DPP)
  378. RETUZ.AM(IFAC,1,1)=(DPUZ/RC)-((UZC*GM1)*DPP)
  379. RETRET.AM(IFAC,1,1)=GM1*DPP
  380. C
  381. ELSEIF(IJAC.EQ.2)THEN
  382. RR.AM(IFAC,1,1)=DRORO
  383. RUX.AM(IFAC,1,1)=DROUX
  384. RUY.AM(IFAC,1,1)=DROUY
  385. RUZ.AM(IFAC,1,1)=DROUZ
  386. RRET.AM(IFAC,1,1)=DROP
  387. C
  388. UXR.AM(IFAC,1,1)=DUXRO
  389. UXUX.AM(IFAC,1,1)=DUXUX
  390. UXUY.AM(IFAC,1,1)=DUXUY
  391. UXUZ.AM(IFAC,1,1)=DUXUZ
  392. UXRET.AM(IFAC,1,1)=DUXP
  393. C
  394. UYR.AM(IFAC,1,1)=DUYRO
  395. UYUX.AM(IFAC,1,1)=DUYUX
  396. UYUY.AM(IFAC,1,1)=DUYUY
  397. UYUZ.AM(IFAC,1,1)=DUYUZ
  398. UYRET.AM(IFAC,1,1)=DUYP
  399. C
  400. UZR.AM(IFAC,1,1)=DUZRO
  401. UZUX.AM(IFAC,1,1)=DUZUX
  402. UZUY.AM(IFAC,1,1)=DUZUY
  403. UZUZ.AM(IFAC,1,1)=DUZUZ
  404. UZRET.AM(IFAC,1,1)=DUZP
  405. C
  406. RETR.AM(IFAC,1,1)=DPRO
  407. RETUX.AM(IFAC,1,1)=DPUX
  408. RETUY.AM(IFAC,1,1)=DPUY
  409. RETUZ.AM(IFAC,1,1)=DPUZ
  410. RETRET.AM(IFAC,1,1)=DPP
  411. ENDIF
  412. ENDDO
  413. C
  414. SEGDES MELEFC
  415. C
  416. SEGSUP MLEMC
  417. SEGSUP MLEMCB
  418. SEGSUP MLEMF
  419. C
  420. SEGDES MPNORM
  421. SEGDES MPVOL
  422. SEGDES MPSURF
  423. SEGDES MPRC
  424. SEGDES MPPC
  425. SEGDES MPVC
  426. SEGDES MPGAMC
  427. SEGDES MPLIM
  428. C
  429. SEGDES RR , RUX , RUY , RUZ ,RRET ,
  430. & UXR , UXUX , UXUY , UXUZ ,UXRET ,
  431. & UYR , UYUX , UYUY , UYUZ , UYRET ,
  432. & UZR , UZUX , UZUY , UZUZ , UZRET ,
  433. & RETR , RETUX , RETUY, RETUZ , RETRET
  434. C
  435. 9999 CONTINUE
  436. RETURN
  437. END
  438.  
  439.  
  440.  
  441.  
  442.  
  443.  
  444.  
  445.  
  446.  
  447.  
  448.  
  449.  
  450.  
  451.  
  452.  

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