Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | ControlNum |
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
LOGICAL FUNCTION CheckMinActiveController( ControlNum )
! FUNCTION INFORMATION:
! AUTHOR Dimitri Curtil
! DATE WRITTEN May 2006
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS FUNCTION:
! Returns true if controller is min-constrained. false otherwise.
! METHODOLOGY EMPLOYED:
! na
! REFERENCES:
! na
! USE STATEMENTS:
! na
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! FUNCTION ARGUMENT DEFINITIONS:
INTEGER, INTENT(IN) :: ControlNum
! FUNCTION PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! FUNCTION LOCAL VARIABLE DECLARATIONS:
! na
CheckMinActiveController = .FALSE.
! Check that actuated value is the min avail actuated value
IF ( ControllerProps(ControlNum)%ActuatedValue /= ControllerProps(ControlNum)%MinAvailActuated ) THEN
CheckMinActiveController = .FALSE.
RETURN
END IF
SelectAction: SELECT CASE (ControllerProps(ControlNum)%Action)
CASE (iNormalAction) ! "NORMAL"
! Check for min constrained convergence
IF (ControllerProps(ControlNum)%SetPointValue <= ControllerProps(ControlNum)%SensedValue) THEN
CheckMinActiveController = .TRUE.
RETURN
END IF
CASE (iReverseAction) ! "REVERSE"
! Check for min constrained convergence
IF (ControllerProps(ControlNum)%SetPointValue >= ControllerProps(ControlNum)%SensedValue) THEN
CheckMinActiveController = .TRUE.
RETURN
END IF
CASE DEFAULT
! Should never happen
CALL ShowSevereError( &
'CheckMinActiveController: Invalid controller action during '//TRIM(CreateHVACStepFullString())//'.' &
)
CALL ShowContinueError( &
'CheckMinActiveController: Controller name='//TRIM(ControllerProps(ControlNum)%ControllerName) &
)
CALL ShowContinueError('CheckMinActiveController: Valid choices are "NORMAL" or "REVERSE"')
CALL ShowFatalError('CheckMinActiveController: Preceding error causes program termination.')
END SELECT SelectAction
RETURN
END FUNCTION CheckMinActiveController