Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

2014 IEEE 38th Annual International Computers, Software and Applications Conference

Transformation from Activity Diagrams with Time


Properties to Timed Coloured Petri Nets

Xuling Chang, Linpeng Huang, Jianpeng Hu, Chen Li and Bei Cao
Department of Computer Science and Engineering, Shanghai Jiao Tong University, Shanghai, China
Email: {changxl, lphuang, mikerise, lcroy}@sjtu.edu.cn, caobei.sjtu@gmail.com

Abstract—The activity diagram is widely used for describing the practical usability of our proposed approach, a case study
and understanding workflows, however, it lacks a formal seman- with a GameCapture application is used as an example.
tics and cannot be manipulated by computer. In this paper, we
present a transformation from UML activity diagrams with time The remainder of the paper is organized as follows: Sec-
properties to timed coloured petri nets (TCPNs) in a formal way. tion II discusses the related works of this paper, Section III
We extend the activity diagram with time properties and a formal introduces the activity diagrams briefly, Section IV gives a
model named extended activity hypergraph (EAH) is defined. formal definition with a weak semantics for activity diagrams,
By mapping this formal model to a clocked transition system Section V demonstrates the transformation rules from activity
(CTS), we define a weak semantics for it. A list of transformation diagrams to timed coloured petri nets, and we also discuss the
rules are proposed to show how this can be transformed to a
TCPN model. We partially prove the model equivalence of the
equivalence of activity diagrams and the TCPN models which
two models. Finally, an example of GameCapture application is are transformed under our rules, and finally, in Section VI,
used to validate our approach. an example of GameCapture application to demonstrate the
practical usability of our method is discussed.
Keywords—Activity diagrams, Timed Coloured Petri Nets, Ex-
tended Activity Hypergraph, Model Transformation.
II. R ELATED W ORKS
I. I NTRODUCTION A graphical mapping of an activity diagram onto a coloured
The Unified Modeling Language (UML) [1] is a semi- petri net model is proposed in [9]. The authors do not show
formal language developed by the Object Management Group how they dealt with the analysis of concurrency of the system.
(OMG) [2] to describe the structural and behavioral aspects In [3] a transformation method from UML activity diagrams to
of the complicated software systems. Three categories of stochastic petri nets is proposed. It translates each diagram into
diagrams are defined in UML, i.e, static diagrams, behavioural LGSPN (Labeled Generalized Stochastic Petri Nets) and gains
diagrams and diagrams to organize and manage application a formal semantics for them, then composes these LGSPNs
modules [3]. Activity diagrams is a graphical language which together to gain an analyzable model. In [10] a novel approach
is consisted in behavioral diagrams. This diagram is also used for automatic transformation of SysML activity diagram into
and extended in other modeling languages such as System Timed Petri Net with Energy constraints (ETPN) is proposed.
Modeling Language (SysML) [4], Service Oriented Architec- Model equivalence is not discussed in their works.
ture Modeling Language (SoaML) [5], and a new UML profile In [11] a tool that supports verification of work flow model
dedicated for modeling and analysis of real-time and embedded specified in UML activity diagrams is described. The tool
systems (MARTE) [6]. translates an activity diagram into an input format for model
Timed Coloured Petri Nets (TCPNs) is a language for checker according to a mathematical semantics. In [12] a
modeling and validation of systems in which concurrency, formal verification framework for SysML activity diagrams
communication, and synchronisation play a major role [7]. is proposed. It is based on mapping a composition of SysML
The transformation from UML Activity diagram to TCPN activity diagrams to the input language of the probabilistic
is reasonable for 1) TCPN models are formal and have a symbolic model checker called “PRISM”.
mathematical definition of both its syntax and its semantics To enhance the confidence level of UML activity diagrams,
[8].2) TCPN has a strong ability to describe the real-time the syntax and semantics of UML activity diagrams with
systems with complex loop, concurrency events and data timing constraints are defined in [13]. The authors outline the
parsing behaviors. 3) The model constructed by TCPN can translation of their semantics into PROMELA input language
be verified by several tools available, like CPN tools. of the SPIN model checker.In [14], the authors show mapping
In this paper, we are interested in modeling and evaluating from UML activity diagrams to extended petri nets. However,
system with time properties such as real-time systems. We the authors do not study the semantics equivalence of the two
firstly extend the activity diagram with time properties and models.
define an extended activity hypergraph (EAH). The time prop- Eshuis and Wieringa define two formal semantics of activi-
erty can be added as an annotation. By mapping this EAH ty diagrams (requirement-level semantics and implementation-
model to a clocked transition system, a weak semantics for level semantics) in [15]. The semantics in their work is robust
EAH is defined. Thus we can execute a transformation from but complicated. And the data information is not defined
EAH to a TCPN model which is manipulatable by computer explicitly.
and can be used to verify system properties, i.e, performance
analysis. We use CPN Tools to carry out a simulation with data In this paper, we define the activity diagram with time
collector to analyze performance of the model. To demonstrate properties formally and give a weak semantics for it. The

