Petri Nets <-> Erlang (was: UML <-> Erlang)

C.Reinke <>
Wed Nov 19 15:05:10 CET 2003


> It would seem that there is a general feeling that UML is not
> quite suited to the task.  The question begs, what IS suited to
> Erlang.  having a look at some of the sugestions (SDL etc), but we
> use ad hoc diagrams as well.  Perhaps we can find some comonality
> in all the ad hoc methods for Erlang and find a better tool that
> way?

One graphical notation I'd strongly suggest to look into are Petri
Nets, especially high-level, or Coloured Petri Nets:

  Petri Nets World --
  online services for the international Petri Nets community
  http://www.daimi.au.dk/PetriNets/

Petri Nets (PN) describe communicating automata - the state machines
you all know and love in a concurrent setting, with localised state,
localised state transitions, and explicit, asynchronous
communication between subsystems. Very much in the spirit of Erlang.

High-level nets add inscriptions in some programming language, to
describe data structures and their processing (example inscription
languages are predicate logic, Standard ML, Haskell, or Java).

If you were to use Erlang-coloured nets, you could use a single
uniform notation to go from first graphical sketches of a system, to
abstract models that can serve as specifications and as the basis
for simulating systems (to search for performance problems), to full
implementations where the net part serves as structured and
executable documentation. 

PN do have a proper, and simple formal basis that allows for
analysis and simulation, but they also provide a simple, intuitive
graphical notation accessible to non-experts. PN predate UML and
have been widely used (including, but by no means limited to
modeling, analysis and performance evaluation of manufacturing and
telecomunication systems) - they also form the background for some
workflow and business process modeling systems, and they are behind
some of the model checking tools you may have heard about in other
contexts.

Please have a look, and let me know what you think.

Cheers,
Claus

PS. The Petri Nets Home Page provides links/references to everything,
    including introductions, applications, tools. Of more dubious
    value are an overview talk I gave myself a long time ago to my
    colleagues here in Kent:

      http://www.cs.kent.ac.uk/~cr3/talks/#PetriNets
    
    and a paper outlining how to obtain a simple but cheap first
    implementation of F-coloured PN (for some functional language F)
    by embedding them into their inscription language F:

      http://www.cs.kent.ac.uk/people/staff/cr3/publications/HCPN.html




More information about the erlang-questions mailing list