Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 -...

32
- 1 - technische universität dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 technische universität dortmund fakultät für informatik informatik 12 Integration von Physik und Informatik in Cyber-Physical Systems Peter Marwedel TU Dortmund, Informatik 12 Photos/Graphics: P. Marwedel + Microsoft 20160314

Transcript of Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 -...

Page 1: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 1 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

technische universität dortmund

fakultät für informatik

informatik 12

Integration

von Physik und Informatik

in Cyber-Physical Systems

Peter Marwedel TU Dortmund, Informatik 12

Photos/Graphics: P. Marwedel + Microsoft 2016年03月14日

Page 2: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 2 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Was ist ein Cyber-Physical System?

Physical Cyber

Digital Controls Systems, ca. 1980

Cyber-Physical Systems, 2010+ !

© P. Marwedel,

Marco Di Natale

Hier: positivere Betrachtung

Page 3: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 3 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Cyber-physical systems und

Eingebettete Systeme

CPS = ES + physikalische Umgebung

Eingebettete Systeme (ES): informationsverarbeitende

Systeme, die in ein umgebendes Produkt eingebettet sind

[Peter Marwedel, 2003]

Cyber-physical systems (CPS): integrations of computation

with physical processes [Edward Lee, 2006].

Physik Informationsverarbeitung

© Graphics:

Microsoft

Page 4: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 4 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Definitionen

National Science Foundation (NSF):

… (CPS) ... depend upon the synergy of

computational and physical components. ..will

be coordinated, distributed, and connected, …

Akatech:

… represent networked, software-intensive

embedded systems in a control loop, …

Europäische Kommission

… (CPS) refer to next generation embedded

ICT systems that are interconnected and

collaborating

CPS Hub NRW ..

cps-vo.org

Akatech: Cyber-

Physical Systems.

http://www.acatech.de/

http://bit.ly/13I7985

Page 5: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 5 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Definitionen

Chancen und Anwendungsbereiche

Herausforderungen

Modellierung

• Behandlung in der Ausbildung in Dortmund

• Timed Automata

• Modelica

Zusammenfassung

- 5 -

Gliederung

Page 6: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 6 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Anwendungsgebiete (1): Vernetzte Systeme

Page 7: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 7 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Anwendungsgebiete (2): Verkehrswesen

Automobile

Luftfahrt

Eisenbahnen

Wasserstraßen

©Photos:

P. Marwedel

Viele eingebettete Systeme, zunehmend vernetzt

Page 8: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 8 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Weitere Anwendungsgebiete (1)

©: Microsoft Cliparts

+ P. Marwedel, 2011

Fabrikautomatisierung

(Industrie 4.0)

Gesundheitswesen

Intelligentes Haus

Robotik

Page 9: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 9 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Weitere Anwendungsgebiete (2)

Energieversorgung

Katastrophenschutz

Öffentliche Sicherheit

Stabilitätsüberwachung

Physikalische Experimente

© C

ER

N

© airlinetrends.com

© w

ww

.sp

ieg

el.d

e

© u

mw

eltbundesam

t.de

© P

. M

arw

edel

Page 10: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 10 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Globale Sicht auf CPS

Attraktiver Begriff, der fast alle künftigen IT-Anwendungen

jenseits der Büroautomatisierung umfasst

In den USA stärkere Betonung der Integration der Physik

In Europa etwas stärkere Betonung der Verteiltheit

Innerhalb Europa‘s starkes Interesse in Deutschland

Abgrenzung zu Internet of Things (IoT) [Edward Lee]:

• CPS sind ein Entwurfsproblem,

• IoT ist eine konkrete Realisierungstechnik

Page 11: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 11 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Definitionen

Chancen und Anwendungsbereiche

Herausforderungen

Modellierung

• Behandlung in der Ausbildung in Dortmund

• Timed Automata

• Modelica

Zusammenfassung

- 11 -

Gliederung

Page 12: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 12 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Herausforderungen (1)

Sicherheit, Privatheit

Einhalten von Zeitschranken

Energieeffizienz

Dynamik

Heterogenität

Unscharfe (fuzzy) Verifikation

Page 13: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 13 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Herausforderungen (2)

Periodische Abtastung zu hinterfragen

Große Datenvolumina

Rechtliche Fragen

(Haftbarkeit, Geistiges Eigentum)

Nutzen für die Gesellschaft

Akzeptanz

Page 14: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 14 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

CPS-Entwurf ist interdisziplinär

Informatik

Mathematik

Beim Entwurf ist Wissen aus vielen Disziplinen erforderlich

Wände zwischen Disziplinen müssen abgebaut werden.

Physik

Medizin, Statistik,

