blockLimPID

P, PI, PD, and PID controller with limited output, anti-windup compensation and delayed, smooth activation

Information

For detailed model documentation please consult the html-documentation shipped with ClaRa.

 


Authorship and Copyright Statement for original (initial) Contribution

Author:

DYNCAP/DYNSTART development team, Copyright © 2011-2024.

References:

For references please consult the html-documentation shipped with ClaRa.

Remarks:

This component was developed by ClaRa development team under the 3-clause BSD License.

Acknowledgements:

ClaRa originated from the collaborative research projects DYNCAP and DYNSTART. Both research projects were supported by the German Federal Ministry for Economic Affairs and Energy (FKZ 03ET2009 and FKZ 03ET7060).

CLA:

The author(s) have agreed to ClaRa CLA, version 1.0. See https://claralib.com/pdf/CLA.pdf

By agreeing to ClaRa CLA, version 1.0 the author has granted the ClaRa development team a permanent right to use and modify his initial contribution as well as to publish it or its modified versions under the 3-clause BSD License.

The ClaRa development team consists of the following partners:

TLK-Thermo GmbH (Braunschweig, Germany)

XRG Simulation GmbH (Hamburg, Germany).

Parameters

TypeNameDefaultDescription
General Design of Controller
Modelica.Blocks.Types.SimpleControllercontrollerTypeModelica.Blocks.Types.SimpleController.PIDType of controller
Realsign1set to 1 if a positive control error leads to a positive control output, else -1
Normalisation of I/O Signals
BooleanperUnitConversiontrueTrue, if input and output values should be normalised with respect to reference values
Realu_ref1Reference value for controlled variable
Realy_ref1Reference value for actuated variable
Limiter for Controller Output
Realy_max1Upper limit of output
Realy_min-y_maxLower limit of output
Time Response of the Controller
Realk1Gain of Proportional block
Modelica.Units.SI.TimeTau_i0.51/Ti is gain of integrator block
Modelica.Units.SI.TimeTau_d0.1Gain of derivative block
Anti-Windup Compensation
Modelica.Units.SI.TimeNi0.91/Ni is gain of anti-windup compensation
Derivative Filtering
RealNd1The smaller Nd, the more ideal the derivative block, setting Nd=0 introduces ideal derivative
Controller activation
Booleanuse_activateInputfalseProvide Boolean input to switch controller on/off.
ClaRa.Basics.Units.Timet_activation0.0Time when controller is switched on. For use_activateInput==true the controller is switched on if (time>t_activation AND activateController=true).
ClaRa.Basics.Units.TimeTau_lag_I0.0Time lag for activation of integral part AFTER controller is being switched on
Realy_inactive1Controller output if controller is not active
I/O Filters
RealTau_in0Time constant for input smoothening, Tau_in=0 refers to signal no smoothening
RealTau_out0time constant for output smoothening, Tau_out=0 refers to signal no smoothening
Initialisation
IntegerinitOption501Initialisation option
BooleanlimitsAtInittrue= false, if limits are ignored during initializiation
Realxi_start0Initial or guess value value for integrator output (= integrator state)
Realy_start0Initial value of output
Expert Settings › DAE Index Reduction
RealTau_add0Set to >0 for additional state after add block in controller, if DAE-index reduction fails.
Expert Settings › Obsolete Settings
Realxd_start0Initial or guess value for state of derivative block

Connectors

TypeNameDefaultDescription
Modelica.Blocks.Interfaces.RealInputu_sConnector of setpoint input signal
Modelica.Blocks.Interfaces.RealInputu_mConnector of measurement input signal
Modelica.Blocks.Interfaces.BooleanInputactivateInputtrue, if controller is on
Modelica.Blocks.Interfaces.RealOutputyConnector of actuator output signal

Components

TypeNameDefaultDescription
RealcontrolErroru_s - u_mControl error (set point - measurement)
Modelica.Blocks.Math.GainP
ClaRa.Components.Utilities.Blocks.IntegratorI
ClaRa.Components.Utilities.Blocks.DerivativeClaRaD_approx
Modelica.Blocks.Math.Add3addPID
Modelica.Blocks.Math.AddaddI
Modelica.Blocks.Math.GaingainTrack
Modelica.Blocks.Nonlinear.Limiterlimiter
Modelica.Blocks.Sources.ConstantDzero
Modelica.Blocks.Sources.RealExpressionIzero
Modelica.Blocks.Math.GaintoPUconvert input values to "per unit"
Modelica.Blocks.Math.Feedbackfeedback
Modelica.Blocks.Math.GainfromPUconvert output values to "Real"
Modelica.Blocks.Logical.Switchswitch_OnOff_I
Modelica.Blocks.Sources.ConstantI_off_zero
Modelica.Blocks.Logical.Switchswitch_OnOff
Modelica.Blocks.Sources.RealExpressiony_unlocked
ClaRa.Components.Utilities.Blocks.FirstOrderClaRasmoothPIDInput
ClaRa.Components.Utilities.Blocks.FirstOrderClaRasmoothPIDOutput
Modelica.Blocks.Math.FeedbackaddSat
ClaRa.Components.Utilities.Blocks.FirstOrderClaRasmoothPIDOutput1
Modelica.Blocks.Sources.RealExpressiony_start_I
Modelica.Blocks.Math.FeedbackresetP
Modelica.Blocks.Sources.RealExpressiony_unlocked1
Modelica.Blocks.Math.AddresetPD
Modelica.Blocks.Sources.RealExpressiony_unlocked2
Modelica.Blocks.Sources.BooleanExpressionactivate_
Modelica.Blocks.Logical.Timertime_lag_I_activation
Modelica.Blocks.Logical.AndcontrollerActive
Modelica.Blocks.Routing.BooleanPassThroughbooleanPassThrough
Modelica.Blocks.Logical.GreaterThresholdI_activation

Revisions

For revisions please consult the html-documentation shipped with ClaRa.