0730-3157/14 $31.00 © 2014 IEEE 267


DOI 10.1109/COMPSAC.2014.36
semantics is inspired by works proposed in [15] and [13]. Our
semantics is simpler than the requirement-level semantics in
[15]. To maintain the equivalence of the model, we partially
prove the equivalence of the two model (EAH models and
TCPN models). We use a case to depict the practical usability
of our method.
Fig. 1. Relationship of transitions
III. ACTIVITY D IAGRAMS AND E XTENDED ACTIVITY
H YPERGRAPH
In this section, we discuss the most commonly used UML max(d) denote the minimum and maximum execution time
activity diagrams notions.An extended activity hypergraph is of d separately. Function node(d) denotes which node is d
then defined to simplify the activity diagrams. belonging to. We add a function called dura(n) for every
n ∈ N odes returning its duration d ∈ Dura. If a node
does not have a time property, a symbol  is used. So
A. Basic Notions dura(n) ∈ Dura ∪ {}.
A UML activity diagram is represented as a graph com-  Data is the data transforming between different nodes.
posed with nodes connected by control flows and object flows. We tag the data on a hyperedge to denote its transforming
For simplicity, we only consider the commonly contained types path. For each d ∈ Data. Function type(d) will return the
of nodes and arcs in UML activity diagrams.These nodes type of d. Since we have tagged the data t on the hyperedge
and arcs include Initial/Final Node, Activity Node, Object h, a function data(h) denoting the data that is transformed
Flow/Node, Decision/Merge Node and Fork/Join Node. through hyperedge h. If there is no data tagged on h, we use
Since we want to use the activity diagram to model the  to denote it. Then data(h) ∈ Data ∪ {}.
systems with time properties, time properties is added. The  V ar is the set of variables which are used in guard
time information contains the minimum and the maximum expressions.
execution time for an activity node. The data information is
input data and output data of an an activity node which is Definition 3.2: A f low of EAH is a sequence of nodes
represented by object flow. sn = n1 · n2 · . . . · ni · . . . where every two adjacent nodes
ni and ni+1 in sn are connected by an hyperedge e where
B. Extended Activity Hypergraph data(e) = {}.
In order to transform activity diagram into TCPN easily,
we firstly simplify the activity diagram. We are inspired by IV. S EMANTICS OF ACTIVITY D IAGRAM
the works in [15] and give an Extended Activity Hypergraph We use the requirement-level semantics of activity diagram
(EAH). We add time and data properties into the activity hy- in [15] and extended it to accommodate our newly defined
pergraph for analyzing performance of the model we construct. model. This formal semantics maps activity diagram into a
We then map the activity diagram onto EAH. The detail clocked transition system (CTS) [16], which can be used
of the transformation process will be shown in a later section. to model real-time systems. We add data flow information
We firstly give the definition of Extended Activity Hypergraph. explicitly to this model. We add data explicitly because it is
different from normal variables which not only have a value
Definition 3.1: An extended activity hypergraph is a turple but also can be moved between different nodes. Moreover,
EAH = (N odes, Events, Guards, HyperEdges, Data, the data information will change in different aspects (e.g type
Dura, V ar) where: and quantity) during a data flow depending on different input
 N odes is a set of nodes. Set N odes is partitioned into events.
set At of compound activities, set AN of activity nodes, one
initial node δInit and a final node set F N . A. Formal Semantics
 Events is the set of event expressions. Six kinds of We simplified the transitions of the requirement-level se-
