|
- module CChokeProblemsVariables
- use CProblemDifinition
-
- implicit none
- public
-
- ! Input vars
- type(CProblem) :: HydraulicChoke1Plugged
- type(CProblem) :: HydraulicChoke1Fail
- type(CProblem) :: HydraulicChoke1Washout
- integer :: HydraulicChoke1PluggedPercent
- type(CProblem) :: HydraulicChoke2Plugged
- type(CProblem) :: HydraulicChoke2Fail
- type(CProblem) :: HydraulicChoke2Washout
- integer :: HydraulicChoke2PluggedPercent
- type(CProblem) :: ManualChoke1Plugged
- type(CProblem) :: ManualChoke1Fail
- type(CProblem) :: ManualChoke1Washout
- integer :: ManualChoke1PluggedPercent
- type(CProblem) :: ManualChoke2Plugged
- type(CProblem) :: ManualChoke2Fail
- type(CProblem) :: ManualChoke2Washout
- integer :: ManualChoke2PluggedPercent
- type(CProblem) :: ChokePanelAirFail
-
- procedure (ActionInteger), pointer :: HydraulicChoke1PluggedPtr
- procedure (ActionInteger), pointer :: HydraulicChoke1FailPtr
- procedure (ActionInteger), pointer :: HydraulicChoke1WashoutPtr
- procedure (ActionInteger), pointer :: HydraulicChoke2PluggedPtr
- procedure (ActionInteger), pointer :: HydraulicChoke2FailPtr
- procedure (ActionInteger), pointer :: HydraulicChoke2WashoutPtr
- procedure (ActionInteger), pointer :: ManualChoke1PluggedPtr
- procedure (ActionInteger), pointer :: ManualChoke1FailPtr
- procedure (ActionInteger), pointer :: ManualChoke1WashoutPtr
- procedure (ActionInteger), pointer :: ManualChoke2PluggedPtr
- procedure (ActionInteger), pointer :: ManualChoke2FailPtr
- procedure (ActionInteger), pointer :: ManualChoke2WashoutPtr
- procedure (ActionInteger), pointer :: ChokePanelAirFailPtr
-
- contains
-
- subroutine ProcessChokeProblemsDueTime(time)
- implicit none
- integer :: time
- if(HydraulicChoke1Plugged%ProblemType == Time_ProblemType) call ProcessDueTime(HydraulicChoke1Plugged, ChangeHydraulicChoke1Plugged, time)
- if(HydraulicChoke1Fail%ProblemType == Time_ProblemType) call ProcessDueTime(HydraulicChoke1Fail, ChangeHydraulicChoke1Fail, time)
- if(HydraulicChoke1Washout%ProblemType == Time_ProblemType) call ProcessDueTime(HydraulicChoke1Washout, ChangeHydraulicChoke1Washout, time)
- if(HydraulicChoke2Plugged%ProblemType == Time_ProblemType) call ProcessDueTime(HydraulicChoke2Plugged, ChangeHydraulicChoke2Plugged, time)
- if(HydraulicChoke2Fail%ProblemType == Time_ProblemType) call ProcessDueTime(HydraulicChoke2Fail, ChangeHydraulicChoke2Fail, time)
- if(HydraulicChoke2Washout%ProblemType == Time_ProblemType) call ProcessDueTime(HydraulicChoke2Washout, ChangeHydraulicChoke2Washout, time)
- if(ManualChoke1Plugged%ProblemType == Time_ProblemType) call ProcessDueTime(ManualChoke1Plugged, ChangeManualChoke1Plugged, time)
- if(ManualChoke1Fail%ProblemType == Time_ProblemType) call ProcessDueTime(ManualChoke1Fail, ChangeManualChoke1Fail, time)
- if(ManualChoke1Washout%ProblemType == Time_ProblemType) call ProcessDueTime(ManualChoke1Washout, ChangeManualChoke1Washout, time)
- if(ManualChoke2Plugged%ProblemType == Time_ProblemType) call ProcessDueTime(ManualChoke2Plugged, ChangeManualChoke2Plugged, time)
- if(ManualChoke2Fail%ProblemType == Time_ProblemType) call ProcessDueTime(ManualChoke2Fail, ChangeManualChoke2Fail, time)
- if(ManualChoke2Washout%ProblemType == Time_ProblemType) call ProcessDueTime(ManualChoke2Washout, ChangeManualChoke2Washout, time)
- if(ChokePanelAirFail%ProblemType == Time_ProblemType) call ProcessDueTime(ChokePanelAirFail, ChangeChokePanelAirFail, time)
- end subroutine
-
- subroutine ProcessChokeProblemsDuePumpStrokes(strokes)
- implicit none
- integer :: strokes
- if(HydraulicChoke1Plugged%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(HydraulicChoke1Plugged, ChangeHydraulicChoke1Plugged, strokes)
- if(HydraulicChoke1Fail%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(HydraulicChoke1Fail, ChangeHydraulicChoke1Fail, strokes)
- if(HydraulicChoke1Washout%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(HydraulicChoke1Washout, ChangeHydraulicChoke1Washout, strokes)
- if(HydraulicChoke2Plugged%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(HydraulicChoke2Plugged, ChangeHydraulicChoke2Plugged, strokes)
- if(HydraulicChoke2Fail%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(HydraulicChoke2Fail, ChangeHydraulicChoke2Fail, strokes)
- if(HydraulicChoke2Washout%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(HydraulicChoke2Washout, ChangeHydraulicChoke2Washout, strokes)
- if(ManualChoke1Plugged%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ManualChoke1Plugged, ChangeManualChoke1Plugged, strokes)
- if(ManualChoke1Fail%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ManualChoke1Fail, ChangeManualChoke1Fail, strokes)
- if(ManualChoke1Washout%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ManualChoke1Washout, ChangeManualChoke1Washout, strokes)
- if(ManualChoke2Plugged%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ManualChoke2Plugged, ChangeManualChoke2Plugged, strokes)
- if(ManualChoke2Fail%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ManualChoke2Fail, ChangeManualChoke2Fail, strokes)
- if(ManualChoke2Washout%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ManualChoke2Washout, ChangeManualChoke2Washout, strokes)
- if(ChokePanelAirFail%ProblemType == PumpStrokes_ProblemType) call ProcessDuePumpStrokes(ChokePanelAirFail, ChangeChokePanelAirFail, strokes)
- end subroutine
-
- subroutine ProcessChokeProblemsDueVolumePumped(volume)
- implicit none
- real(8) :: volume
- if(HydraulicChoke1Plugged%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(HydraulicChoke1Plugged, ChangeHydraulicChoke1Plugged, volume)
- if(HydraulicChoke1Fail%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(HydraulicChoke1Fail, ChangeHydraulicChoke1Fail, volume)
- if(HydraulicChoke1Washout%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(HydraulicChoke1Washout, ChangeHydraulicChoke1Washout, volume)
- if(HydraulicChoke2Plugged%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(HydraulicChoke2Plugged, ChangeHydraulicChoke2Plugged, volume)
- if(HydraulicChoke2Fail%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(HydraulicChoke2Fail, ChangeHydraulicChoke2Fail, volume)
- if(HydraulicChoke2Washout%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(HydraulicChoke2Washout, ChangeHydraulicChoke2Washout, volume)
- if(ManualChoke1Plugged%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ManualChoke1Plugged, ChangeManualChoke1Plugged, volume)
- if(ManualChoke1Fail%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ManualChoke1Fail, ChangeManualChoke1Fail, volume)
- if(ManualChoke1Washout%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ManualChoke1Washout, ChangeManualChoke1Washout, volume)
- if(ManualChoke2Plugged%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ManualChoke2Plugged, ChangeManualChoke2Plugged, volume)
- if(ManualChoke2Fail%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ManualChoke2Fail, ChangeManualChoke2Fail, volume)
- if(ManualChoke2Washout%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ManualChoke2Washout, ChangeManualChoke2Washout, volume)
- if(ChokePanelAirFail%ProblemType == VolumePumped_ProblemType) call ProcessDueVolumePumped(ChokePanelAirFail, ChangeChokePanelAirFail, volume)
- end subroutine
-
- subroutine ProcessChokeProblemsDueDistanceDrilled(distance)
- implicit none
- real(8) :: distance
- if(HydraulicChoke1Plugged%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(HydraulicChoke1Plugged, ChangeHydraulicChoke1Plugged, distance)
- if(HydraulicChoke1Fail%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(HydraulicChoke1Fail, ChangeHydraulicChoke1Fail, distance)
- if(HydraulicChoke1Washout%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(HydraulicChoke1Washout, ChangeHydraulicChoke1Washout, distance)
- if(HydraulicChoke2Plugged%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(HydraulicChoke2Plugged, ChangeHydraulicChoke2Plugged, distance)
- if(HydraulicChoke2Fail%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(HydraulicChoke2Fail, ChangeHydraulicChoke2Fail, distance)
- if(HydraulicChoke2Washout%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(HydraulicChoke2Washout, ChangeHydraulicChoke2Washout, distance)
- if(ManualChoke1Plugged%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ManualChoke1Plugged, ChangeManualChoke1Plugged, distance)
- if(ManualChoke1Fail%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ManualChoke1Fail, ChangeManualChoke1Fail, distance)
- if(ManualChoke1Washout%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ManualChoke1Washout, ChangeManualChoke1Washout, distance)
- if(ManualChoke2Plugged%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ManualChoke2Plugged, ChangeManualChoke2Plugged, distance)
- if(ManualChoke2Fail%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ManualChoke2Fail, ChangeManualChoke2Fail, distance)
- if(ManualChoke2Washout%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ManualChoke2Washout, ChangeManualChoke2Washout, distance)
- if(ChokePanelAirFail%ProblemType == DistanceDrilled_ProblemType) call ProcessDueDistanceDrilled(ChokePanelAirFail, ChangeChokePanelAirFail, distance)
- end subroutine
-
-
-
-
- subroutine ChangeHydraulicChoke1Plugged(status)
- USE CHOKEVARIABLES
- implicit none
- integer, intent (in) :: status
- if(associated(HydraulicChoke1PluggedPtr)) call HydraulicChoke1PluggedPtr(status)
- if(status == Clear_StatusType) CHOOKE(1)%PlugMalf = 0
- if(status == Executed_StatusType) CHOOKE(1)%PlugMalf = 1
- endsubroutine
-
- subroutine ChangeHydraulicChoke1Fail(status)
- USE CHOKEVARIABLES
- implicit none
- integer, intent (in) :: status
- if(associated(HydraulicChoke1FailPtr)) call HydraulicChoke1FailPtr(status)
- if(status == Clear_StatusType) CHOOKE(1)%FailMalf = 0
- if(status == Executed_StatusType) CHOOKE(1)%FailMalf = 1
- endsubroutine
-
- subroutine ChangeHydraulicChoke1Washout(status)
- USE CHOKEVARIABLES
- use CChokeManifoldVariables
- implicit none
- integer, intent (in) :: status
- if(associated(HydraulicChoke1WashoutPtr)) call HydraulicChoke1WashoutPtr(status)
- if(status == Clear_StatusType) CHOOKE(1)%WashoutMalf = 0
- if(status == Executed_StatusType) CHOOKE(1)%WashoutMalf = 1
-
- if(status == Clear_StatusType) HyChock1OnProblem = .false.
- if(status == Executed_StatusType) HyChock1OnProblem = .true.
- endsubroutine
-
- subroutine ChangeHydraulicChoke2Plugged(status)
- USE CHOKEVARIABLES
- implicit none
- integer, intent (in) :: status
- if(associated(HydraulicChoke2PluggedPtr)) call HydraulicChoke2PluggedPtr(status)
- if(status == Clear_StatusType) CHOOKE(2)%PlugMalf = 0
- if(status == Executed_StatusType) CHOOKE(2)%PlugMalf = 1
- endsubroutine
-
- subroutine ChangeHydraulicChoke2Fail(status)
- USE CHOKEVARIABLES
- implicit none
- integer, intent (in) :: status
- if(associated(HydraulicChoke2FailPtr)) call HydraulicChoke2FailPtr(status)
- if(status == Clear_StatusType) CHOOKE(2)%FailMalf = 0
- if(status == Executed_StatusType) CHOOKE(2)%FailMalf = 1
- endsubroutine
-
- subroutine ChangeHydraulicChoke2Washout(status)
- USE CHOKEVARIABLES
- use CChokeManifoldVariables
- implicit none
- integer, intent (in) :: status
- if(associated(HydraulicChoke2WashoutPtr)) call HydraulicChoke2WashoutPtr(status)
- if(status == Clear_StatusType) CHOOKE(2)%WashoutMalf = 0
- if(status == Executed_StatusType) CHOOKE(2)%WashoutMalf = 1
-
- if(status == Clear_StatusType) HyChock2OnProblem = .false.
- if(status == Executed_StatusType) HyChock2OnProblem = .true.
- endsubroutine
-
- subroutine ChangeManualChoke1Plugged(status)
- USE FricPressDropVars
- implicit none
- integer, intent (in) :: status
- if(associated(ManualChoke1PluggedPtr)) call ManualChoke1PluggedPtr(status)
- if(status == Clear_StatusType) ManChoke1Plug = 0
- if(status == Executed_StatusType) ManChoke1Plug = 1
- endsubroutine
-
- subroutine ChangeManualChoke1Fail(status)
- implicit none
- integer, intent (in) :: status
- if(associated(ManualChoke1FailPtr)) call ManualChoke1FailPtr(status)
- !if(status == Clear_StatusType) print*,'On_ManualChoke1Fail_Clear'
- !if(status == Executed_StatusType) print*,'On_ManualChoke1Fail_Execute'
- endsubroutine
-
- subroutine ChangeManualChoke1Washout(status)
- USE FricPressDropVars
- use CChokeManifoldVariables
- implicit none
- integer, intent (in) :: status
- if(associated(ManualChoke1WashoutPtr)) call ManualChoke1WashoutPtr(status)
- if(status == Clear_StatusType) ManChoke1Washout = 0
- if(status == Executed_StatusType) ManChoke1Washout = 1
-
- if(status == Clear_StatusType) LeftManChokeOnProblem = .false.
- if(status == Executed_StatusType) LeftManChokeOnProblem = .true.
- endsubroutine
-
- subroutine ChangeManualChoke2Plugged(status)
- USE FricPressDropVars
- implicit none
- integer, intent (in) :: status
- if(associated(ManualChoke2PluggedPtr)) call ManualChoke2PluggedPtr(status)
- if(status == Clear_StatusType) ManChoke2Plug = 0
- if(status == Executed_StatusType) ManChoke2Plug = 1
- endsubroutine
-
- subroutine ChangeManualChoke2Fail(status)
- implicit none
- integer, intent (in) :: status
- if(associated(ManualChoke2FailPtr)) call ManualChoke2FailPtr(status)
- !if(status == Clear_StatusType) print*,'On_ManualChoke2Fail_Clear'
- !if(status == Executed_StatusType) print*,'On_ManualChoke2Fail_Execute'
- endsubroutine
-
- subroutine ChangeManualChoke2Washout(status)
- USE FricPressDropVars
- use CChokeManifoldVariables
- implicit none
- integer, intent (in) :: status
- if(associated(ManualChoke2WashoutPtr)) call ManualChoke2WashoutPtr(status)
- if(status == Clear_StatusType) ManChoke2Washout = 0
- if(status == Executed_StatusType) ManChoke2Washout = 1
-
- if(status == Clear_StatusType) RightManChokeOnProblem = .false.
- if(status == Executed_StatusType) RightManChokeOnProblem = .true.
- endsubroutine
-
- subroutine ChangeChokePanelAirFail(status)
- USE CHOKEVARIABLES
- implicit none
- integer, intent (in) :: status
- if(associated(ChokePanelAirFailPtr)) call ChokePanelAirFailPtr(status)
- if(status == Clear_StatusType) ChokeAirFail = 0
- if(status == Executed_StatusType) ChokeAirFail = 1
- endsubroutine
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- subroutine SubscribeHydraulicChoke1Plugged(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeHydraulicChoke1Plugged
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeHydraulicChoke1Plugged' :: SubscribeHydraulicChoke1Plugged
- implicit none
- procedure (ActionInteger) :: v
- HydraulicChoke1PluggedPtr => v
- end subroutine
-
- subroutine SubscribeHydraulicChoke1Fail(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeHydraulicChoke1Fail
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeHydraulicChoke1Fail' :: SubscribeHydraulicChoke1Fail
- implicit none
- procedure (ActionInteger) :: v
- HydraulicChoke1FailPtr => v
- end subroutine
-
- subroutine SubscribeHydraulicChoke1Washout(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeHydraulicChoke1Washout
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeHydraulicChoke1Washout' :: SubscribeHydraulicChoke1Washout
- implicit none
- procedure (ActionInteger) :: v
- HydraulicChoke1WashoutPtr => v
- end subroutine
-
- subroutine SubscribeHydraulicChoke2Plugged(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeHydraulicChoke2Plugged
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeHydraulicChoke2Plugged' :: SubscribeHydraulicChoke2Plugged
- implicit none
- procedure (ActionInteger) :: v
- HydraulicChoke2PluggedPtr => v
- end subroutine
-
- subroutine SubscribeHydraulicChoke2Fail(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeHydraulicChoke2Fail
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeHydraulicChoke2Fail' :: SubscribeHydraulicChoke2Fail
- implicit none
- procedure (ActionInteger) :: v
- HydraulicChoke2FailPtr => v
- end subroutine
-
- subroutine SubscribeHydraulicChoke2Washout(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeHydraulicChoke2Washout
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeHydraulicChoke2Washout' :: SubscribeHydraulicChoke2Washout
- implicit none
- procedure (ActionInteger) :: v
- HydraulicChoke2WashoutPtr => v
- end subroutine
-
- subroutine SubscribeManualChoke1Plugged(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeManualChoke1Plugged
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeManualChoke1Plugged' :: SubscribeManualChoke1Plugged
- implicit none
- procedure (ActionInteger) :: v
- ManualChoke1PluggedPtr => v
- end subroutine
-
- subroutine SubscribeManualChoke1Fail(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeManualChoke1Fail
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeManualChoke1Fail' :: SubscribeManualChoke1Fail
- implicit none
- procedure (ActionInteger) :: v
- ManualChoke1FailPtr => v
- end subroutine
-
- subroutine SubscribeManualChoke1Washout(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeManualChoke1Washout
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeManualChoke1Washout' :: SubscribeManualChoke1Washout
- implicit none
- procedure (ActionInteger) :: v
- ManualChoke1WashoutPtr => v
- end subroutine
-
- subroutine SubscribeManualChoke2Plugged(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeManualChoke2Plugged
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeManualChoke2Plugged' :: SubscribeManualChoke2Plugged
- implicit none
- procedure (ActionInteger) :: v
- ManualChoke2PluggedPtr => v
- end subroutine
-
- subroutine SubscribeManualChoke2Fail(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeManualChoke2Fail
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeManualChoke2Fail' :: SubscribeManualChoke2Fail
- implicit none
- procedure (ActionInteger) :: v
- ManualChoke2FailPtr => v
- end subroutine
-
- subroutine SubscribeManualChoke2Washout(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeManualChoke2Washout
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeManualChoke2Washout' :: SubscribeManualChoke2Washout
- implicit none
- procedure (ActionInteger) :: v
- ManualChoke2WashoutPtr => v
- end subroutine
-
- subroutine SubscribeChokePanelAirFail(v)
- !DEC$ ATTRIBUTES DLLEXPORT :: SubscribeChokePanelAirFail
- !DEC$ ATTRIBUTES ALIAS: 'SubscribeChokePanelAirFail' :: SubscribeChokePanelAirFail
- implicit none
- procedure (ActionInteger) :: v
- ChokePanelAirFailPtr => v
- end subroutine
-
- end module CChokeProblemsVariables
|