Post on 15-Jan-2016
description
transcript
Rigoros and Adaptive ... Information Systems 1
Development of Rigorous Adaptive Information
Systems
Dr. Nasreddine AoumeurFIN, ITI, DB group
aoumeur@iti.cs.uni-magdeburg.de
Course Site: wwwiti.cs.uni-magdeburg.de/~aoumeur wwwiti.cs.uni-magdeburg.de/iti_db/lehre/oois/inde
Rigoros and Adaptive ... Information Systems 2
Information Systems: Working Information Systems: Working definitiondefinition
– reactive systems (i.e. in continuous interaction with their environment), with
– large amount of immutable and non-immutable data (i.e. fixed and changing) and, with
– processes and activities for exhibiting behaviors on these (state-less and –full) data.
Rigoros and Adaptive ... Information Systems 3
Different generations of CMs : “Entity first”
State-less and -ful DATA
Processes and Rules
IS Conceptual ModelEntity-Relationship[1973..] - Intuitive / Simple - Revolutionary for IS - UoD : Entities+Relations - Mathematically sound - Rich abstraction mechnanisms - Different variants (NIAM / SADT / MERISE / ..)
Process-centric Formalisms - CCS, CSP, DFD, Petri Nets, .. - Synchronous / asynchronous - Mathematically sound - Executable / operational
Rigoros and Adaptive ... Information Systems 4
Different generations of CMs : “Object first”
State-less and -ful DATA
Processes and Rules
IS Conceptual Model Object Paradigm[1980..] - Really Intuitive / highly accepted - Object (Id, structure / dynamic) - UoD : Interacting objects community - Rich abstraction mechnanisms (e.g. Class, inheritance, role, aggregation, ..)
- Different formal interpretations
Behavior-centric OO Formalisms - OO Petri Nets, Mondel, JSD.. - Mathematically sound - Executable / operational / concurrent - Cope with data and process around objects
Rigoros and Adaptive ... Information Systems 5
Current generation of CMs : “Interaction first”
Aspect-/connector-/meta-level
All What is : - Evolving (business rules, market laws, cross-organizational policies, …) - Cross-Cutting (security, management,..)
- Non-functional (availability, performance,..)
Stable and invariantentities
IS Conceptual ModelAspect/archietctural Paradigm - Explicit separation between Coordination and computation - Separation between what is evolving from what is stable - Dynamic shifting-down / up of changing behavior - Suitable for services and mobility
Entity Interfaces
Dynamically weaving
Rigoros and Adaptive ... Information Systems 6
First generation of CMs : “Entity first”
Processes and Rules
E/R Conceptual Model
Entity Name
Attribute1 : Type1
Attribute2 : Type2....Attributei : Typei
Property1
.....
n-m
i-j AssocPART
IS-A
m Entit(ies)
n Entit(ies)
Rigoros and Adaptive ... Information Systems 7
First generation of CMs : “Entity first”E/R Conceptual Model
Customer
Name : StringBirth-Date : DateAddress : AddressIncome : Money
Open-Date
Bank
1-20-N Own
(Running) Account
Number : NatBalance : MoneyLimit : MoneyHistory : List[Date,Money]
IS-A
Saving Account
Number : NatInterest : PercentBalance
Processes and RulesAccount USE : First open --- then deposit – then (withdraw-deposit)* - then Close-or-be-closed
Rigoros and Adaptive ... Information Systems 8
First generation of CMs : “Entity first”E/R Conceptual Model
Customer
Name : StringAmount
Date
1-20-N Withdraw
AutomaticTellerMachine
ATM-Reference : StringCash : HiddenBank : StringTransaction : List[Money]History :List[Card-Nb,Acnt-Nb,Money
Bank-Card
Number : NatAccount-Nb: NatCode : String
Processes and RulesATM-use : First enter-card – then enter-code – then enter-transaction—get money
Rigoros and Adaptive ... Information Systems 9
First generation of CMs : “Entity first”E/R Conceptual Model
Student
Name : StringSubscription-NbSemester
Date-Out
Date-Back
0-N0-3 Borrow
Book
Reference : StringName : StringAuthor : StringPublisher : String
Processes and RulesFirst subscribe-- Get library-card – (Borrow – Return –or– Penality)*--(be)Unsubscribe(d)
Rigoros and Adaptive ... Information Systems 10
First CM generation : Process With Petri NetsWhat is a behavioral process in IS---at the
highest-abstract-level?
• States (instances) : In terms of (un-)availability. That a state instance is regarded as a resource
- Example : An account (instance) is a resource, a book (instance) is a resource.
• (State-based) Actions: The allowed ordering causality between states (instances) via actions (i.e. operations, methods).
- Example : First open-account, then deposit then looping withdraw-depsit-then close
Rigoros and Adaptive ... Information Systems 11
• Author : Carl-Adam Petri Live currently in Hamburg (honorary Professor at the Univ.)
• History: Model introduced by C.A. Petri in 1962– (Physics) Ph.D. Thesis:
“Communication with Automata”• PNs Applications: Distributed computing,
manufacturing, control, information systems, communication networks, transportation…
• Purpose: PNs specify / validate / verify explicitly and graphically:– sequencing/causality actions on states– conflict/non-deterministic choice actions– True concurrency actions on states
First CM generation : Process With Petri Nets
Rigoros and Adaptive ... Information Systems 12
(Introductory) Reference:• Tadao Murata. “Petri nets: Properties, Analysis
and Applications.” Proc. of the IEEE, 77(4), 1989.• Wolfgang Reisig, “Petri Nets”, Springer, EATCS
Monographs on Theoretical Computer Science, 1985 (Also in German).
First CM generation : Process With Petri Nets
Rigoros and Adaptive ... Information Systems 13
First CM generation : Process With Petri NetsConceptual philosophy under Petri nets:
1. In any system, we have resources- Artifact-based resources : data, objects,
events, - Real resources : printers, buffers, CPUs
2. There is generally, a number of available instances for each kind of resource in the system.
3. Actions (behavior, dynamics) in the system allows: - consuming (using) some resources and- producing new ones or updating existing
ones (under some conditions).
Rigoros and Adaptive ... Information Systems 14
• With each kind of ressource is described by:– a PLACE graphically as circle is associated
• Ressource instances are included as:– BLACK DOTS (called TOKENS) within the corresponding
ressource kind place.
• Actions called TRANSITIONS are:– graphically represented as a BOX or RECTANGLE.
• Ressources consumption are captured by:– INPUT ARCS---valuted or inscribed by the numbers of
required ressouces--- From the corresponding ressource place to the associated action box.
• Ressources production or changes are captured by:– OUTPUT ARCS---valuted or inscribed by the numbers of produced
ressouces--- From the associated action box to the corresponding target resource place
PETRI NETS ARE BIPARTITE GRAPHS
First CM generation : Petri Nets Concepts
Rigoros and Adaptive ... Information Systems 15
First CM generation : Petri Nets Concepts
2
4
30
P1
P2
T1
INPUT place withfive (5) tokens as MarkingINPUT place withfive (5) tokens as Marking
INPUT arc withtwo (2) (required tokens) as arc-inscription
INPUT arc withtwo (2) (required tokens) as arc-inscription
Transition named T1Transition named T1
OUTPUT arc withFour (4) (produced tokens) as arc-inscription
OUTPUT arc withFour (4) (produced tokens) as arc-inscription
OUTPUT place withthirty (30) tokens as markingOUTPUT place withthirty (30) tokens as marking
Rigoros and Adaptive ... Information Systems 16
First CM generation : Petri Nets Illustrations
BankOKToOpen
OpenAcnt
DepositOpened
AcntState
Withdraw DepositTransfert
Closed
Rigoros and Adaptive ... Information Systems 17
First CM generation : Petri Nets Illustrations
1
1
30
Books@LibraryToBorrow
Borow
1B
orro
wed
-Boo
ks
ToReturn
Return Return&Penalty
Penality2Pay
6
Card
Rigoros and Adaptive ... Information Systems 18
First CM generation : Petri Nets Strenghts
t1
t1 t2 t3
(b) Conflict t1 t2 t3
t2
© Concurrency
(a) Sequencetial execution
and choice
Rigoros and Adaptive ... Information Systems 19
First CM generation : Petri Nets Strenghts
t1 t2 t3
t1
t4
(d) Synchronation (e) Merging
Rigoros and Adaptive ... Information Systems 20
First CM generation : Petri Nets Typical Use
ToSend
Send msg
Receive Ack Send Ack
Receive msg
ToReceive
CommunicationProtocols
Rigoros and Adaptive ... Information Systems 21
First CM generation : Petri Nets Typical UseOperating Systems
Produce
Consume
Buffer
Rigoros and Adaptive ... Information Systems 22
First CM generation : Petri Nets Typical UseEmbedded Systems
Coins
Change
GetCigarett
e
GetCaffe
Machine-Items
GetWater
2$4$3$
75P
25P
Water Cigarette
Caffe
Rigoros and Adaptive ... Information Systems 23
First CM generation: Petri Nets FormalismsA Petri nets in a five tuples PN = (P, T, W, M0)
– P = {p1,p2, ....,pn} is a finite sets of places (circles)– T = {t1, t2, ...,tq} is a finite set of transitions
(boxes)– F (P x T) (T X P) is a finite set of arcs. An input
(resp. output) ) arc joins a place to transition (resp. transition to place). NEVER PLACE TO PLACE or TRANSITION TO TRANSITION.
– W : F {1,2,...} is a weight function attached to the arcs. If the weight in missing it is implicitly one.
– M0 : P {0,1,2,....} is the intial marking. M0(p), p P is the marking (i.e. numbers of tokens) of the place p.
Rigoros and Adaptive ... Information Systems 24
First CM generation: Petri Nets FormalismsNotations :
t : the set of input places of transition t. that is the set of places p such that (p,t) F.
– t : the set of output places of transition t. That is, p such that (t,p) F.
p : the set of input transitions of place p. that is the set of transitions such that (t,p) F.
– p : the set of output places of transition t. That is, t such that (p,t) F.
Rigoros and Adaptive ... Information Systems 25
Dynamics of Petri nets :– A transtion t is said to be enabled if, whatever
p t , p contains a number of tokens greater of equal than W(p,t) (i.e. M(p) W(p,t))
– Firing an enabled transition t, consists in :»Removing W(p,t) tokens from each p t »Adding W(t, p) tokens from each p t »That is, M‘(p) = M(p) – W(p,t) + W(t,p)
– A sequence of transitions firing is generally represented by = <ti1, ti2 , ....., tik>, and
– We say that the corresponding resulting marking is: M0 -- --Mk
First CM generation: Petri Nets Dyanmisms
Rigoros and Adaptive ... Information Systems 26
First CM generation : Petri Nets DynamismsOperating Systems Animated
Produce
Consume
Buffer
Rigoros and Adaptive ... Information Systems 27
First CM generation : Petri Nets DynamismsEmbedded Systems Animated
Coins
Change
GetCigarett
e
GetCaffe
Machine-Items
GetWater
5$4$3$
75P
25P
Water
Cigarette Caffe
1810 67
111
100
2
2
175
Rigoros and Adaptive ... Information Systems 28
H2
O2
H2O
t
2
2
First CM generation : Petri Nets Dynamisms
Chimical Reactions : 2H2 + O2 2H2O
Rigoros and Adaptive ... Information Systems 29
Incidence matrix : A = [aij]
– is an n m matrix of integers – its typical entry is given by
aij = aij+ - aij
-
– Where aij+ = w(T,P) is the weight of the
arc from transition T to its output place P
– and aij- =w(P.T) is the weight of the arc
from the input place P to the transition T.
First CM generation : Petri Nets Internals
Rigoros and Adaptive ... Information Systems 30
• Given an initial marking M0, let be a firiable sequence of transitions which applies to M0.
• The counting vector V of is the vector V = [v1,v2,..,vj,...vq] is the numbers of times tj is included in .
• If M is the marking obtained by firing , then: » Mt = M0
t + AVt .
With t denotes the transpose.
First CM generation : Petri Nets Internals
Rigoros and Adaptive ... Information Systems 31
Illustration:
2t1 p1 t2 p2 t4
t3 p3
p4
4
2
2
First CM generation : Petri Nets Internals
Rigoros and Adaptive ... Information Systems 32
t1 t2 t3 t4 p1 1 -2 -1 0 • A = p2 0 4 0 -1 p3 0 0 1 -1 p4 0 0 -2 2
Let M0 = [3,0,0,2] and = <t2,t3,t4>,
that is V = [0,1,1,1] .
Then M = [0, 3, 0, 2] using the formulas.
First CM generation : Petri Nets Internals