blockLinearPiecewiseTwo

A two-pieces linear piecewise function

Extends from Modelica.Blocks.Icons.Block (Basic graphical layout of input/output block).

Information

This component calcuates the output according to two piecewise linear function as

x0 ≤ u ≤ x1: y1 = y10 + u (y11-y10)/(x1-x0)
y2 = y20
x1 < u ≤ x2: y1 = y11
y2 = y20 + (u-x1) (y21-y20)/(x2-x1)

Parameters

TypeNameDefaultDescription
Realx0First interval [x0, x1]
Realx1First interval [x0, x1] and second interval (x1, x2]
Realx2Second interval (x1, x2]
Realy10y[1] at u = x0
Realy11y[1] at u = x1
Realy20y[2] at u = x1
Realy21y[2] at u = x2

Connectors

TypeNameDefaultDescription
Modelica.Blocks.Interfaces.RealInputuSet point
Modelica.Blocks.Interfaces.RealOutput[2]yConnectors of Real output signal

Components

TypeNameDefaultDescription
Buildings.Controls.SetPoints.Tabley1TabTable for y[1]
Buildings.Controls.SetPoints.Tabley2TabTable for y[2]

Revisions

  • July 20, 2011, by Wangda Zuo:
    Add comments and merge to library.
  • January 18, 2011, by Wangda Zuo:
    First implementation.