ExogenousData

Reading external data from a file using Modelica's CombiTimeTable format (MCTT)

Diagram

Information

This information is part of the Business Simulation Library (BSL). Please support this work and ► donate.

This block generates an output signal y_nout[:] (or y in case of a single output) by constant, linear or cubic Hermite spline interpolation in a table. The time points and function values are stored in a matrix table[i,j], where the first column table[:,1] contains the time points and the other columns contain the data to be interpolated. For more information → Modelica.Blocks.Sources.CombiTimeTable.

See also

LinearTimeTable

Parameters (14)

tableOnFile

Value: true

Type: Boolean

Description: = true, if table is defined on file or in function usertab (combiTimeTable.tableOnFile)

table

Value: fill(0.0, 2, 2)

Type: Real[:,:]

Description: Table matrix (time = first column; e.g., table=[0, 0; 1, 1; 2, 4]) (combiTimeTable.table)

tableName

Value: "NoName"

Type: String

Description: Table name on file or in function usertab (see docu) (combiTimeTable.tableName)

fileNameURI

Value: modelSettings.exogenousDataFileURI

Type: String

Description: URI for the exogenous data file

verboseRead

Value: true

Type: Boolean

Description: = true, if info message that file is loading is to be printed (combiTimeTable.verboseRead)

columns

Value: 2:size(table, 2)

Type: Integer[:]

Description: Columns of table to be interpolated (combiTimeTable.columns)

smoothness

Value: Smoothness.LinearSegments

Type: Smoothness

Description: Smoothness of table interpolation (combiTimeTable.smoothness)

extrapolation

Value: Extrapolation.LastTwoPoints

Type: Extrapolation

Description: Extrapolation of data outside the definition range (combiTimeTable.extrapolation)

timeScale

Value: 1

Type: Time (s)

Description: Time scale of first table column (combiTimeTable.timeScale)

offset

Value: {0}

Type: Real[:]

Description: Offsets of output signals (combiTimeTable.offset)

startTime

Value: 0

Type: Time (s)

Description: Output = offset for time < startTime (combiTimeTable.startTime)

shiftTime

Value: startTime

Type: Time (s)

Description: Shift time of first table column (combiTimeTable.shiftTime)

timeEvents

Value: TimeEvents.Always

Type: TimeEvents

Description: Time event handling of table interpolation (combiTimeTable.timeEvents)

verboseExtrapolation

Value: false

Type: Boolean

Description: = true, if warning messages are to be printed if time is outside the table definition range (combiTimeTable.verboseExtrapolation)

Connectors (2)

y

Type: RealOutput

Description: Single Output

y_nout

Type: RealMultiOutput[combiTimeTable.nout]

Description: Output vector

Components (2)

modelSettings

Type: ModelSettings

Description: Setting important global variables within a model

combiTimeTable

Type: CombiTimeTable

Description: Table look-up with respect to time and linear/periodic extrapolation methods (data from matrix/file)