Mechanik,

Biologie

© Graphics: Microsoft

Im folgenden Fokus auf Integration der Physik

Page 15: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 15 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Reelle vs. Festkommazahlen

Physik:

Viele physikalische Größen beschrieben durch ein Paar

(reelle Zahl, Einheit)

Unendlich viele reelle Zahlen

Cyber:

Gleitkommazahlen als Approximation

Endliche Menge an Gleitkommazahlen

Unpassend! W. Taha, R. Cartwright: Some Challenges for Model-Based Simulation, The 4th Analytic

Virtual Integration of Cyber-Physical Systems Workshop, Dec. 2013, Vancouver

© Graphics: Microsoft,

P. Marwedel, 2015

Page 16: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 16 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Herausforderungen: Zeno-Verhalten

Durch die Dämpfung e ist

jeder Zyklus kürzer als der

vorhergehende

Sei ein Zeitintervall

eine obere Schranke für

die Anzahl der Stöße in ?

Beispiel: Teilelastischer Stoß

einer Punktmasse

0

y>0, t<0: ÿ(t)=-g

y=0: ẏ(0)=- e maxt<0(ẏ(t))

Ideales Model eines Stoßes

bei t=0:

Wiederholte Stöße

Ein System zeigt Zeno-

Verhalten unbeschränk-

te Zahl von Ereignissen in

beschränkter Zeit.

Simulation?

NEIN y

t

….

Page 17: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 17 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Definitionen

Chancen und Anwendungsbereiche

Herausforderungen

Modellierung

• Behandlung in der Ausbildung in Dortmund

• Timed Automata

• Modelica

Zusammenfassung

- 17 -

Gliederung

Page 18: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 18 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Grenzen der üblichen „Threads“,

Bedeutung von Modellen

Even the core … notion of “computable” is at

odds with the requirements of embedded software.

In this notion, useful computation terminates, but termination

is undecidable.

In embedded software, termination is failure, and yet to get

predictable timing, subcomputations must decidably

terminate.

What is needed is nearly a reinvention of computer science.

Edward A. Lee: Absolutely Positively

on Time, IEEE Computer, July, 2005

Suche nach anderen Modellierungsansätzen.

Page 19: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 19 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Einige Berechnungsmodelle

* Klassifikation basierend auf Implementierung mit gemeinsamen Datenstrukturen

Kommunikation/

lokale Berechnung.

Gemeinsam-

er Speicher

Nachrichtenaustausch

Synchron | Asynchron

Undefinierte

Komponenten

Einfacher Text, use cases

| Sequenzdiagramme

Differentialgleichung Modelica, Matlab, ….

CFSM StateCharts SDL

Datenfluss Scoreboarding +

Tomasulo Algor. ->

Comp.Architecture

Kahn Netz-

werke, SDF

Petri-Netze C/E nets, P/T nets, …

Diskretes Ereignis-

(DE) Model

HW-Beschrei-

bungssprache* i.W. nur experimentelle Systeme

V.Neumann threads C, C++,Java C, C++, Java mit Bibliotheken

CSP, ADA |

Mehr Details in Büchern

und Videos

Page 20: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 20 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Lehrbücher

1. Ausgabe

• Englisch

• Deutsch, 2003 & 2007

• Chinesisch, 2006

• Mazedonisch, 2010

2. Ausgabe, mit CPS

• Englisch, Dez. 2010/Jan. 2011

• Übersetzte chinesische

Ausgabe, 2013

• Vertrag für deutsche Ausgabe

Peter

Marwedel Peter

Marwedel

Peter

Marwedel

© Graphics: Springer, Science

Publishers, Ad Verbum

Peter

Marwedel

Peter

Marwedel Peter

Marwedel

Page 21: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 21 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Folien und Videos (auf Englisch) verfügbar

Videos verfügbar unter http://peter.marwedel.eu oder direkt

http://www.youtube.com/user/cyphysystems

Page 22: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 22 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Einige Berechnungsmodelle

* Klassifikation basierend auf Implementierung mit gemeinsamen Datenstrukturen

Kommunikation/

lokale Berechnung.

Gemeinsam-

er Speicher

Nachrichtenaustausch

Synchron | Asynchron

Undefinierte

Komponenten

Einfacher Text, use cases

| Sequenzdiagramme

Differentialgleichung Modelica, Matlab, ….

CFSM StateCharts SDL

Datenfluss Scoreboarding +

Tomasulo Algor. ->

Comp.Architecture

Kahn Netz-

werke, SDF

Petri-Netze C/E nets, P/T nets, …

Diskretes Ereignis-

(DE) Model

HW-Beschrei-

