Télécharger derl.eso

Retour à la liste

Numérotation des lignes :

derl
  1. C DERL SOURCE BECC 11/05/26 21:15:20 6981
  2. SUBROUTINE DERL(
  3. & PC, GAM,
  4. & P, RHO_L, P_L, U_L,
  5. & DER,
  6. & LOGDEB, LOGAN)
  7. *
  8. *************************************************************************
  9. *
  10. * project : CAST3M, EUROPLEXUS...
  11. *
  12. * name : derl
  13. *
  14. * description : euler equations for a mixture of stiffened gases
  15. * flux in the non-reactive case.
  16. *
  17. * left entropy-respecing curve.
  18. * derivative of w with respect to p
  19. *
  20. * language : fortran 77
  21. *
  22. * author : a. beccantini den/dm2s/sfme/ltmf
  23. *
  24. *************************************************************************
  25. *
  26. * called by :
  27. *
  28. *
  29. *************************************************************************
  30. *
  31. ***** input
  32. *
  33. * pc, gam = properties of the gas
  34. *
  35. * p = pressure in the right side of the left
  36. * entropy respecing curve
  37. *
  38. * rho_l, p_l, u_l
  39. * = density, pressure, velocity on the left
  40. *
  41. * logdeb = debugging ?
  42. *
  43. ***** output
  44. *
  45. * der = derivative
  46. *
  47. * logan = anomaly ?
  48. *
  49. *************************************************************************
  50. *
  51. * 12/11/2009 created
  52. * 25/05/2011 evolution in CAST3M
  53. *
  54. *************************************************************************
  55. *
  56. * n.b.: all variables are declared
  57. *
  58. C IMPLICIT NONE
  59. IMPLICIT INTEGER(I-N)
  60. REAL*8
  61. & PC, GAM,
  62. & P, RHO_L, P_L, U_L,
  63. & DER, CSON_L, VAR, DER2
  64. *
  65. LOGICAL LOGDEB, LOGAN
  66. *
  67. IF (P .LE. (-1.0D0 * PC)) THEN
  68. C
  69. C******* Stop
  70. C
  71. WRITE(*,*) 'P = ', P
  72. WRITE(*,*) 'PC = ', PC
  73. LOGAN = .TRUE.
  74. WRITE(*,*) 'SUBROUTINE DERL'
  75. WRITE(*,*) 'ANOMALY DETECTED.'
  76. GOTO 9999
  77. ENDIF
  78. IF (P .LE. P_L) THEN
  79. C
  80. C******* Rarefaction
  81. C
  82. cson_L = gam * (P_L + PC) / RHO_L
  83. cson_L = SQRT (cson_L)
  84. var = P + PC
  85. var = var / (P_L + PC)
  86. var = var ** ((GAM - 1.0D0) / (2.0D0 * GAM))
  87. DER = ((-1.0D0 * cson_L / GAM) * (var / (P + PC)))
  88. ELSE
  89. var = RHO_L * (GAM + 1.0D0) * (P + PC)
  90. var = var + (RHO_L * (GAM - 1.0D0) * (P_L + PC))
  91. DER = SQRT (2.0D0 / var)
  92. DER2 = 0.5D0 * SQRT (2.0D0) * (var**(-1.5D0)) * RHO_L *
  93. & (gam + 1.0D0)
  94. DER2 = DER2 * (P - P_L)
  95. DER = DER2 - DER
  96. ENDIF
  97. *
  98. IF (LOGAN) THEN
  99. WRITE(*,*) 'SUBROUTINE FSTERL.F'
  100. WRITE(*,*) 'ANOMALY DETECTED.'
  101. GOTO 9999
  102. ENDIF
  103. *
  104. 9999 RETURN
  105. END
  106.  
  107.  

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