LimIntegrator

Integrator with limited value of the output and optional reset

    LimIntegrator

Library

Modelica/Blocks/Continuous

Description

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

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

If parameter limitAtInit = false, the limits of theintegrator are removed from the initialization problem whichleads to a much simpler equation system. After initialization has beenperformed, it is checked via an assert whether the output is in thedefined limits. For backward compatibility reasonslimitAtInit = true. In most cases it is bestto use limitAtInit = false.

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

Parameters

LimIntegrator_0

NameLabelDescriptionData TypeValid Values

mo_k

k

Integrator gain

Scalar

mo_outMax

outMax

Upper limit of output

Scalar

mo_outMin

outMin

Lower limit of output

Scalar

mo_use_reset

use_reset

=true, if reset port enabled

Number

0
1

mo_use_set

use_set

=true, if set port enabled and used as reinitialization value when reset

Number

0
1

mo_initType

initType

Type of initialization (1: no init, 2: steady state, 3/4: initial output)

Structure

mo_initType/choice1

No initialization (start values are used as guess values with fixed=false)

Number

0
1

mo_initType/choice2

Steady state initialization (derivatives of states are zero)

Number

0
1

mo_initType/choice3

Initialization with initial states

Number

0
1

mo_initType/choice4

Initialization with initial outputs (and steady state of the states if possible)

Number

0
1

mo_limitsAtInit

limitsAtInit

= false, if limits are ignored during initialization (i.e., der(y)=k*u)

Scalar

true
false

mo_y_start

y_start

Initial or guess value of output (must be in the limits outMin .. outMax)

Scalar

LimIntegrator_1

NameLabelDescriptionData TypeValid Values

mo_strict

strict

= true, if strict limits with noEvent(..)

Scalar

true
false

LimIntegrator_2

NameLabelDescriptionData TypeValid Values

mo__nmodifiers

Number of Modifiers

Specifies the number of modifiers

Number

mo__modifiers

Modifiers

Add new modifier

Structure

mo__modifiers/varname

Variable name

Cell of strings

mo__modifiers/attribute

Attribute

Cell of strings

'start'
'fixed'

mo__modifiers/value

Value

Ports

NameTypeDescriptionIO TypeNumber

u

implicit

Connector of Real input signal

input

1

y

implicit

Connector of Real output signal

output

1

Port 3

implicit

Optional connector of reset signal

input

mo_use_reset

Port 4

implicit

Optional connector of set signal

input

mo_use_reset&&mo_use_set

See Also