events were mentioned in [15]: named external events, named mantics in [15] as Figure 1. We add a new transition →data
internal events, condition changed events, termination events, into the original requirement-level transitions and only reserve
and temporal events. Further introduction for these events is →time , →var and →step . Before we define the transitions,
in [15], and we do not distinguish these events in this paper we need some notions. We use C to denote the set of active
as it does not affect the running of target TCPN. nodes, which is also called the configuration in CTS. We get
the value of v by σ(v). Let ID denotes the set of input data.
 Guards is a set containing the guard functions. If variable guard is true, expression σ  guard denotes it
 HyperEdges are the relations between the nodes of [15]. Function dura(t) returns the maximum value of timer
activity diagram. Hyperedges have several parameters. For t. We now define set Disc = C ∪ ID ∪ V ar in the Clocked
every hyperedge h, source(h) denotes the nonempty set of Transition System, where V ar is the set of variables in the
source nodes of h and target(h) the nonempty set of target activity diagram which is defined in Section A.
nodes. Function guard(h) returns the guard function of h. If We then define the set of running timers. If the correspond-
a hyperedge has no guard function, a symbol ⊥ is used. Thus, ing node of the timer is in C, the timer is running.
guard(h) ∈ Guards ∪ {⊥}.
Definition 4.1: Set RT (C) is defined as
 Dura is the set of time properties. There are some
parameters for Dura. For each d ∈ Dura, min(d) and RT (C) ⇔ {t ∈ T imers|cnode(t) ⊂ C},

268
where cnode(t) denotes the corresponding node of timer t. J, D, M, P N, Arcs, T m, P I) , the Extended Activity Hyper-
graph as EAH = (N odes, Events, HyperEdges, Guards,
Definition 4.2: The passage of time is denoted by relation Data, Dura, V ar). The mapping from activity diagrams to
→time . Timers and the master clock is increased by a real activity hypergraphs were discussed in [15]. We add transfor-
number δ. Relation →time is defined as mation rules from activity diagram with time properties and
σ →time σ  ⇔ ∃δ ∈ R • δ > 0 data flows to our newly defined extended activity hypergraph.
∧ σ  = σ[M C/σ(M C) + δ, t∈σ(RT (C)) t/σ(t) + δ] Rule 4.1: For every f low in EAH, there is a correspond-
∧ ∀t ∈ RT (σ(C)) • σ(t) < dura(t), ing data instance d ∈ Data. Every f low has only one data
type.
where σ[ t∈T t/vart ] represents updating every variable in set
T with vart Rule 4.2: If the successor of init node is in a loop, this
init node is merged with its successor node. Similarly, if the
Definition 4.3: Relation →data denotes the receival of precursor of the f inal node is in a loop, this f inal node is
data. Elements in set ID will be replaced by all the data on merged with its precursor node.
the hyperedge which direct to current node. Then the data in
Rule 4.3: For every object flow in activity diagram, there
ID will be ready to be processed. And the running activity
is a corresponding hyperedge e in EAH. The object node is
will not change.
attached on e as a data instance. We use the first kind of object
σ →data σ  ⇔ σ(C) = σ  (C) flow to illustrate our rule. A node sequence (ai · oi · ai+1 ) is
used:
∧ σ(M C) = σ  (M C) ∧ ∃n ∈ N ode ∀(ai · oi ·ai+1 ) ∈ AD
• n ∈ σ(C) ∧ ∃H = ∅ • H ⊆ HyperEdges ∃e ∈HyperEdges
∧ (∀h ∈ H • n ∈ target(h) ⇒ ⇒ data(e) = oi ;
data(h)={}
 Rule 4.4: Every edge entering and leaving an F ork/Join
σ  = σ[ID/ data(h)]) node is merged into one hyperedge e. The object nodes passing
h∈H through the F ork/Join node is assigned to e.
Valuation σ[s/Xs] assigns variable Xs to variable s. ∀pn ∈ (F ∪J)∃e ∈ HyperEdges ⇒
Definition 4.4: Relation →var denotes the update of vari- source(e) = start(pn) • target(e) = end(pn)
ables. The variables of the system need to be calculated
before the step is token. We use function cal(v) to denote Rule 4.5: Every Decision/M erge nodes with n incoming
the calculation of variable v. Elements in set C, D, M C does edges or n outgoing edges will be mapped into n hyperedges.
not change. The object nodes passing through the Decision node will
be assigned to each hyperedge which is newly created. The
σ →var σ  ⇔ σ(C) = σ  (C) ∧ σ(ID) = σ  (ID) expressions is assigned to its corresponding hyperedges.
∧ σ(M C) = σ  (M C) ∧ ∀t ∈ RT (σ(C)) ∀pn ∈(D ∪ M )∃H ⊆ HyperEdges ⇒
∧ ∀v ∈ V ar • cal(v). (∀n ∈end(pn)∃e ∈ H ⇒ (source(e) = start(pn)
Definition 4.5: Relation →step denotes waking up a sleep- ∧target(e) = n) • pn ∈ D) ∨ (∀n ∈ start(pn)∃e ∈ H ⇒
ing node. A node n can be waked iff the guards on the (source(e) = n ∧ target(e) = end(n)) • pn ∈ J)
hyperedges which direct to n are all satisfied. After data passed
through an activity node, its content, type and amount may Further discussion on rules for mapping activity diagrams
changed. We use function process(ID) to process the current with no data flows can be found in [15] and [17].
data set ID.
σ →step σ  ⇔ ∃H ⊆ HyperEdge V. F ROM E XTENDED ACTIVITY H YPER G RAPH TO T IMED
∀h ∈ H ⇒ (source(h) ∈ C • σ  guard(h)) C OLOURED P ETRI N ETS
 A. Timed Coloured Petri Nets
