semiLinear() is redesigned to not generate events.
'<') has been improved.
Advanced.PrintLowRes = true;
this will print and copy the plot window using screen resolution, which is compatible with earlier
versions of Dymola.
model A annotation(Coordsys(component=[20, 20])); // .... end A;
Advanced.OutputModelicaCodeWithJacobians
= true. Advanced.AutomaticChoicesAreReplaceable=true;
model C2
extends Modelica.Mechanics.Rotational.Examples.CoupledClutches;
parameter Boolean addFriction=true;
Modelica.Mechanics.Rotational.BearingFriction BearingFriction1(tau_pos=[0,2]) if addFriction annotation (extent=[62,-62; 82,-42]);
equation
connect(BearingFriction1.flange_a, J3.flange_a) annotation (points=[62,-52;
50,-52; 50,0; 35,0], style(color=0, rgbcolor={0,0,0}));
end C2;
stretch=false => The bitmap is not scaled to fit the bounding
box. The orginal (pixel) size is preserved.
preserveAspectRatio=false => The bitmap is scaled to fill the
bounding box, possibly distorting the image.
The default values are 'true' in both cases.
trace(variables = false,statements = false,calls = false, onlyFunction = "");This will optionally trace values of assigned variables, executed statements, calls of the function, and can optionally be overridden for a specicific function. Calling trace with default value for onlyFunction overrides the trace-settings for all functions.
simulateExtendedModelinitializedlist and variables| x | X-values | |
| y | Y-values | |
| style | 0 | Style of plotting (default automatic) |
| legend | "" | Legend describing plotted data (default none) |
| id | 0 | Identity of window (default 0 means last) |


a.inPort.signal[1] to a.u,
and a.inPort.signal to {a.u}.
Save will save the current
window
layout or Modelica version in a file
associated with the user. The
next time Dymola is started, the saved settings are used.
The layout information includes:
C:\Documents and Settings\<user>\Application Data\Dynasim\settings.mosThe directory Dynasim is automatically created by Dymola if needed. It is also possible to store the settings in a directory read by all users, or to save the settings as a local script file chosen by the user.
The command Clear All will erase the
settings
file for the current user or all users.
Defaults will apply until settings are saved.
After a signal has been plotted, the display unit can be changed in Plot/Setup. The display unit is chosen from a list of known derived units. The display unit must be changed for each plotted signal. The last selected display unit becomes the default display unit when another signal with the same fundamental unit is plotted.

