Télécharger cli172.eso

Retour à la liste

Numérotation des lignes :

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

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