Simulation Core
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

1 рік тому
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. module CMudTreatmentProblemsVariables
  2. use CProblemDifinition
  3. implicit none
  4. public
  5. ! Input vars
  6. type(CProblem) :: Degasser
  7. type(CProblem) :: ShaleShaker
  8. type(CProblem) :: Desander
  9. type(CProblem) :: Desilter
  10. procedure (ActionInteger), pointer :: DegasserPtr
  11. procedure (ActionInteger), pointer :: ShaleShakerPtr
  12. procedure (ActionInteger), pointer :: DesanderPtr
  13. procedure (ActionInteger), pointer :: DesilterPtr
  14. contains
  15. subroutine ProcessMudTreatmentProblemsDueTime(time)
  16. implicit none
  17. integer :: time
  18. if(Degasser%ProblemType == Time_ProblemType) call ProcessDueTime(Degasser, ChangeDegasser, time)
  19. if(ShaleShaker%ProblemType == Time_ProblemType) call ProcessDueTime(ShaleShaker, ChangeShaleShaker, time)
  20. if(Desander%ProblemType == Time_ProblemType) call ProcessDueTime(Desander, ChangeDesander, time)
  21. if(Desilter%ProblemType == Time_ProblemType) call ProcessDueTime(Desilter, ChangeDesilter, time)
  22. end subroutine
  23. subroutine ProcessMudTreatmentProblemsDuePumpStrokes(strokes)
  24. implicit none
  25. integer :: strokes
  26. if(Degasser%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(Degasser, ChangeDegasser, strokes)
  27. if(ShaleShaker%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ShaleShaker, ChangeShaleShaker, strokes)
  28. if(Desander%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(Desander, ChangeDesander, strokes)
  29. if(Desilter%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(Desilter, ChangeDesilter, strokes)
  30. end subroutine
  31. subroutine ProcessMudTreatmentProblemsDueVolumePumped(volume)
  32. implicit none
  33. real(8) :: volume
  34. if(Degasser%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(Degasser, ChangeDegasser, volume)
  35. if(ShaleShaker%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ShaleShaker, ChangeShaleShaker, volume)
  36. if(Desander%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(Desander, ChangeDesander, volume)
  37. if(Desilter%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(Desilter, ChangeDesilter, volume)
  38. end subroutine
  39. subroutine ProcessMudTreatmentProblemsDueDistanceDrilled(distance)
  40. implicit none
  41. real(8) :: distance
  42. if(Degasser%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(Degasser, ChangeDegasser, distance)
  43. if(ShaleShaker%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ShaleShaker, ChangeShaleShaker, distance)
  44. if(Desander%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(Desander, ChangeDesander, distance)
  45. if(Desilter%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(Desilter, ChangeDesilter, distance)
  46. end subroutine
  47. subroutine ChangeDegasser(status)
  48. implicit none
  49. integer, intent (in) :: status
  50. if(associated(DegasserPtr)) call DegasserPtr(status)
  51. !if(status == Clear_StatusType) print*,'On_Degasser_Clear'
  52. !if(status == Executed_StatusType) print*,'On_Degasser_Execute'
  53. endsubroutine
  54. subroutine ChangeShaleShaker(status)
  55. implicit none
  56. integer, intent (in) :: status
  57. if(associated(ShaleShakerPtr)) call ShaleShakerPtr(status)
  58. !if(status == Clear_StatusType) print*,'On_ShaleShaker_Clear'
  59. !if(status == Executed_StatusType) print*,'On_ShaleShaker_Execute'
  60. endsubroutine
  61. subroutine ChangeDesander(status)
  62. implicit none
  63. integer, intent (in) :: status
  64. if(associated(DesanderPtr)) call DesanderPtr(status)
  65. !if(status == Clear_StatusType) print*,'On_Desander_Clear'
  66. !if(status == Executed_StatusType) print*,'On_Desander_Execute'
  67. endsubroutine
  68. subroutine ChangeDesilter(status)
  69. implicit none
  70. integer, intent (in) :: status
  71. if(associated(DesilterPtr)) call DesilterPtr(status)
  72. !if(status == Clear_StatusType) print*,'On_Desilter_Clear'
  73. !if(status == Executed_StatusType) print*,'On_Desilter_Execute'
  74. endsubroutine
  75. subroutine SubscribeDegasser(v)
  76. !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeDegasser
  77. !DEC$ ATTRIBUTES ALIAS: 'SubscribeDegasser' :: SubscribeDegasser
  78. implicit none
  79. procedure (ActionInteger) :: v
  80. DegasserPtr => v
  81. end subroutine
  82. subroutine SubscribeShaleShaker(v)
  83. !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeShaleShaker
  84. !DEC$ ATTRIBUTES ALIAS: 'SubscribeShaleShaker' :: SubscribeShaleShaker
  85. implicit none
  86. procedure (ActionInteger) :: v
  87. ShaleShakerPtr => v
  88. end subroutine
  89. subroutine SubscribeDesander(v)
  90. !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeDesander
  91. !DEC$ ATTRIBUTES ALIAS: 'SubscribeDesander' :: SubscribeDesander
  92. implicit none
  93. procedure (ActionInteger) :: v
  94. DesanderPtr => v
  95. end subroutine
  96. subroutine SubscribeDesilter(v)
  97. !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeDesilter
  98. !DEC$ ATTRIBUTES ALIAS: 'SubscribeDesilter' :: SubscribeDesilter
  99. implicit none
  100. procedure (ActionInteger) :: v
  101. DesilterPtr => v
  102. end subroutine
  103. end module CMudTreatmentProblemsVariables