Télécharger cli142.eso

Retour à la liste

Numérotation des lignes :

cli142
  1. C CLI142 SOURCE OF166741 24/12/13 21:15:17 12097
  2. SUBROUTINE CLI142(MELEMF,MELEMC,MELECB,MELEFC,MELRES,INORM,ICHPVO,
  3. & ICHPSU,IROC,IVITC,IPC,IGAMC,ILIINC,ILIINP,IJAC,IJACO)
  4. C************************************************************************
  5. C
  6. C PROJET : CASTEM 2000
  7. C
  8. C NOM : CLI122
  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
  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.  
  44. INTEGER MELEMF,MELEMC,MELECB,INORM,ICHPVO,ICHPSU, IROC,IVITC,IPC
  45. & ,IGAMC,ICEL,NFAC,IFAC,MELRES,IJACO
  46. & ,NGF,NGC,NLF,NLC
  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
  50. & ,UNC
  51. & ,GM1,USGM1,COEF,ECIN,HIN
  52. & ,DRORO,DROUX,DROUY,DROP
  53. & ,DUXRO,DUXUX,DUXUY,DUXP
  54. & ,DUYRO,DUYUX,DUYUY,DUYP
  55. & ,DPRO,DPUX,DPUY,DPP
  56. & ,COEF1,COEF2,COEF3
  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. C
  89. C SEGACT *MOD
  90. C SEGACT *MOD
  91. C SEGACT *MOD
  92. C SEGACT *MOD
  93. C SEGACT *MOD
  94. C
  95. C
  96. C**** Boucle sur le face pour le calcul des invariants de
  97. C Riemann et du flux
  98. C
  99. SEGACT MELEFC
  100. NFAC=MELEFC.NUM(/2)
  101. C
  102. C**** Objet MATRIK
  103. C
  104. NRIGE = 7
  105. NMATRI = 1
  106. NKID = 9
  107. NKMT = 7
  108. C
  109. SEGINI MATRIK
  110. IJACO = MATRIK
  111. MATRIK.IRIGEL(1,1) = MELRES
  112. MATRIK.IRIGEL(2,1) = MELRES
  113. C
  114. C**** Matrice non symetrique
  115. C
  116. MATRIK.IRIGEL(7,1) = 2
  117. C
  118. NBME = 16
  119. NBSOUS = 1
  120. SEGINI IMATRI
  121. IF(IJAC.EQ.1)THEN
  122. MLMOTS=ILIINC
  123. ELSEIF(IJAC.EQ.2)THEN
  124. MLMOTS=ILIINP
  125. ENDIF
  126. SEGACT MLMOTS
  127. MATRIK.IRIGEL(4,1) = IMATRI
  128. C
  129. IMATRI.LISPRI(1) = MLMOTS.MOTS(1)
  130. IMATRI.LISPRI(2) = MLMOTS.MOTS(2)
  131. IMATRI.LISPRI(3) = MLMOTS.MOTS(3)
  132. IMATRI.LISPRI(4) = MLMOTS.MOTS(4)
  133. IMATRI.LISPRI(5) = MLMOTS.MOTS(1)
  134. IMATRI.LISPRI(6) = MLMOTS.MOTS(2)
  135. IMATRI.LISPRI(7) = MLMOTS.MOTS(3)
  136. IMATRI.LISPRI(8) = MLMOTS.MOTS(4)
  137. IMATRI.LISPRI(9) = MLMOTS.MOTS(1)
  138. IMATRI.LISPRI(10) = MLMOTS.MOTS(2)
  139. IMATRI.LISPRI(11) = MLMOTS.MOTS(3)
  140. IMATRI.LISPRI(12) = MLMOTS.MOTS(4)
  141. IMATRI.LISPRI(13) = MLMOTS.MOTS(1)
  142. IMATRI.LISPRI(14) = MLMOTS.MOTS(2)
  143. IMATRI.LISPRI(15) = MLMOTS.MOTS(3)
  144. IMATRI.LISPRI(16) = MLMOTS.MOTS(4)
  145. C
  146. SEGDES MLMOTS
  147. MLMOTS=ILIINC
  148. SEGACT MLMOTS
  149. C
  150. IMATRI.LISDUA(1) = MLMOTS.MOTS(1)
  151. IMATRI.LISDUA(2) = MLMOTS.MOTS(1)
  152. IMATRI.LISDUA(3) = MLMOTS.MOTS(1)
  153. IMATRI.LISDUA(4) = MLMOTS.MOTS(1)
  154. IMATRI.LISDUA(5) = MLMOTS.MOTS(2)
  155. IMATRI.LISDUA(6) = MLMOTS.MOTS(2)
  156. IMATRI.LISDUA(7) = MLMOTS.MOTS(2)
  157. IMATRI.LISDUA(8) = MLMOTS.MOTS(2)
  158. IMATRI.LISDUA(9) = MLMOTS.MOTS(3)
  159. IMATRI.LISDUA(10) = MLMOTS.MOTS(3)
  160. IMATRI.LISDUA(11) = MLMOTS.MOTS(3)
  161. IMATRI.LISDUA(12) = MLMOTS.MOTS(3)
  162. IMATRI.LISDUA(13) = MLMOTS.MOTS(4)
  163. IMATRI.LISDUA(14) = MLMOTS.MOTS(4)
  164. IMATRI.LISDUA(15) = MLMOTS.MOTS(4)
  165. IMATRI.LISDUA(16) = MLMOTS.MOTS(4)
  166. C
  167. SEGDES MLMOTS
  168. NBEL = NFAC
  169. NBSOUS = 1
  170. NP = 1
  171. MP = 1
  172. SEGINI RR , RUX , RUY , RRET ,
  173. & UXR , UXUX , UXUY , UXRET ,
  174. & UYR , UYUX , UYUY , UYRET ,
  175. & RETR , RETUX , RETUY , RETRET
  176. C
  177. C**** Duale = IMATRI.LISDUA(1) = 'RN'
  178. C Primale = IMATRI.LISPRI(1) = 'RN'
  179. C -> IMATRI.LIZAFM(1,1) = RR
  180. C
  181. IMATRI.LIZAFM(1,1) = RR
  182. IMATRI.LIZAFM(1,2) = RUX
  183. IMATRI.LIZAFM(1,3) = RUY
  184. IMATRI.LIZAFM(1,4) = RRET
  185. IMATRI.LIZAFM(1,5) = UXR
  186. IMATRI.LIZAFM(1,6) = UXUX
  187. IMATRI.LIZAFM(1,7) = UXUY
  188. IMATRI.LIZAFM(1,8) = UXRET
  189. IMATRI.LIZAFM(1,9) = UYR
  190. IMATRI.LIZAFM(1,10) = UYUX
  191. IMATRI.LIZAFM(1,11) = UYUY
  192. IMATRI.LIZAFM(1,12) = UYRET
  193. IMATRI.LIZAFM(1,13) = RETR
  194. IMATRI.LIZAFM(1,14) = RETUX
  195. IMATRI.LIZAFM(1,15) = RETUY
  196. IMATRI.LIZAFM(1,16) = RETRET
  197. C
  198. SEGDES MATRIK
  199. SEGDES IMATRI
  200. C
  201. C**** Fin definition MATRIK
  202. C
  203. DO IFAC=1,NFAC,1
  204. NGF=MELEFC.NUM(1,IFAC)
  205. NGC=MELEFC.NUM(2,IFAC)
  206. NLF=MLEMF.LECT(NGF)
  207. NLC=MLEMC.LECT(NGC)
  208. VOLU=MPVOL.VPOCHA(NLC,1)
  209. SURF=MPSURF.VPOCHA(NLF,1)
  210. C In CASTEM les normales sont sortantes
  211. CNX=MPNORM.VPOCHA(NLF,1)
  212. CNY=MPNORM.VPOCHA(NLF,2)
  213. C Variables au centre
  214. RC=MPRC.VPOCHA(NLC,1)
  215. PC=MPPC.VPOCHA(NLC,1)
  216. UXC=MPVC.VPOCHA(NLC,1)
  217. UYC=MPVC.VPOCHA(NLC,2)
  218. GAMC=MPGAMC.VPOCHA(NLC,1)
  219. GM1=GAMC-1.0D0
  220. USGM1=1.0D0/GM1
  221. C
  222. C******* On calcule UN, UT
  223. C
  224. UNC=(UXC*CNX)+(UYC*CNY)
  225. C
  226. C******* Densite, vitesse, pression sur le bord
  227. C
  228. COEF=-1*SURF/VOLU
  229. C
  230. DRORO=UNC*COEF
  231. DROUX=(RC*CNX)*COEF
  232. DROUY=(RC*CNY)*COEF
  233. DROP=0.0D0
  234. C
  235. DUXRO=(UNC*UXC)*COEF
  236. DUXUX=((RC*CNX*UXC)+(RC*UNC))*COEF
  237. DUXUY=((RC*CNY*UXC))*COEF
  238. DUXP=CNX*COEF
  239. C
  240. DUYRO=(UNC*UYC)*COEF
  241. DUYUX=((RC*CNX*UYC))*COEF
  242. DUYUY=((RC*CNY*UYC)+(RC*UNC))*COEF
  243. DUYP=CNY*COEF
  244. C
  245. ECIN=0.5D0*((UXC*UXC)+(UYC*UYC))
  246. HIN=GAMC*USGM1*PC
  247. DPRO=(UNC*ECIN)*COEF
  248. DPUX=((CNX*HIN)+(RC*CNX*ECIN)+(RC*UNC*UXC))*COEF
  249. DPUY=((CNY*HIN)+(RC*CNY*ECIN)+(RC*UNC*UYC))*COEF
  250. DPP=(UNC*GAMC*USGM1)*COEF
  251. CC
  252. CC******* Jacobian with respect to conservative variables
  253. CC
  254. IF(IJAC.EQ.1)THEN
  255.  
  256. COEF1=-1.0D0*UXC/RC
  257. COEF2=-1.0D0*UYC/RC
  258. COEF3=0.5D0*GM1*((UXC*UXC)+(UYC*UYC))
  259. C
  260. RR.AM(IFAC,1,1)=DRORO+(DROUX*COEF1)+(DROUY*COEF2)+(DROP
  261. $ *COEF3)
  262. RUX.AM(IFAC,1,1)=(DROUX/RC)-((UXC*GM1)*DROP)
  263. RUY.AM(IFAC,1,1)=(DROUY/RC)-((UYC*GM1)*DROP)
  264. RRET.AM(IFAC,1,1)=GM1*DROP
  265. C
  266. UXR.AM(IFAC,1,1)=DUXRO+(DUXUX*COEF1)+(DUXUY*COEF2)+(DUXP
  267. $ *COEF3)
  268. UXUX.AM(IFAC,1,1)=(DUXUX/RC)-((UXC*GM1)*DUXP)
  269. UXUY.AM(IFAC,1,1)=(DUXUY/RC)-((UYC*GM1)*DUXP)
  270. UXRET.AM(IFAC,1,1)=GM1*DUXP
  271. C
  272. UYR.AM(IFAC,1,1)=DUYRO+(DUYUX*COEF1)+(DUYUY*COEF2)+(DUYP
  273. $ *COEF3)
  274. UYUX.AM(IFAC,1,1)=(DUYUX/RC)-((UXC*GM1)*DUYP)
  275. UYUY.AM(IFAC,1,1)=(DUYUY/RC)-((UYC*GM1)*DUYP)
  276. UYRET.AM(IFAC,1,1)=GM1*DUYP
  277. C
  278. RETR.AM(IFAC,1,1)=DPRO+(DPUX*COEF1)+(DPUY*COEF2)+(DPP
  279. $ *COEF3)
  280. RETUX.AM(IFAC,1,1)=(DPUX/RC)-((UXC*GM1)*DPP)
  281. RETUY.AM(IFAC,1,1)=(DPUY/RC)-((UYC*GM1)*DPP)
  282. RETRET.AM(IFAC,1,1)=GM1*DPP
  283. C
  284. ELSEIF(IJAC.EQ.2)THEN
  285. RR.AM(IFAC,1,1)=DRORO
  286. RUX.AM(IFAC,1,1)=DROUX
  287. RUY.AM(IFAC,1,1)=DROUY
  288. RRET.AM(IFAC,1,1)=DROP
  289. C
  290. UXR.AM(IFAC,1,1)=DUXRO
  291. UXUX.AM(IFAC,1,1)=DUXUX
  292. UXUY.AM(IFAC,1,1)=DUXUY
  293. UXRET.AM(IFAC,1,1)=DUXP
  294. C
  295. UYR.AM(IFAC,1,1)=DUYRO
  296. UYUX.AM(IFAC,1,1)=DUYUX
  297. UYUY.AM(IFAC,1,1)=DUYUY
  298. UYRET.AM(IFAC,1,1)=DUYP
  299. C
  300. RETR.AM(IFAC,1,1)=DPRO
  301. RETUX.AM(IFAC,1,1)=DPUX
  302. RETUY.AM(IFAC,1,1)=DPUY
  303. RETRET.AM(IFAC,1,1)=DPP
  304. ENDIF
  305. ENDDO
  306. C
  307. SEGDES MELEFC
  308. C
  309. SEGSUP MLEMC
  310. SEGSUP MLEMCB
  311. SEGSUP MLEMF
  312. C
  313. SEGDES MPNORM
  314. SEGDES MPVOL
  315. SEGDES MPSURF
  316. SEGDES MPRC
  317. SEGDES MPPC
  318. SEGDES MPVC
  319. SEGDES MPGAMC
  320. C
  321. SEGDES RR , RUX , RUY , RRET ,
  322. & UXR , UXUX , UXUY , UXRET ,
  323. & UYR , UYUX , UYUY , UYRET ,
  324. & RETR , RETUX , RETUY , RETRET
  325. C
  326. 9999 CONTINUE
  327. RETURN
  328. END
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.  
  337.  
  338.  
  339.  
  340.  
  341.  
  342.  
  343.  

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