modelTablesFromFile

Application of tables read from file
Diagram of TablesFromFile

Extends from Tables (Application of tables).

Information

Description

This examples demonstrates how the variable resistance of an electric circuit can be set by means of a table. The table data are read from a Modelica specific file.

Plot the following variable(s)

  • table.y[1]: output of table
  • variableResistor.R_actual: actual resistance

Parameters

TypeNameDefaultDescription
StringfileNameModelica.Utilities.Files.loadResource("modelica://HanserModelica/Resources/Tables/table.txt")File name
Modelica.Units.SI.InductanceL (from Tables)2Inductance
Modelica.Units.SI.Voltagev (from Tables)20Total DC voltage

Components

TypeNameDefaultDescription
Modelica.Electrical.Analog.Basic.Groundground (from Tables)
Modelica.Electrical.Analog.Sources.ConstantVoltageconstantVoltage (from Tables)
Modelica.Electrical.Analog.Basic.Inductorinductor (from Tables)
Modelica.Electrical.Analog.Basic.VariableResistorvariableResistor (from Tables)
Modelica.Blocks.Sources.CombiTimeTabletable (from Tables)