∧ σ  = σ(C/ target(h), ID/process(ID)).
h∈H Timed coloured petri nets (TCPN) are new kind of CPN
models which timing information is added. This makes it
In the initial state, only σ0 is contained in the configuration, possible to evaluate how efficiently a system performs its
C = {σ0 }. The input data set is empty, ID = ∅. Timers in operations. With a TCPN model, performance measures such
set T imer is initialized using set Dura. Other variables are as mean waiting times can be calculated.
initialized appropriately.
B. Transformation Rules
B. From Activity Diagram to Activity Hypergraph We next transform the extended activity hypergraph EAH
In this section we firstly reduced the activity diagram by into TCPN model. A TCPN model contains elements like
mapping elements in the activity diagram into corresponding places, transactions, arcs, expressions, variables and some
elements in the activity hypergraph. We only show rules that functions. We use a to denote the arcs which direct from
we add for mapping activity diagrams with data flows. transitions to places. Similarly, a is used to denote the arcs that
directing from places to transitions. An activity node can be
We consider in the rest of this paper the activity diagram transformed into place or transition as were discussed in [15].
with time properties as T AD = (δInit , F N, AN, At, Obj, F, Here we choose to transform activity nodes into transitions. Let

269
cpnT be the target TCPN model. We use function ma(t) to Rule 5.6: Every one-to-many hyperedge in EAH is trans-
denote the maximum time of transition t and mi(t) to denote formed into a branch structure:
the minimum time, where t ∈ T . The transformation rules are
then listed below:
Rule 5.1: Every data instance has a corresponding color ∀e ∈ HyperEdges • |target(e)| > 1
set in TCPN model. 0
∃(ai · pi · a i · ti · (a0i+1 · p0i+1 · a i+1 , a1i+1
∀d ∈ Data∃c ∈ Σ ⇒ type(d) = c. 1
·p1i+1 · a i+1 , · · · , ani+1 · pni+1 · a i+1 )) ∈ cpnT
n

Rule 5.2: Every node n ∈ N odes in EAH is mapped into ∧(a∗ ∈ A • p∗ ∈ P • t∗ ∈T ) ∧ (data(e) = {}
transition t. If the hyperedge e that directing to n has a guard ⇒ C(p) = type(data(e))) ⇒ guard(e) = {⊥}
function G, a corresponding function is assigned to t. If the
duration of n exists, it is also assigned to t. where a∗ represents all arcs in sequence ai · pi · a i · ti · (a0i+1 ·
0 1
p0i+1 · a i+1 , a1i+1 · p1i+1 · a i+1 , · · · , ani+1 · pni+1 · a i+1 ), so as
n
∀n ∈ N odes∃t ∈ T ∧ (time(n) = {} ⇒
∗ ∗
(G(t) = guard(n)•guard(n) = {⊥}) p and t . This rule is shown in Figure 5.
∧(ma(t) = max(d) • mi(t) = min(d)•
dura(t) = {d} • d = ) C(d)
(d) @+0
Rule 5.3: For the node which is directed from initial
node, a place with time variable is used to form a self loop. C(d)
This rule is aimed at ensuring the correctness of the master
timer in a TCPN model. C(d)

∀n ∈ N odes ∧ (∀e ∈ HyperEdges• Fig. 5. Rule 5.6: branch structure.


source(e) =initial ⇒ n ∈ target(e))
⇒(ti · ai · pi · a i · ti ) ∈ T CP N Rule 5.7: For each many-to-one hyperedge in EAH is
converted into a merge structure, which is shown in Figure
Rule 5.2 and Rule 5.3 is shown in Figure 2. 6:
∀e ∈ HyperEdges • |source(e)| > 1
0 1
{m, n} e e ∃((a0i · p0i · a i , a1i · p1i · a i , · · · , ani · pni
·a i ) · ti+1 · ai+1 · pi+1 · a i+1 ) ∈ cpnT
n
@[m, n]
@[m, n]
∧a∗ ∈ A•p∗ ∈ P • t∗ ∈ T ∧ (data(e) = {}
Fig. 2. Rules 5.2 and 5.3 : rules for nodes ⇒ C(p) = type(data(e))) ⇒ guard(e) = {⊥}
Rule 5.4: For the node which is the start node of a f low in
EAH, a Queue structure formed by TCPN nodes is inserted C(d)
after it. An example of queue structure in TCPN is shown in
Figure 3. (d) @+0 C(d)

colset F = with f timed;


colset Flist = list F;
C(d)
1`[ ] @+0
flist^^[f1] f1::flist var flist : Flist;
var f1 : F
1`f1 FormQ Queue
1`flist
F
flist Fig. 6. Rule 5.7: join rule.

Fig. 3. An example of Queue structure in TCPN model: a list is used to


contain the variables in Queue.
C. Discussion on Model Equivalence
Rule 5.5: Every one-to-one hyperedge in EAH attached
with a data is transformed into a place with an input arc and As we discussed above, a weak semantics for activity
an output arc, which is shown in Figure 4: diagrams is defined. Transformation from activity diagram into
TCPN model can be carried out according to the rules in
∀e ∈ HyperEdges∃a ∈ A • a ∈ A • p ∈ P Section V. Inspired by [18], we discuss the model equivalence
⇒ (a · p · a ) ∈ cpnT ∧ (data(e) = {} ⇒ here.
C(p) = type(data(e))) Theorem 5.1: Let ahE be an extended activity hypergraph
and cpnT its corresponding timed coloured petri net obtained
following our transformation rules. If sa is a run of ahE and
(d)
st is a sequence of cpnT . Then (1) ∀sa ∈ ahE , ∃st ∈ cpnT
C(d) and (2) ∀st ∈ cpnT , ∃sa ∈ ahE

Fig. 4. Rule 5.5: rule for transforming edges. Due to the page limited, we will not give a detailed proof
of the theorem.

270
@[1, 3] [f1=g] @[2, 4]
After After
Begin 1`f1 Copy
Begin Draw
Scene 1`f1 Frame
Scene Indicator F colset F = with f | g timed;
1`f1 F colset E = with e timed;
1`f1 1`f1
@[1, 3] After
Afte colset Flist = list F;
<<DrawRed>> {1} Render
d 1`f1
{1, 3} Copy var flist : Flist;
Draw Red After
Afte Frame @+1 var f1:F;
<<Render>> Frame
ram F
Diamond Game
(f) Render Frame F 1`f1 Draw 1`f1
Logic
g
(f) (f) [H] Indicatorr @+0
@[2, 4] Afte
After 1`f1
(f) Fork1
<<HookJump>> {2, 4} Render
{1, 3} Goto Hooked [G] ram
Frame
<<CopyFrame>> 1 1`e @0.0 1`f1 1`f1 Decision
cision Fork1_2
<<BScene>> Function e Game 1`f1 F
Copy BackBuffer TImer F
Begin Scene {1} Logic @+1 1`f1
(f) Frame e Afte
After @+1
E Hookk
(f) Hook O
Open
Jump
ump 1`f1 1`f1 1`f1
(f) flist f1::flist Jumpp File
F
1`[ ] if f1=f 1`f1
{1} Queue
<<Game>> {2, 4} then 1`f1 After
Afte
<<Openfile>>
Game Logic @+5 else empty Open
Open file to
write 1`flist flist^^[f1] File F
<<Present>> Present if f1=g Fork1_1 1`f1
Draw a Frame (f) @+0 Frame then 1`f1 F @+0
(f) {5} FormQ else empty 1`f1 1`f1
1`f1 Fork2
{12, 16}
<<EScene>> {1, 2} <<Enc>> 1`f1 After
Afte
End Scene Encode Present Fork2_1 Fork2_2
1`f1 F F
<<VPP>> {2, 4} Frame F
@[15, 18] 1`f1 @[12, 16]
Video Processing <<Write>> Prepare
Write File VPP 1`f1 After 1`f1
{15, 18} Enc
F Enc
(f) 1`f1 @[2, 4]
@[1, 2] 1`f1 W it
Write F
(f)
EEnd
d After
Aft File 1`f1
Scene VPP F @+0
<<CloseFile>> 1`f1 After
Afte
CLose File Join Write
1`f1 File F
1`f1
After
Close After
Af
Close
File 1`f1 Join
File F

Fig. 7. Transformation from activity hypergraph to TCPN model : Example of GameCapture Application

VI. C ASE S TUDY: T HE G AME C APTURE A PPLICATION corresponding colour set and variables for a Queue structure
of TCPN model is added. Transformation for hyperedges and
As an example of the our transformation method and nodes is under Rules 5.2, 5.5, 5.6, 5.7. Note that, the guards
its practical usability, we show a GameCapture application. and condition expressions need to be fixed manually according
This program is implemented based on an open-source project to different case. This transformation result is shown on the
TAKSI[19]. right of Figure 7.
In this scenario we assume that the user wants to record
the video when he is playing his favorite game. In order to B. Simulation and Analysis
generate a video, at least 24 frames per second need to be We add a data collector to transition “Present Frame” and
recorded and encoded. For simplicity, we firstly consider using test the data throughput capacity and data transforming speed
a single thread program. However, the performance is poor in of the two TCPN models using CPN Tools. The simulation
SOFTWARE mode. To improve its performance, we consider method is discussed in [7]. We simulate 2000ms to collect
using a Multi-Thread architecture. We reconstruct this model the frame amount and calculate the processing speed. The
into a multi-thread one by executing the VPP (Video Pre- simulation results are as shown in Figures 8 and 9. We can see
processing) module and the Encoder module concurrently. the multi-thread model performs better than the single-thread
model from this simulation result.
A. Model Transformation

We transform the two model (single-thread and multi-   
  

thread) into TCPN models under our transformation rules. We
only show the transformation of multi-thread model and the 

transformation of the single-thread model is similar.






We firstly transform the original activity diagram with 

time properties into our extended activity hypergraph, which 


is shown on the left of Figure 7. The initial node and final

node is eliminated based on Rule 4.2. Activity nodes, pseudo             
nodes and arcs are transformed properly into EAH model. The 
condition expressions of Decision nodes is rewritten into in-
dependent expressions. Then we transform this newly achieved Fig. 8. Number of processed frames in the two models during 2000ms
EAH model into a TCPN model under our transformation
rules. Due to the model has only one f low, a colour set F
C. Implementation
and a corresponding variable f 1 is defined based on Rules
4.1 and 5.1. A Queue structure is inserted after the place In order to validate our method, we implemented our
named “prepare” under Rule 5.4. A place named “timer” is GameCapture application using the two system model we have
added to the transition “Game Logic” due to Rule 5.3. The discussed: single-thread model and multi-thread model.

271

   described in this paper was supported by the National Natural
    Science Foundation of China under Grant No. 61232007,

  91118004, and the Innovation Program of Shanghai Municipal
Education Commission (No. 13ZZ023).



R EFERENCES
[1] O. Uml, “2.0 superstructure specification,” OMG, Needham, 2004.
 [2] O. CORBA, “Object management group,” 1999.
          

[3] J. P. López-Grao, J. Merseguer, and J. Campos, “From uml activity
diagrams to stochastic petri nets: application to software performance
engineering,” ACM SIGSOFT software engineering notes, vol. 29, no. 1,
Fig. 9. The processing speed of two models models during 2000ms pp. 25–36, 2004.
[4] O. OMG, “Systems modeling language (sysml),” OMG Available Spec-
ification, 2007.
This application is based on an open-source project [5] M. OMG, “Service oriented architecture modeling language (soaml),”
TAKSI[19]. We test these two applications by capturing 2008.
and encoding under different screen resolution: 320 × 240, [6] ——, “Modeling and analysis of real-time and embedded systems,”
640 × 480, 800 × 600, 1024 × 768, 1280 × 720, 1440 × 900, Object Management Group, 2008.
1920 × 1080. We test its ultimate processing speed in Frame [7] K. Jensen, L. M. Kristensen, and L. Wells, “Coloured petri nets and cpn
Per Second. A personal computer (core i7-3630qm processor tools for modelling and validation of concurrent systems,” International
CPU, with 8 GB RAM) is used as experiment platform. The Journal on Software Tools for Technology Transfer, vol. 9, no. 3-4, pp.
213–254, 2007.
experiment results are shown in Figure 10.
[8] K. Jensen, L. M. Kristensen, and L. L. M. Kristensen, Coloured Petri
nets: modelling and validation of concurrent systems. Springer, 2009.

    [9] H. T. Jung and S. H. Joo, “Transformation of an activity model
   
 into a colored petri net model,” in Trendz in Information Sciences &
Computing (TISC), 2010. IEEE, 2010, pp. 32–37.


 [10] E. Andrade, P. Maciel, G. Callou, and B. Nogueira, “A methodology


for mapping sysml activity diagram to time petri net for requirement
 validation of embedded real-time systems with energy constraints,” in
Digital Society, 2009. ICDS’09. Third International Conference on.
 IEEE, 2009, pp. 266–271.

[11] R. Eshuis and R. Wieringa, “Tool support for verifying uml activity
      diagrams,” Software Engineering, IEEE Transactions on, vol. 30, no. 7,
 pp. 437–447, 2004.
[12] S. Ouchani, O. A. Mohamed, and M. Debbabi, “A formal verification
Fig. 10. Ultimate processing speed of these two application framework for sysml activity diagrams,” Expert Systems with Applica-
tions, vol. 41, no. 6, pp. 2713–2728, 2014.
[13] N. Guelfi and A. Mammar, “A formal semantics of timed activity dia-
From the experiment result, we can see the multi-thread grams and its promela translation,” in Software Engineering Conference,
application performs better, which is in consistent with the 2005. APSEC’05. 12th Asia-Pacific. IEEE, 2005, pp. 8–pp.
simulation result. [14] N. Yang, H. Yu, H. Sun, and Z. Qian, “Mapping uml activity diagrams
to analyzable petri net models,” in Quality Software (QSIC), 2010 10th
International Conference on. IEEE, 2010, pp. 369–372.
VII. C ONCLUSION
[15] H. Eshuis, “Semantics and verification of uml activity diagrams for
In this paper, we add time properties into the activity workflow modelling,” 2002.
diagrams and then define an extended activity hypergraph. [16] Y. Kesten, Z. Manna, and A. Pnueli, “Verification of clocked and hybrid
By mapping the extended activity hypergraph into a clocked systems,” Acta Informatica, vol. 36, no. 11, pp. 837–912, 2000.
transition system, a weak semantics is defined for it. To [17] R. Eshuis, “Model checking activity diagrams in tcm,” Citeseer, Tech.
analyze the activity diagram with time properties, we transform Rep., 2001.
its corresponding extended activity hypergraph into a timed [18] J. Bowles and D. Meedeniya, “Formal transformation from sequence
diagrams to coloured petri nets,” in Software Engineering Conference
coloured petri net model. A list of transformation rules is (APSEC), 2010 17th Asia Pacific. IEEE, 2010, pp. 216–225.
then defined. We only give the basic transformation rules [19] D. Robinson, “Taksi: Video capture/screen capture for 3d graphics.”
dealing with simple notions and structures of activity diagram http://taksi.sourceforge.net/, 2006.
in this paper. We use an extended activity hypergraph with
weak semantics as the intermediate model for: (1) The weak
semantics by CTS is based on state chart which is very close to
activity diagram; (2) The CTS semantics have time properties
inherently, it is easy to be transformed into TCPN model.
Finally, we discuss the equivalence of the two models and
partially prove the equivalence of the two model. Further
discussions on model equivalence need to be studied in the
future.

ACKNOWLEDGMENT
We would like to express our special thanks to Rik Eshuis
for his helpful suggestions to improve the paper. The work

272

You might also like