Unit conversions and the initial default display unit can be specified in command scripts as needed. For example,
defineUnitConversion("Pa", "MPa", 1e-6, 0); // scale and offset
defineDefaultDisplayUnit("Pa", "MPa"); // use MPa by default
The set of common unit conversions which are used by default can be
found in dymola/insert/displayunit.mos. Additional US
unit conversions are defined in dymola/insert/displayunit_us.mos;
which are used by default can be changed in dymola/insert/dymola.mos.for source in {"Step","Constant","Ramp","Sine"} loop
simulateModel("TestSource(redeclare Modelica.Blocks.Sources."+source+" Source)");
end for;
This is a major change with respect to previous versions of the Modelica Standard Library. The changes are not backward compatible. A script to automatically convert models to this new version is provided. There are cases, where this script does not convert correctly. In this case models have to be manually converted. In any case you should make a back-up copy of your model before automatic conversion is performed. Note, conversion should work successfully for all models that are using components of the Modelica standard and ModelicaAdditions library with the following exceptions:
- It is planned to improve the automatic conversion for the release version.
- The major changes of Modelica 2.1 Beta1 with respect to Modelica 1.6 are:
- Simplified the definition of the signal connectors in Modelica.Blocks.Interfaces. For example, an output signal "FirstOrder.outPort.signal[1]" is now named "FirstOrder.y". This simplifies the understanding and usage especially for beginners.
- De-vectorized the Modelica.Blocks library. All blocks in the Modelica.Blocks library are now scalar blocks. As a result, the parameters of the Blocks are scalars and no vectors any more. For example, a parameter "amplitude" that might had a value of "{1}" previously, has now a value of "1". This simplifies the understanding and usage especially for beginners.
If a vector of blocks is needed, this can be easily accomplished by adding a dimension to the instance.- 16 new components have been added to the Blocks library
- All components of the ModelicaAdditions library are included in the Modelica Standard Library in an improved way:
- ModelicaAdditions.Blocks is included in Modelica.Blocks. The logical blocks have a nicer icon layout now.
- ModelicaAdditions.Tables is included in Modelica.Blocks.Sources and Modelica.Blocks.Tables.
- ModelicaAdditions.MultiBody is obsolete and is replaced by the much more powerful library Modelica.Mechanics.MultiBody (this is version 1.0.1 of the MultiBody library where the signal connectors have been changed to the new signal connectors).
- ModelicaAdditions.HeatFlow1D is obsolete since a long time. It was replaced by the improved library Modelica.Thermal.HeatTransfer.
- ModelicaAdditions.PetriNets is obsolete and is replaced by the much more powerful library Modelica.StateGraph.
- Added a new library Modelica.StateGraph to model discrete event and reactive systems in a convenient way. It is based on the JGraphChart method and takes advantage of Modelica features for the "action" language. JGraphChart is a further development of Grafcet to include elements of StateCharts that are not present in Grafcet/Sequential Function Charts. Therefore, the StateGraph library has a similar modeling power as StateCharts but avoids some deficiences of action languages usually used together with StateCharts.
- For details, see the release notes of the library.
- The 2.1 Beta 1 version of the Modelica Standard Library needs to be preloaded by selecting it in the Files/Library menu. By default, version 1.6 is utilized.
- When Modelica 2.1 Beta1 is used, then the following libraries cannot be utilized any more because they are not yet converted: HyLibLight, HyLib, PneuLibLight, PneuLib, PowerTrain, VehicleDynamics, Sampled.
- Same increment on horizontal and vertical axes can be specified in Plot/Setup/Range.
- Axis labels are printed in a more uniform format. Precision is increased when needed to show very small ranges.
- Base number for relative axis is printed bold and underlined to make this mode easy to recognize, e.g.
0.6953.
- Space for vertical axis is increased if needed to fit all labels.
- Diagram tooltips show units.
ConnType a[3];
parameter Real n = 2;
ConnType b[n];
], ),
end <class> ). ,, ;,
then, else). inner /* */ class a end a;) = vs. :=).
Advanced.AutoFormatting=true;
|
|
|
Component tooltip.
|
Connector tooltip. |
|
|
|
Tooltip for a single signal.
|
Tooltip for multiple signals
and
a common independent variable. |
semiLinear() is now a built-in function.der(x)=0 is exploited
to reduce the problem.Advanced.LogStartValuesForIterationVariables =
true.
It is possible to annotate parameters or parameter types in order that it's possible to make a selection from a set of values from a pull down menu. For example, setting a parameter true or false can be made by selecting on or off as shown below.
![]()
The needed declarations for this appearance is:
type OnOff = Boolean annotation (choices(choice=false "off", choice=true "on"));The following examples show similar choices from a set of predefined vectors representing different common directional axes or commonly used colors. In the example to the right, a selection has been among a set of strings.
parameter OnOff animation=false "Enable/disable animation";
![]()
![]()
![]()
The corresponding declarations are:type Axis = Real[3] annotation (choices(
choice={1,0,0} "{1,0,0} - x axis",
choice={0,1,0} "{0,1,0} - y axis",
choice={0,0,1} "{0,0,1} - z axis",
choice={0,0,0} "any axis"));
parameter Axis n={1,0,0} "Axis of rotation";type Color = Real[3] annotation (choices(
choice={1,0,0} "red",
choice={0,1,0} "green",
choice={0,0,1} "blue"));
parameter Color color={1,0,0} "Object color";type Shape = String annotation (choices(It should be noted that, it's possible to enter any value without using the pull downmenu. This enables the use of expressions, for example.
choice="" "none",
choice="box" "box",
choice="cylinder" "cylinder"));
parameter Shape shape="" "Animation shape";
annotation (
defaultComponentName="world",
defaultAttributes="inner",
missingInnerMessage="No \"world\" component is defined. A default world
component with the default gravity field will be used
(g=9.81 in negative y-axis). If this is not desired,
drag MultiBody.World into the top level of your model.",
import Modelica.Math.*
= true
sin(1)
= 0.841470984807897
a=1:10
Declaring variable: Integer a [10];
a=1:20
Redeclaring variable: Integer a [20];