You are on page 1of 33

Model-based design and operation with

Modelica
Michael Wetter
Simulation Research Group

February 20, 2015

The vision is to
create a flexible computing infrastructure for research, product
development and operation of engineered systems,
based on open standards
for expressing models and interfacing computing modules,
which allows
analysis and reasoning based on models,
and model-transformation for different use cases.

Context: Models need to be compatible with up-stream


data-formats and serve down-stream applications

data

dynamics

x = f (x)

Case study:
Building in which the fixed schematic of the simulator required
a model to be used that is different from the actual system
Actual system and implementation in BIM
Granularity & connectivity defined by product
offerings and physical connections.

These are different


systems

EnergyPlus system schematics


Granularity & connectivity is
constraint by solution algorithms
(e.g., fluid loops) and model
causality.

The red objects had to


be inserted by the
user due to the
system context in
which the other
components have
been used. In the
actual system and in
the BIM view, there is
only one outside air
mixer needed; this
component was
required merely
because of the
simulation program
architecture.

To enable a 1-to-1 mapping, an acausal modeling language is needed that


allows to connect components in any way that is possible in the real
world.
4

Acausal models allow specifying the system architecture rather


than a modeler-perceived data flow between computing
Block Diagram Modeling
modules

Procedural Modeling

Acausal Modeling

Acausal balanced models

Acausal connectors

Domain

Potential

Flow

Heat flow

Q_flow

input/output determined
at compilation time

Fluid flow

h_outflow
X_outflow
C_outflow

can connect none or


multiple components
to a port

Electrical

Translational

Requirement of locally
balanced models
# of equations = # of
variables,
at each level of model
hierarchy.

Stream

m_flow

Automatically summed
up at connections to
satisfy conservation
equation.
connector Pin "Pin of an electrical component"
SIunits.Voltage v "Potential at the pin";
flow SIunits.Current i "Current flowing into the pin";
end Pin;
model Ground "Ground node"
Modelica.Electrical.Analog.Interfaces.Pin p;
equation
p.v = 0;
end Ground;

Encapsulation - Modelica

...
equation
dT = solid.T - fluid.T;
solid.Q_flow = Q_flow;
fluid.Q_flow = -Q_flow;
Q_flow = A*qCon_flow();
end Convection;

Replaceable classes allow for component and system model


reuse
model SystemDT "Model with DT controller"
//
replaceable DiscreteTimePI controller(
samplePeriod=120)
constrainedby
Controls.BasicPI(kP=2) "PI controller";
//
end SystemDT;
Extend the model, and replace the controller.
model SystemCT "Model with CT controller"
extends SystemDT(
redeclare Controls.ContinuousTimePI controller);
end SystemCT;
Only subclasses of Controls.BasicPI are allowed to be used.
The instance will inherit the value of kP.
8

Replaceable classes allow for component and system model


reuse
Packages implement functions for different media
model DensitySensor "Ideal one port density sensor"
extends Modelica.Icons.RotationalSensor;
replaceable package Medium=Modelica.Media.Interfaces.PartialMedium
"Medium in the sensor";
Modelica.Fluid.Interfaces.FluidPort_a port(
redeclare package Medium=Medium,
m_flow(min=0));
Modelica.Blocks.Interfaces.RealOutput d(final quantity="Density",
final unit="kg/m3",
displayUnit="g/cm3",
min=0) "Density in port medium";
equation
// Call the density function from the Medium package
d = Medium.density(Medium.setState_phX(port.p,
inStream(port.h_outflow), inStream(port.Xi_outflow)));
port.m_flow = 0;
port.h_outflow = 0;
port.Xi_outflow = zeros(Medium.nXi);
port.C_outflow = zeros(Medium.nC);
end DensitySensor;

Models can be spatially discretized using arrays of models