bungssprache* i.W. nur experimentelle Systeme

V.Neumann threads C, C++,Java C, C++, Java mit Bibliotheken

CSP, ADA |

Page 23: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 23 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Definitionen

Chancen und Anwendungsbereiche

Herausforderungen

Modellierung

• Behandlung in der Ausbildung in Dortmund

• Timed Automata

• Modelica

Zusammenfassung

- 23 -

Gliederung

(Hier: Schwergewicht auf Modellierung)

Page 24: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 24 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Eine einfache Lichtsteuerung

Was heißt „kurz” nacheinander drücken ergibt helles Licht?

© Kim Larsen, U. Aalborg, 2015

Page 25: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 25 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Timed automata: Schritt in Richtung einer Inte-

gration der Zeitmodellierung mit Taktzählern

© Kim Larsen,

U. Aalborg, 2015

Simulation z.B. mit Uppaal,

www.uppaal.org

© Kim Larsen, U. Aalborg, 2015

Page 26: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 26 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Definitionen

Chancen und Anwendungsbereiche

Herausforderungen

Modellierung

• Behandlung in der Ausbildung in Dortmund

• Timed Automata

• Modelica

Zusammenfassung

- 26 -

Gliederung

Page 27: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 27 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Modelica

Sprache zur Modellierung von gemischten IT- und

physikalischen Systemen

( ) ( ( ), )

( ) ( ( ), )

t t t

t t t

x f x

y f x

0 ( ( ), ( ), ( ), )t t t t f x x y

http://openmodelica.org

Modellierung über Gleichungssysteme

Abbildung auf numerische Integration

Page 28: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 28 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Modelica-Modell des teilelastischen Stoßes

In Anlehnung an http://book.xogeny.com/

behavior/discrete/bouncing/

model Ball

type Height = Real(unit = "m");

type Velocity = Real(unit = "m/s");

parameter Real e = 0.8 "Restitution";

parameter Height h0 = 1.0 "Initiale Höhe";

Height h;

Velocity v;

initial equation

v = 0.0;

h = h0;

equation

v = der(h);

der(v) = -9.81;

when {h <= 0.0} then

reinit(v, -e * v);

end when;

end Ball;

Wenn die Bedingung erfüllt ist,

wird ein Ereignis erzeugt,

welches Variable neu initialisiert

System von Differentialgleichungen, kann mittels

Gleichungslösern numerisch gelöst werden

Page 29: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 29 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Modelica: Ergebnisse

Erzeugt mit OpenModelica

Connection Editor v 1.9.3

Page 30: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 30 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Modelica:

Konsequenzen von

Zahlendarstellung,

Simulationsmodell

und Zeno-Effekt

Der Ball

durchschlägt

den Tisch!

Für h 0 wird das Ereignis

“h wird <=0” nicht mehr

erzeugt, deswegen entfällt

die Umkehrung von v.

Erzeugt mit OpenModelica

Connection Editor v 1.9.3

Page 31: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 31 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Modelica: klebriger Ball model KlebrigerBall

type Height = Real(unit = "m");

type Velocity = Real(unit = "m/s");

parameter Real e = 0.8 “Restitution";

parameter Height h0=1.0 "Initiale Höhe“t";

constant Velocity eps=1e-3 “kleine Ges";

Boolean klebt;

Height h;

Velocity v;

initial equation

v = 0.0;

h = h0;

klebt = false;

equation

v = der(h);

der(v) = if klebt then 0 else -9.81;

when {h <= 0.0} then

klebt = abs(v) < eps;

reinit(v, if klebt then 0 else -e*v);

end when;

end KlebrigerBall;

Erzeugt mit OpenModelica

Connection Editor v 1.9.3

Bei |v|<eps wird

die effektive

Beschleunigung

auf 0 gesetzt

Page 32: Integration von Physik und Informatik in Cyber-Physical ... · technische universität - 10 - dortmund fakultät für informatik P. Marwedel, Informatik 12, 2016 SFB 876 Globale Sicht

- 32 - technische universität

dortmund

fakultät für

informatik

P. Marwedel,

Informatik 12, 2016

SFB

876

Zusammenfassung

Bei künftigen IT-Systemen Trend zur Integration mit

Gegenständen des realen Lebens CPS

CPS ist attraktiver Begriff, der eine Vielzahl von IT-

Anwendungen abdeckt.

Viele Chancen, aber auch viele Herausforderungen, hier

dargestellt anhand der Integration mit der Physik

Chancen für eine attraktive Lehre (auch mit HW!)

Mögliche Berechnungsmodelle beinhalten

• timed automata

• Differentialgleichungen, z.B. mit Modelica beschrieben