Piecewise-linear function#

block

Block appearance in REPEAT VISION#

 The Piecewise linear function block creates a piecewise linear function based on an array of n+ 1 values y(t) (1):

(1)#\[ y=\frac{y_{i+1}-y_i}{t_{i+1}-t_i}∆t+y_i, если ~ t_i>t>t_{i+1} \]
\[ y=y_0,\ \ если ~ t≤t_0 \]
\[ y=y_n,\ \ если ~ t≥t_0 \]

1.  Properties#

Property

Default value

Description

Units of measurement

Vector of time arguments

0; 0.25; 0.5; 0.75

Time arguments vector

s

Vector of function values

1; 0; 2; 1

Values

-

Periodicity

On

-

-

Sampling type:
Fundamental project frequency decimation;
Sample time;
Sampling frequency

Fundamental project frequency decimation

-

-

Decimation factor of project fundamental discretization frequency, available when selecting Sampling type - Fundamental project frequency decimation

1

-

-

Sample time, available when selecting Sampling type - Sample time

0.05

-

s

Sampling frequency, available when selecting Sampling type - Sampling frequency

20.0

-

Hz

2.  Inputs and outputs#

Parameters

input/output

Description

Units of measurement

Port type

Output

Output

Signal

-

Automation

In order to see the connection capabilities of the block, you need to go to page Description of block ports

3.  Code generation#

Important

Block supports C source code generation

4.  Examples of use#

 Examples of using this block can be found in the following sections:

Tutorials

Library

Tutorial name

Thermohydraulics

Plotting of pump pressure characteristic

How-to guides

Section

Guide name

Energy

Development of a model of the industrial circuit system of oil coolers of NPP with WCWR