Modelica.Fluid.Interfaces.FluidPort_a port_a(
redeclare package Medium = Medium)
"Fluid connector a";
Modelica.Fluid.Interfaces.FluidPort_b port_b(
redeclare package Medium = Medium)
"Fluid connector b";
parameter Integer nEle(min=1) = 5
"Number of elements used in the discretization";
MixingVolume[nEle] vol(
redeclare each package Medium = Medium,
each nPorts = 2,
each V=10/nEle) "Volume for fluid stream";
equation
connect(port_a, vol[1].ports[1]);
connect(port_b, vol[nEle].ports[2]);
for i in 1:nEle-1 loop
connect(vol[i].ports[2], vol[i+1].ports[1]);
end for;

10

Numerics

11

Initial value ordinary differential equations

Consider initial value problem


dx(t)
= f (x(t)),
dt
x(0) = x0

t 2 [0, 1]

A unique solution exists if f () and @f ()/@t are Lipschitz continuous.

If your model does not satisfy these properties, what can you do if a solver does not
converge, or gives unexpected results? Is it a problem of the model or the solver?

12

A model that we often see implemented but can cause Newton


to fail
Consider the mass flow relation

V = sign( p) k

| p|

Suppose this expression is part of an algebraic loop that is solved for the pressure p using a
Newton algorithm.
Let g(p) = 0 be the residual function.

The denominator tends to


infinity, and hence the
Newton step becomes
arbitrarily small.

Newton will iterate using


pk+1 = pk

g(pk )
@g(pk )/@p

until a convergence criteria on pk is met.

-5

-4

-3

-2

-1

13

Stream of fluids
For electrical systems, we have a potential (voltage) that drives a flow (current).
For fluids, we have a potential (pressure) that drives a flow (mass flow rate) which carries
properties (temperatures, mass concentration).
Conservation of mass
n
X
0=
m
i

houtf low,a

houtf low,b

i=1

Conservation of energy
(
n
X
hmix ,
if m
i>0
0=
m
i
houtf low,i , otherwise.
i=1

hmix

If mass flow rates are computed based on (nonlinear) pressure drops, this cannot be solved
reliably as the residual equation depends on a boolean variable.

14

inStream(h

)=

region), see Figure 8,outflow


and,i in the general
case.

Stream of fluids - Stream connectors

j =1...n , j i

j =1...n , j i

Solution: Introduce inStream operator.

Sep. 20-22, 2009


Require inStream operator to be
continuously differentiable

0
m& 1
m& 2
m& 3

houtflow, j

(n 1)

j =1...n , j i

houtflow, j

n 1

that is, the operator returns the arithmetic mean of


the stream variables (but without houtflow,i). Figure 6
shows an illustration of this regularization for the
case of a three-way mixing point. Herein, the arithFigure
5:
Exact
solution
for
a
three-way
connection
= m& 1 + m& 2 + m& 3
metic mean value is shown in blue. Note that outside
In the Modelica Language Specification [6], a rec- of the regularization domain points remain, which
= f1 pmix p1 , ommended
,1ab ,1ba of the inStream() operator are not continuously differentiable. This is necessary
1ab , 1baregularization
is given. First, let i be the sum of the mass flow due to the second requirement to the regularization,
which states that the approximation must be exact
2 abconsidered
= f 2 pmix p2 ,rates
, 2ba ,for
, 2ba the operatorFigure
2 abapplying
to port i.8: Three
way the
mixing
point.
whenever
absolute
of all flow variables
Suggested
regularization
of values
inStream(h3)
i =
max( m& j ,0)
are greater than a given small value.
= f p p , , , ,

