modelLimitController

Limits electrical power consumption

Information

The LimitController restricts the heating system’s thermal output based on a power limit signal. When P_limit_active is true, a PI controller (PID_reset_lim) regulates output so the measured heating power P_Heating tracks P_limit. When inactive, the output is set to Q_limit_not_active.

Key features

  • PI control with reset when limiter is inactive (xi_start = Q_nom).
  • Variable maximum output: P_limit when active, Q_limit_not_active when inactive.
  • Minimum output fixed at zero.
  • First-order lag (breakAlgebraicLoop) to avoid algebraic loops in feedback.

Logic

  1. Switch selects setpoint from P_limit or Q_limit_not_active based on P_limit_active.
  2. PI controller regulates within [0, Q_limit_not_active].
  3. Reset triggered when limiter turns off.
  4. Output PID_limit sent to actuator/supervisory control.

Parameters

TypeNameDefaultDescription
Modelica.Units.SI.HeatFlowRateQ_limit_not_activeMaximum thermal heat flow rate if limiter is not active
Modelica.Units.SI.HeatFlowRateQ_nomNominal heat flow rate of heating system

Connectors

TypeNameDefaultDescription
Modelica.Blocks.Interfaces.RealOutputPID_limitConnector of actuator output signal
Modelica.Blocks.Interfaces.RealInputP_limit
Modelica.Blocks.Interfaces.BooleanInputP_limit_active
Modelica.Blocks.Interfaces.RealInputP_Heating

Components

TypeNameDefaultDescription
Modelica.Blocks.Continuous.FirstOrderbreakAlgebraicLoop
Modelica.Blocks.Math.FeedbackcontrolError_P_Limit
Basics.Blocks.PID_reset_limcontroller_P_Limit
Modelica.Blocks.Logical.SwitchP_limit_active_switch
Modelica.Blocks.Sources.RealExpressionQ_varLimiter_max
Modelica.Blocks.Logical.Notnot2
Modelica.Blocks.Sources.RealExpressionQ_varLimiter_min
Basics.Blocks.Hysteresis_inputVariableactive
Modelica.Blocks.Math.Addadd
Modelica.Blocks.Sources.RealExpressiondeactivationOffset
Modelica.Blocks.Sources.RealExpressionactivationOffset
Modelica.Blocks.Math.Addadd1
Modelica.Blocks.Logical.Oror1
Modelica.Blocks.Logical.Changechange1
Modelica.Blocks.Math.GainCOP_best
Modelica.Blocks.Logical.SwitchP_limit_active_switch1