Simulation Core
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

CKickProblemsVariables.f90 2.1 KiB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. module CKickProblemsVariables
  2. use CProblemDifinition
  3. implicit none
  4. public
  5. !constants
  6. integer :: Gas_FluidType = 0
  7. integer :: Oil_FluidType = 1
  8. integer :: Water_FluidType = 2
  9. ! Input vars
  10. type(CProblem) :: Kick
  11. integer :: FluidType
  12. integer :: FlowRate
  13. integer :: OverBalancePressure
  14. logical :: IsAutoMigrationRateSelected
  15. real(8) :: AutoMigrationRate
  16. procedure (ActionInteger), pointer :: KickPtr
  17. contains
  18. subroutine ProcessKickProblemsDueTime(time)
  19. implicit none
  20. integer :: time
  21. if(Kick%ProblemType == Time_ProblemType) call ProcessDueTime(Kick, ChangeKick, time)
  22. end subroutine
  23. subroutine ProcessKickProblemsDuePumpStrokes(strokes)
  24. implicit none
  25. integer :: strokes
  26. if(Kick%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(Kick, ChangeKick, strokes)
  27. end subroutine
  28. subroutine ProcessKickProblemsDueVolumePumped(volume)
  29. implicit none
  30. real(8) :: volume
  31. if(Kick%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(Kick, ChangeKick, volume)
  32. end subroutine
  33. subroutine ProcessKickProblemsDueDistanceDrilled(distance)
  34. implicit none
  35. real(8) :: distance
  36. if(Kick%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(Kick, ChangeKick, distance)
  37. end subroutine
  38. subroutine ChangeKick(status)
  39. implicit none
  40. integer, intent (in) :: status
  41. if(associated(KickPtr)) call KickPtr(status)
  42. !if(status == Clear_StatusType) print*,'On_Kick_Clear'
  43. !if(status == Executed_StatusType) print*,'On_Kick_Execute'
  44. endsubroutine
  45. subroutine SubscribeKick(v)
  46. !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeKick
  47. !DEC$ ATTRIBUTES ALIAS: 'SubscribeKick' :: SubscribeKick
  48. implicit none
  49. procedure (ActionInteger) :: v
  50. KickPtr => v
  51. end subroutine
  52. end module CKickProblemsVariables