(
(
3(

3ba

)
2 ba )

As medium, the fluid Modelica.Media.IdealGases.Then, the expressions using the conventional


operaMixtureGases.FlueGasSixComponents
is used
1ab = ( pmix , T1a _ inflow
,
inStream
(
Xi
))
1a (8) are substituted by a custor max(x, 0) in equation
which is a mixture of six ideal gas substances. The
tom operator positiveMax(x, i ), which is defined
T1a _ inflow
= T ( pmix , inStream( h1a ), inStreamindependent
( Xi1a ) )
medium variables are pressure p, temsuch that it always returns a positive, non-zero value.
perature T and 5 independent mass fractions Xi. This
&
&
h2 a max
(

m
,

)
+
h

max
(

m
inStream(houtflow
2 ,i ) = 3 a
3 , )
system
is basically described by the following set of
inStream(h1a ) =
max(m& 2 ,houtflow
) +, j max
( m& 3 , )m&equations:
positiveMax(
j , i )
mix

3 ab

j =1...n , j i

j =1...n , j i

2 ab

(13)

... on pmix and two mass flow


Iterate
rates. m& j , i )
positiveMax(
j =1...n , j i
This set of nonlinear algebraic equations can be basiA suitable
definitionfor
of the
the operator
is amixing
linear comThe
iteration
variables
above
problem
namely
callynumber
solved ofwith
three
iteration
variables,
suitably
bination
ofand
max(x,
0) and functions
+ along achanged
was
reduced
from
22
to
3,
residual
from
two
mass
flow
rates
and
the
pressure
p
in
the
mixmix
chosen variable .
way
discontinuous
to
continuous.
ing point: If two masspositiveMa
flow rates
are given, the third
(
x
x, i ) = max( x,0) + (1 ) . Figure 6: Recommended
Franke
et flow
al., 2009
way connection
mass
rate can be computed via the mass balance

approximation for a three-

15

Simplifying the equations through block lower triangularization


and tearing:
(i) Block lower triangularization
After BLT transformation

Incidence matrix

1: Q = T1 T2
2 : 0 = T1
3 : f (t) = T1 + T2

T1

T2

T1

T2

Application to an
electric circuit model

Bunus and Fritzson (2004)

16

(ii) Tearing

Suppose we have an equation


n

0 = f ( x ), x , n > 1,
that can be written in the form

1
2

(1) L x = f ( x ),
1

(2)

2
1
2

0 = f ( x , x ),

where L is a lower triangular matrix with constant non-zero diagonals.


How do you solve this efficiently?
Pick a guess value for x2, solve (1) for x1, and compute a new value for x2 from (2).
Iterate until x2 converges to a solution.
17

Translation process (figure from OpenModelica)

Figure from Bunus and Fritzson (2004)

18

Non-careful constructed
models can lead to numerical
problems for which it can take
days to find the root cause

19

Symptom:
Mass flow rate started to oscillate when fan control
(54)
signal was off

by nu-

airflow
damper

fan

pump

south

east

north

west

zone

zone

zone

zone

zone

Figure 10: Schematic diagram


of configuration of fans that
caused unstable simulation.
heating
coil
+

cooling
coil
-

control valve

m (t)/m 0

w resistance

pre-heat
coil

core

1
0.5
0
0.5
1

All fans were


were
switched off
for the whole
simulation
600

1,000
1,600
time in seconds

20

Symptom: Mass flow rate started to oscillate when fan control


Figure 10: Schematic diagram
was
offthat
ofsignal
configuration
of fans

m (t)/m 0

caused unstable simulation.

Problem size

231 continuous states


4400 time varying variables

1
0.5
0
0.5
1
600

1,000
1,600
time in seconds

Figure 11: Instability of


m (t)/m 0 for the fan inlet mass
flow rate at location (a) in Figure 10.

Figure 12: Schematic diagram

21

( e, t ) required dividing numerical noise by nu


Thus,
computing
V
Problem abstraction
merical noise.
fan, consisting of a volume (circle)
and a pressure source (triangle)
flow resistance

volume

Fi
of
ca

heating coil, consisting


of volumes in series

(a)

Solid lines indicate flow paths with zero volume flow rate;
dashed lines indicate flow paths in which volume flow rates oscillate.

Moreover, since in the system model, the fans were connected as


shown in Figure 10, the fluid volumes of two fan models were cou-

Fi

22

r (e, t) c2

(54)

6.2Problem
Implementation
in Buildings Library
0.12V (e, t) required dividing numerical noise by nuThus, computing
abstraction
merical noise.

Fan curve

V (e, t)

Dp(r (t), V (t))


Dp(r (t), V (t))

Dp (e, r (e, t), V (e, t))


2r (e, t) c2
2
Dp (1e, r (e, t), V (e, t))

Figure
of con
caused

m (t)/m 0

fan, consisting
of a volume
(circle)
WeNonlinear
will nowresidual
explain
how the first two problems
were
avoided
in
the
function:
and a pressure source (triangle)
flow resistance
Buildings library version 0.12. We will then explain why the new
f (x) = 0
implementation was also not robust. Finally, in Section 6.3 we will
Numerical approximation:
volume
heating coil, consisting
explain how we reimplemented
the
fan
model
to
circumvent
all three
of volumes in series

kf (x) f (x ())k K
DRAFT working paper. Do not distribute.
problems.
(a)
for
K > 0.
In some
the Buildings
library version 0.12,Solidthe
first two problems are
lines indicate flow paths with zero volume flow rate;
For small values of r (t) and Dp(r (t), V (t)), the governing equation
dashed lines indicate flow paths in which volume flow rates oscillate.
became
avoided by reformulating
(51) as

r (e, t)2 c1

fans (52a)
were connected
as
= c r (t) + c r (t)Moreover,
V (t), since in the system model, theDRAFT
working
paper.
Figure
shown
in
Figure
10,
the
fluid
volumes
of
two
fan
models
were
cou
.
(54)
r (e, t)2c
2parameterization, multiple volumes were
m (t)/

= c 1 r (t) + c2 r (tpled.
) V Due
(t)to+thecmodel
V
(
t
)
,
(52b)
3
2

flow r
Thus, computing
V (e, t) required dividing
numerical
noise
by nuA model is always
an idealization,
but the
above
idealization,
whileingood
text abooks,
connected
without
a flow resistance
between,for
forming
sequence is
n
ure 10
merical noise.
of connected volumes. Within this sequence, the mass flow rate benot suited for simulation:
n i i 1
Dp
(
r
(
t
)
,
V
(
t
))
=
c
r
(
t
)
VVcame
(oscillatory
t, )the
, governing
for
n Ifaspressure
4.
(52c)
and
unstable,
shown in Figure
11, because at
fan,
consisting
of
a
volume
(circle)
For small values of r (and
t)a and
Dp
(
r
(
t
)
,
(
t
))
equation
i
raise
and fan speed
pressure source (triangle)

Figure
10:
Schematic
diagram
r = 0 (and Dp
= 0), any value of V (t) satisfied the governing equaflow resistance
i
=
1
thepath.
approximate
became
ofare
configuration
of
fanscaused
that thesolution
tion (52a)
for the fan in the lower
flow
This
solver to of
Numerical approximation of the volume flow
rate
caused
unstable
simulation.then numerical
stall.
iterative
solvers,
This implementation
has
shown
to
be
numerically
problematic
in a

Dp
(
e,
r
(
e,
t
)
,
V
(
e,
t
))
r
(
e,
t
)
c
1
noise is divided by numerical
(e, t) =
volume
V
heating coil, consisting
large system model in which ofrthe
curve
was modeled
as a linear
( e,fan
New Implementation
in Buildings
volumes
intseries
) c6.3
noise! Library
2

12
(t) as 1an iteration
function.12 The reason
was
that
Dymola
selected
V
This prob

Dp (e, r (e, t), V (e, t))pressure state


pressure source 0.5
flow resistance
pressure state
. t), V (t)) required 0an iterative
(54)
//corbu.lb
Figure
variable, andcomputingr r((e,t)t)and
Dp
(
r
(
c2
0.5
for pre
mwetter/de
1
e, t ) and some
tion, ,p
solution, i.e., they were
approximated
using
some
p (t)
Dp(r
r (t)(
, V (t))
Dp (V (t))
p (t) Buildings

600
23
1,000
1,600
Thus,
computing
V
(
e,
t
)
required
dividing
numerical
noise
by
nuflow r
time
in
seconds

m (t)/m 0

(a)

Solid lines indicate flow paths with zero volume flow rate;
dashed lines indicate flow paths in which volume flow rates oscillate.

network
putes the pressure raise p r(t), V (t) . Fan curves
Solution:
a model
satisfies
physics
where of
that
relateConstruct
volume flow
rate tothat
pressure
raise
are not
Implem
interest,decreasing
is differentiable
a unique
strictly
if a fanand
has has
a stall
region. solution
However,
The Mo
pressure
state
pressure
source
flow
resistance
pressure
state
below we will show that strict decrease is required to
for a fan
prove existence of a solution. A numerical solver then
computes
r(t),V (t))
pa (t) and ppr (bV(t)
pa (t) for some p(r(t),
(t)) a numerical
pb (t)

approximation
to
the
flow
rate
V
(t)
that
satisfies
1: Schematic
diagram
for
pressure
boundary
condition,
pressure
source of fan, and flow resistance.
p(r
Find functional form p(, ) so that

nV
0
=
p(r(t),
(t))
p
(
V
(2)for a robust simulatio
a (t) pbis(t).
proximation. Let x 2 R , for some n 2 r
N. (t))+p
suited formulation
required
ite x () 2 Rn to denote the numerical apwhere r
n tohas
x obtained
with
solver
precision
conNote
that even
if the fan is controlled to be either on
a
unique
solution
(and
physics
is
satisfied
in
region
of
interest).
We
are
interested
in
how
to
formulate
the
fan
curve
N
(t)/N
eter 2 R+ . For example, for f (x) = 0,
off, the speed r(t) may attain any value between 0 a
Hence,
we
want
p(,to)
such
that
(2)
has always
unique
solution.
thespeed
volu
p(,If)
a solution
the
equation.
obtaining
this
1.a For
example,
a user may compute the
as
quires an iterative solver, then one computes
output of a second order filter for two cients
reasons: th
Fi
Now,
continuous
time
system
simulation
programs
to be continuously
mate1)solution
x () 2 Rndifferentiable,
that satisfies,and
for
this provides a continuous change in flow rate, wh
ing
poin
compute
for
any
time
instant
t
2
R
and
speed
0, can
can
be
faster
and
more
robust
to
simulate
compa

2) its derivative with respect to V (t) be bounded away from zero.


to tolerance
a step change.Second,
the ,second order
filter m
volume
r kx
2 [0,
1],
and
for
any
solver
2
R
+
x ()k K .
(1)
be used to approximate the transient response of

fa
an approximate solution V (,fan.
t) For
to this
(2).reason,
In thecases
fan models inby
thethe
Model
Mwhere
DEFINITION
/ user
Buildings library
have a parameter
allows
r.24
no solution exists, the iterative
solution
will that V

er the system shown in Figure 1 at some

enable or disable such a second order filter.

<

(8)

p(V )

{(0.25, 0.5), (0.5, 0.45), (0.75, 0.3)}.


Figure 7, model
the support points are stric
Problem formulation using a differentiable
but the polynomial is increasing for
2 R,
flow rates. Such
an inflection point c
pressure state
pressure source
flow resistance
pressure state
pr (V ) + pa pb )
by using cubic hermite splines that
0,
(9)
using the algorithm of Fritsch and C
@ V
This
algorithm guarantees
strict descen
(t))
(t))
p
(t)
p(r(t),
V
p
(
V
p
(t)
a
r
b
dition is that for all r 2 R, the function
hermite spline if the data are strict
1: Schematic derivative
diagram for and
pressure
boundary
condition, pressure source of fan, and flow resistance.
continuous
there
exists
a
>
0
Figure
7
shows
such
a
cubic
hermite
A sufficient condition is that there exists some
forsuch
all Vthat
2 for
R,all V 2 <
computed for the above support point
proximation. Let x 2 Rn , for some n 2 N.
suited
formulation isoutside
requiredthe
for range
a robustofsimulatio
extrapolated
the
su

n
Otherwise,
the
following
may
occur:
ite x@ ()p(r,
2 RV )to<
denote.the numerical ap(10)
n to x obtained
with solver precision conNote that even if the fan is controlled to be either on
@ V
Wespeed
will r(t)
nowmay
create
fan
model
that0 sa
eter 2 R+ . For example, for f (x) = 0,
off, the
attain aany
value
between
pr (V )
tion
(10) and
themay
fancompute
affinitythelaws
willtobetheused
below
to construct
a(10)
solution
equation.
If obtaining
this a 1. For
example,
a user
speedinas
)
p(r
,
V
1
quires an iterative solver, then one computes
output
of aof
second
order filter
forsimplify
two reasons:
Fi
gion
operation.
To
notat
n.
pb (t) pa (t)
mate solution x () 2 Rn that satisfies, for
this
provides
change
in flow rate, whp
{(
V i , pa icontinuous
)}ni=1 , with
Vp(r
i 2 , V )0 and
0,
can be faster and more robust to simulate compa
i 2 {1, . . . , n}, denote
first show that a solution may not exist
p(r3the
, V )user-supplie
to a step change.
Second, the second order filter m
0

datatofor
the
between
the of
fa
0) is kx
not xsatisfied.
Figure
()k K Consider
.
(1) 6 be used
0 pressure
approximate
the rise
transient
response
speed
1. Let
= 0
V =models
a fan with a stall region that works fan. let
Foratthisfull
reason,
the rfan
in the Model
M DEFINITION

as have
aand
small
number
that
bel
Buildings
afan
parameter
allows
tive
pressure.
For
6:selected
Flow library
resistance
curve
thatthat
shows
theis user
For
deviation, see
Wetterp(r
2013
1 , V ), thereFigure
25
))
4 order
situation
where
two
solutions
exist
(with
p(r
,
V
enable
or
disable
such
a
second
filter.
er
the
system
shown
in
Figure
1
at
some
1
normalized fan speed.
ons. This situation can happen in a
@ V

Model transformation for


applications such as
optimization or fault detection
and diagnostics

26

Support for Optimization - JModelica


Extensible Modelica-based open source platform for optimization,
simulation and analysis of complex dynamic systems.
Main objective:

Create an industrially viable


open source platform for
optimization of Modelica
models.
Offer a flexible platform serving
as a virtual lab for algorithm
development and research.
Main features

Optimal control
Parameter estimation
Simulation
Source: http://www.jmodelica.org

27

3.1 The anatomy of an Optimica specification

Support
for Optimization
The Optimica extension
is discussed in detail -[1].JModelica
In this paper, a brief overview of Optimica is given and the
extension is illustrated by means of an example. We consider the following dynamic optimization problem:
min
u(t)

Z tf
0

1 dt

(1)

x2 (t) + u(t), x1 (0) = 0


x2 (0) = 1

(2)

subject to the dynamic constraint


x1 (t) = (1 x2 (t)2 )x1 (t)
x2 (t) = x1 (t),
and

model VDP
Real x1(start=0);
Real x2(start=1);
input Real u;
equation
der(x1) = (1-x2^2)*x1 - x2 + u;
der(x2) = x1;
end VDP;

Listing 1: A Modelica model of a van Der


Pol oscillator.

Source: Akesson et al., 2009

x1 (t f ) = 0
x2 (t f ) = 0
1 u(t) 1

(3)

optimization VDP_Opt (objective=cost(finalTime),


startTime=0,
finalTime(free=true, initialGuess=1))
VDP vdp(u(free=true,initialGuess=0.0));
Real cost (start=0);
equation
der(cost) = 1;
constraint
vdp.x1(finalTime) = 0;
vdp.x2(finalTime) = 0;
vdp.u >= -1;
vdp.u <= 1;
end VDP_Opt;

Listing 2: An Optimica optimization specification based


on the van Der Pol Oscillator.

28

Model reuse during design and operation in the case of


buildings as currently prototyped with Ptolemy II
Solve optimization problems with
10,000 of variables in real-time
through computer algebra &
numerics that exploit equation
structure
F (x,
x, y, u, ) = 0

HVAC & controls

Envelope & daylighting


directly in C++

Modelica Matlab
FMI

FMI
FMI
FMI
FMI
simulation master algorithm

vendor-specific algorithms API


operation
operation

FMI:
FunctionalMockup
Interface, a
standard for
interfacing
computer
code.

design

C++ Python Fortran

FMI

communication layer,
e.g, Volttron
hardware

databases web service

Write models and control


sequences once, deploy
through code generation from
Modelica to Tridium Niagara(R)
using the FMI standard

Set

Example of model use to support operation:


Model-based fault detection for chilled water plants under
consideration of uncertainties
file:///Users/mwetter/proj/iea/a60/iea-annex-60-admin/outreach...

controller

PI
PI

DESIGN

set=0

Experts and
designers

SIMULATION PROGRAM / PLATFORM

Q_flow

Library of models
Simulation model

Q=3000

inletTemp

boiler

Design phase

F(x',x,y,p)=0

outletTemp

Construction

con2

PI
PI

Model compliant with


Functional Mockup
Interface standard

U
FM

Sensor & energy


measurements

sin
Fix faults
Notify faults

Q_flow

Estimation of fault
parameters in real-time

Fault detection
and diagnosis

Maintenance and
operators

Q=3000

heaDyn

Bonvini et al, 2014

senTem2

OPERATION

30

R&D Needs

Link functional requirements,


digital models and actual systems,
at different levels of abstraction and subsystems

modular modeling
infrastructure

frameworks for multi-scale


distributed simulation and optimization

en

ab

lin

te
c

hn

ol

og

ie

pr

oc

es

model-based design &


operation of engineered
systems

domain-specific
model libraries

numerical solvers for


simulation

numerical solvers for


optimization
15

31

Further literature

Online book with interactive examples of Michael Tiller at http://book.xogeny.com/ .


Modelica web reference http://modref.xogeny.com/
Interactive Modelica lessons at http://tour.xogeny.com/
The books by Michael Tiller (2001) and Peter Fritzson (2011 and 2004).
The tutorials at https://www.modelica.org/publications.
The Modelica language specification at https://modelica.org/documents.

Although the Modelica Language Tutorial is for an older version (Modelica 1.4), it is still
instructive and relevant to understand the concepts of the language.

32

References

J. Akesson, M. Gaefvert, and H. Tummescheit. Jmodelica an open source platform for optimization of modelica
models. In Proceedings of MATHMOD 2009 - 6th Vienna International Conference on Mathematical Modelling, Vienna,
Austria, feb 2009. TU Wien.
M. Bonvini, M. D. Sohn, J. Granderson, M. Wetter, and M. A. Piette. Robust on-line fault detection diagnosis for HVAC
components based on nonlinear state estimation techniques. Applied Energy, 124(0):156 166, 2014.
P. Bunus and P. Fritzson. Automated static analysis of equation-based components. Simulation, 80(7 8):321345,
2004.
R. Franke, F. Casella, M. Otter, M. Sielemann, H. Elmqvist, S. E. Mattsson, and H. Olsson. Stream connectors an
extension of modelica for device-oriented modeling of convective transport phenomena. In F. Casella, editor, Proc. of the
7-th International Modelica Conference, Como, Italy, Sept. 2009.
P. Fritzson. Principles of Object-Oriented Modeling and Simulation with Modelica 2.1. John Wiley & Sons, 2004.
P. Fritzson. Introduction to Modeling and Simulation of Technical and Physical Systems with Modelica. Wiley-IEEE Press,
Sept. 2011.
M. M. Tiller. Introduction to Physical Modeling with Modelica. Kluwer Academic Publisher, 2001.
M. Wetter. Fan and pump model that has a unique solution for any pressure boundary condition and control signal. In J.
J. Roux and M. Woloszyn, editors, Proc. of the 13-th IBPSA Conference, pages 35053512, 2013.

33

You might also like