blockLimIntegrator

Integrator with limited value of the output and optional reset

Extends from Interfaces.SISO (Single Input Single Output continuous control block).

Information

This blocks computes y as integral of the input u multiplied with the gain k. If the integral reaches a given upper or lower limit and the input will drive the integral outside of this bound, the integration is halted and only restarted if the input drives the integral away from the bounds.

It might be difficult to initialize the integrator in steady state. This is discussed in the description of package Continuous.

If parameter limitsAtInit = false, the limits of the integrator are removed from the initialization problem which leads to a much simpler equation system. After initialization has been performed, it is checked via an assert whether the output is in the defined limits. For backward compatibility reasons limitsAtInit = true. In most cases it is best to use limitsAtInit = false.

If the reset port is enabled, then the output y is reset to set or to y_start (if the set port is not enabled), whenever the reset port has a rising edge.

Parameters

TypeNameDefaultDescription
Realk1Integrator gain
RealoutMaxUpper limit of output
RealoutMin-outMaxLower limit of output
Booleanuse_resetfalse= true, if reset port enabled
Booleanuse_setfalse= true, if set port enabled and used as reinitialization value when reset
Initialization
InitinitTypeInit.InitialStateType of initialization (1: no init, 2: steady state, 3/4: initial output)
BooleanlimitsAtInittrue= false, if limits are ignored during initialization (i.e., der(y)=k*u)
Realy_start0Initial or guess value of output (must be in the limits outMin .. outMax)
Advanced
Booleanstrictfalse= true, if strict limits with noEvent(..)

Connectors

TypeNameDefaultDescription
RealInputu (from SISO)Connector of Real input signal
RealOutputy (from SISO)Connector of Real output signal
Modelica.Blocks.Interfaces.BooleanInputresetOptional connector of reset signal
Modelica.Blocks.Interfaces.RealInputsetOptional connector of set signal