.ModelicaReference.Classes.'model'

Information

Define specialized class model

Examples

model SlidingMass
  parameter Modelica.Units.SI.Mass m=1;
  parameter Modelica.Units.SI.Force f=1;
  Modelica.Units.SI.Position s;
  Modelica.Units.SI.Velocity v;
  Modelica.Units.SI.Acceleration a;
equation
  der(s) = v;
  der(v) = a;
  m*a = f;
end SlidingMass;

Syntax

   [ encapsulated ][ partial] model
   IDENT class_specifier

class_specifier :
   string_comment composition end IDENT
   | "=" base_prefix name [ array_subscripts ] [ class_modification ] comment
   | "=" enumeration "(" ( [enum_list] | ":" ) ")" comment

See Modelica Grammar for further details.

Description

The keyword model is identical to the keyword class, i.e., no restrictions and no enhancements.


Generated at 2020-06-05T21:39:08Z by OpenModelica 1.16.0~dev-442-g2e5bc9f