blockTimeConversion

Converts a time signal from time base A to time base B

Extends from Icons.Converter (Icon for converter elements).

Information

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

The output y is derived from converting the input u assumed to be given in units of timeBaseA to timeBaseB

Notes

The best way to work with time in Modelica is to use the SIunit [s] for all internal representations and calculations while making use of displayUnit to convert input and output to and from s to another unit of time preferred by the modeler. That way models will be compatible with models from other domains.

Nevertheless, there may be use cases where within the model working with other timeBases will be necessary. Thus there may be need to convert from one time base to another which this converter fulfills.

See also

RateConversion

Parameters

TypeNameDefaultDescription
Structural Parameters
TimeBasestimeBaseAmodelSettings.modelDisplayTimeBaseTimeBase to convert from
TimeBasestimeBaseBTimeBases.secondsTimeBase to convert to (default = seconds)

Connectors

TypeNameDefaultDescription
Interfaces.Connectors.RealInputu
Interfaces.Connectors.RealOutputy

Components

TypeNameDefaultDescription
ModelSettingsmodelSettings

Revisions

  • Slight modification to pass unit checking in v2.0.0.