Simulation Core
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 
 
 
 
 

99 rindas
3.7 KiB

  1. module CBitProblemsVariables
  2. use CProblemDifinition
  3. use CLog3
  4. implicit none
  5. public
  6. ! Input vars
  7. type:: BitProblemsType
  8. type(CProblem) :: PlugJets
  9. type(CProblem) :: JetWashout
  10. integer :: PlugJetsCount
  11. integer :: JetWashoutCount
  12. ! procedure (ActionInteger), pointer :: PlugJetsPtr
  13. ! procedure (ActionInteger), pointer :: JetWashoutPtr
  14. end type BitProblemsType
  15. type(BitProblemsType)::BitProblems
  16. contains
  17. subroutine ProcessBitProblemsDueTime(time)
  18. implicit none
  19. integer :: time
  20. if(BitProblems%PlugJets%ProblemType == Time_ProblemType) call ProcessDueTime(BitProblems%PlugJets, ChangePlugJets, time)
  21. if(BitProblems%JetWashout%ProblemType == Time_ProblemType) call ProcessDueTime(BitProblems%JetWashout, ChangeJetWashout, time)
  22. end subroutine
  23. subroutine ProcessBitProblemsDuePumpStrokes(strokes)
  24. implicit none
  25. integer :: strokes
  26. if(BitProblems%PlugJets%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(BitProblems%PlugJets, ChangePlugJets, strokes)
  27. if(BitProblems%JetWashout%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(BitProblems%JetWashout, ChangeJetWashout, strokes)
  28. end subroutine
  29. subroutine ProcessBitProblemsDueVolumePumped(volume)
  30. implicit none
  31. real(8) :: volume
  32. if(BitProblems%PlugJets%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(BitProblems%PlugJets, ChangePlugJets, volume)
  33. if(BitProblems%JetWashout%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(BitProblems%JetWashout, ChangeJetWashout, volume)
  34. end subroutine
  35. subroutine ProcessBitProblemsDueDistanceDrilled(distance)
  36. implicit none
  37. real(8) :: distance
  38. if(BitProblems%PlugJets%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(BitProblems%PlugJets, ChangePlugJets, distance)
  39. if(BitProblems%JetWashout%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(BitProblems%JetWashout, ChangeJetWashout, distance)
  40. end subroutine
  41. subroutine ChangePlugJets(status)
  42. USE FricPressDropVarsModule
  43. implicit none
  44. integer, intent (in) :: status
  45. ! if(associated(BitProblems%PlugJetsPtr)) call BitProblems%PlugJetsPtr(status)
  46. if(status == Clear_StatusType) FricPressDropVars%BitJetsPlugged = 0
  47. if(status == Executed_StatusType) FricPressDropVars%BitJetsPlugged = 1
  48. endsubroutine
  49. subroutine ChangeJetWashout(status)
  50. USE FricPressDropVarsModule
  51. implicit none
  52. integer, intent (in) :: status
  53. ! if(associated(BitProblems%JetWashoutPtr)) call BitProblems%JetWashoutPtr(status)
  54. if(status == Clear_StatusType) FricPressDropVars%BitJetsWashedOut = 0
  55. if(status == Executed_StatusType) FricPressDropVars%BitJetsWashedOut = 1
  56. endsubroutine
  57. ! subroutine SubscribePlugJets(v)
  58. ! !DEC$ ATTRIBUTES DLLEXPORT :: SubscribePlugJets
  59. ! !DEC$ ATTRIBUTES ALIAS: 'SubscribePlugJets' :: SubscribePlugJets
  60. ! implicit none
  61. ! procedure (ActionInteger) :: v
  62. ! BitProblems%PlugJetsPtr => v
  63. ! end subroutine
  64. ! subroutine SubscribeJetWashout(v)
  65. ! !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeJetWashout
  66. ! !DEC$ ATTRIBUTES ALIAS: 'SubscribeJetWashout' :: SubscribeJetWashout
  67. ! implicit none
  68. ! procedure (ActionInteger) :: v
  69. ! BitProblems%JetWashoutPtr => v
  70. ! end subroutine
  71. end module CBitProblemsVariables