SlideShare uma empresa Scribd logo
1 de 74
Baixar para ler offline
State Space C-Reductions
of Concurrent Systems in Rewriting Logic

    Alberto Lluch, Andrea Vandin              José Meseguer
              IMT Lucca                            UIUC




International Workshop on Rewriting Logic and its Applications (WRLA'12)
                      Tallin, March 24-25, 2012
state space explosion


        0 3 8 ... 6

1 binary counter has ...   2 states

1 n-ary counter has ...    n states     (data abstraction)

m n-ary counters           Mn states!   (symmetries,
                                         concurrency, etc.)
running example



$ = transfer of 1$

x$   = account with x$
credit rule



$

x$                 x+1$
$    $
                        Isomorphic...
                         Isomorphic...
                        but syntactically different
                         but syntactically different
          0$   0$




     $              $

1$   0$             0$      1$




          1$   1$
symmetries in state space exploration problems
some tools with symmetry reduction


   Murphy [Ip&Dill@FMSD'96];
   Symmetric SPIN [Bosnacki et al.@SPIN'00];
   TopSPIN [Donaldson et al.@AMAST'06];
   Groove [Rensink@GRABATS'06];
   MiHDa [Montanari et al.@FMCO'02];
   PRISM-symm [Ball et a@CAV06];
   Planners, constraint solvers, etc.
some drawbacks

✗ Symmetries denoted with extra primitives;
✗ Limited, fixed symmetry classes;
✗ Rigid “flexibility” vs “guarantees” tradeoff;
✗ Complex changes to model checker;
✗ Unofficial extensions of model checkers;
✗ No support for checking correctness.
Can we use rewriting logic to...


 (i) generalize symmetry reduction techniques?
   ✔ Define the c-reduction of a Kripke structure;

   ✔ C-reductions subsume typical symmetry reductions.



(ii) provide some advantages?
   ✔ Define c-reductions using equations (not in the engine);

   ✔ Provide a tool supported verification methodology.



(iii) provide a faster state space exploration?
   ✔ Many experiments.
Can we use rewriting logic to...


 (i) generalize symmetry reduction techniques?
   ✔ Define the c-reduction of a Kripke structure;

   ✔ C-reductions subsume typical symmetry reductions.



(ii) provide some advantages?
   ✔ Define c-reductions using equations (not in the engine);

   ✔ Provide a tool supported verification methodology.



(iii) provide a faster state space exploration?
   ✔ Many experiments.
A Kripke structure is a tuple K = (S , → , L, AP) such that
   S is a set of states;
   → ⊆ S × S is a transition relation;                  $    $    p

   AP are atomic propositions;                          0$   0$

    L: S → 2AP maps states into AP subsets.
                                                  $    p,q             $         p,q

                                            1$    0$                   0$   1$


       p = there is some empty account
                                                                   q

       q = there are one or less dollars around
                                                         1$   1$
A bisimulation between two Kripke structures K and H
is a binary relation ∼ ⊆ SK × SH such that s∼s' implies
   LK(s) = LH(s');
   s →K r implies s' →H r' and r∼r' for some r';             s →K r
                                                              ≀     ≀
   vice versa.                                              s' →H r'
                                         p                                        p
                               $    $                                   $    $


                               0$   0$                                  0$   0$




           p,q        $                      $         p,q              $
                                                                                 p,q

                 1$   0$                     0$   1$                    0$   1$




                           q                                                          q
                               1$   1$                                  1$   1$
A ∼-canonizer for
   – a Kripke structure K
   – and an equivalence (bisimilation) relation ∼ ⊆ S × S
is a function c : S → S such that s∼c(s) for all states s.



                                              c
                $           c          $

          1$   0$                     0$    1$
A ∼-canonizer is strong if s∼s' implies c(s) = c(s')
      (i.e. if canonical representatives of ∼-equivalence classes are unique)




                                 2$      1$       3$                                                 2$        1$        3$

      1$    3$    2$            c                                                                c
                                                                  1$        3$    2$
            c                                 c
                                                                   c
                 1$    2$   3$                                                   1$    2$   3$
                                    2$    3$       1$                                                     2$        3$        1$
                  c
3$   1$    2$               c                           3$   1$        2$
                                                                                                               c

                 3$    2$   1$                                                   3$    2$   1$




                                              otherwise we call them weak.
The c-reduction of a Kripke structure
     K = (S , → , L, AP)
                                   $       $
is
     Kc = (S , →;c , L, AP)        0$ 0$



                              $                $

                           1$ 0$       c       0$ 1$




                                   1$ 1$
Th. If c is a ∼-canonizer then Kc ∼ K.
Can we use rewriting logic to...


 (i) generalize symmetry reduction techniques?
   ✔ Define the c-reduction of a Kripke structure;

   ✔ C-reductions subsume typical symmetry reductions.



(ii) provide some advantages?
   ✔ Define c-reductions using equations (not in the engine);

   ✔ Provide a tool supported verification methodology.



(iii) provide a faster state space exploration?
   ✔ Many experiments.
some symmetry reductions captured


   Full symmetries;
   Rotational symmetries;
   Name reuse (garbage collection);
   Name abstraction.
Can we use rewriting logic to...


 (i) generalize symmetry reduction techniques?
   ✔ Define the c-reduction of a Kripke structure;

   ✔ C-reductions subsume typical symmetry reductions.



(ii) provide some advantages?
   ✔ Define c-reductions using equations (not in the engine);

   ✔ Provide a tool supported verification methodology.



(iii) provide a faster state space exploration?
   ✔ Many experiments.
What is RL?

A rewrite theory R is a tuple (Σ , E ∪ A , R , ϕ)

    Σ = signature (e.g. syntax);

    E = equations (e.g. functions);     Not all equivalence relations ∼
                                         Not all equivalence relations ∼
                                        are tractable as axioms

    A = axioms (e.g. ACI);               are tractable as axioms

    R = rules (e.g. non deterministic behaviour);

    ϕ = frozennes map (e.g. rewrite strategy).

Some assumptions:

    R has good executability properties;

    Topmost rules for a designated [State] kind.
--- The main module defining the signature and one initial state

fmod BANK is

  ...

  sorts Object Message Configuration State .

  subsort Message Object < Configuration .



  op <_|_> : Nat Nat -> Object [ctor] .

  op credit : Nat -> Message [ctor] .

  op __ : Configuration Configuration -> Configuration [ctor assoc comm] .

  op none : -> Configuration [ctor] .

  op {_} : Configuration -> State [ctor frozen] .



  --- A simple initial state                                       $    $

  op init : -> Configuration .
                                                                   0$   0$
  eq init =    < 0 | 0 >   < 1 | 0 > credit(0) credit(1) .



endfm
--- The behavioural rules of the example
mod BANK-RULES is


                                     $
  inc BANK .


  vars i x : Nat .
                                    x$         x+1$
  vars c1 : Configuration .


  --- A simple rule for crediting an account
  rl [credit] :
         { < i | x    > credit(i)   c1 }
       => { < i | s(x) >            c1 } .


endm
search without reduction                                    $   $

                                                                           0$ 0$
Maude> search in BANK-RULES : {init} =>* s:State .
                                                                       $           $

Solution 1 (state 0)                                            1$ 0$              0$ 1$

s:State --> {credit(0) credit(1) < 0 | 0 > < 1 | 0 >}



Solution 2 (state 1)                                                       1$ 1$

s:State --> {credit(1) < 0 | 1 > < 1 | 0 >}


                                                         symmetric states
Solution 3 (state 2)

s:State --> {credit(0) < 0 | 0 > < 1 | 1 >}



Solution 4 (state 3)

s:State --> {< 0 | 1 > < 1 | 1 >}



No more solutions.

states: 4   rewrites: 6 in 0ms cpu (2ms real) (9523 rewrites/second)
c-extension

The c-extension of a rewrite theory
      R = (Σ, E ∪ A , R, ϕ)
is
      Rc = (Σ ⊎ Σc, E ∪ Gc ∪ A , R , ϕc)
i.e. a correct extension of R with the definition of c.
module architecture
                 BANK



BANK-RULES (R)



                            BANK-C (Rc)
c-extension (example of canonizer)
--- The c-extension of BANK that defines the c-canonizer for object permutations

mod BANK-C is

  ...

  op c : State -> [State] .



  vars i j x y : Nat .

  vars c1 : Configuration .



  ceq    c( {                 < i | x > < j | y > c1   } )

        = c( { [[ i <-> j ]]( < i | x > < j | y > c1 ) } )

        if [[ i <-> j ]]( < i | x > < j | y > c1 )

           <# < i | x > < j | y > c1 .



  eq c({c1}) = {c1} [ owise ] .



endm
module architecture

                 BANK



BANK-RULES (R)            BANK-PERMUTATION



                            BANK-C (Rc)
c-extension (example of transpositions)
--- Implementation of object permutations

fmod BANK-PERMUTATION is

  ...

  op [[_<->_]] _ : Nat Nat Configuration -> Configuration [frozen] .

  op [[_<->_]] _ : Nat Nat Nat -> Nat .



  eq [[ i <-> j ]](none) = none .

  eq [[ i <-> j ]](obj1 c1) = ([[ i <-> j ]](obj1)) ([[ i <-> j ]](c1)) .

  eq [[ i <-> j ]](msg1 c1) = ([[ i <-> j ]](msg1)) ([[ i <-> j ]](c1)) .

  eq [[ i <-> j ]](< k | x >) = < [[ i <-> j ]](k) | x > .

  eq [[ i <-> j ]](credit(k)) = credit([[ i <-> j ]] k) .

 eq [[ i <-> j ]](i) = j .

  eq [[ i <-> j ]](j) = i .

 ceq [[ i <-> j ]](k) = k if (i != k) / (j != k) .



endfm
Identification of symmetric states

Maude> red c( {credit(0) < 0 | 0 > < 1 | 1 >}) .
result State: {credit(1) < 0 | 1 > < 1 | 0 >}
                                                   $
                                                   0$ 1$

                                                       c
                                                       $
                                                   1$ 0$
The c-reduction of a rewrite theory
     R = (Σ, E ∪ A , R , ϕ )
is
     Rc = (Σ ⊎ Σc, E ∪ Gc ∪ A , Rc , ϕc)

                                            cc
where Rc is made of rules      K(Rcc)= K (R)
                               K(R ) =     K (R)
     l => c(r) if cond
for each rule of R
     l => r          if cond
module architecture
                 BANK



BANK-RULES (R)             BANK-PERMUTATION



                              BANK-C (Rc)



                        BANK-C-REDUCTION (Rc)
c-reduction (example)
--- The c-reduction of BANK-RULES
mod BANK-C-REDUCTION is


  inc BANK-C .


  rl [credit] :
            { < i | x     > credit(i) c1 }
       => c({ < i | s(x) >           c1 }) .


endm
search in c-reduced state space
Maude> search in BANK-C-REDUCTION : {init} =>* s:State .

search in BANK-C-REDUCTION : {init} =>* s:State .

                                                              $        $

Solution 1 (state 0)
                                                              0$       0$
s:State --> {credit(0) credit(1) < 0 | 0 > < 1 | 0 >}


                                                         $                  $
Solution 2 (state 1)                                               c


s:State --> {credit(1) < 0 | 1 > < 1 | 0 >}         1$   0$                 0$   1$




Solution 3 (state 2)

s:State --> {< 0 | 1 > < 1 | 1 >}
                                                              1$       1$



No more solutions.

states: 3   rewrites: 25 in 0ms cpu (2ms real) (53648 rewrites/second)
Can we use rewriting logic to...


 (i) generalize symmetry reduction techniques?
   ✔ Define the c-reduction of a Kripke structure;

   ✔ C-reductions subsume typical symmetry reductions.



(ii) provide some advantages?
   ✔ Define c-reductions using equations (not in the engine);

   ✔ Provide a tool supported verification methodology.



(iii) provide a faster state space exploration?
   ✔ Many experiments.
Does c provide a correct c-reduction?
Th 1. “K(Rc) is bisimilar to K(R)” (desiderata)

Lemma 0. “Relation ∼ is an equivalence relation”
  (i) Check that the action of the group is correct.


Lemma 1. “Relation∼ is a bisimulation”                 Proof plan for
  (ii) Check that ∼ strongly respects AP;              group-theoretic
 (iii) Check that ∼ and R “commute”.                   reductions


Lemma 2. “Function c is a ∼-canonizer”
 (iv) Check that c is a ∼-canonizer.
modules and checks
                  BANK                    check (i)


BANK-RULES (R)
                 BANK-AP   BANK-PERMUTATION (R∼)

                                          check (iv)
check (iii)
check (ii)                       BANK-C (Rc)
         BANK-PERMUTATION-RULES (R∼)

                           BANK-C-REDUCTION (Rc)
group theoretic equivalence relations


The action ⟦∙⟧ of a group G on S defines an equivalence relation:


       s∼s' iff ⟦ f ⟧(s) = s' for some f ∈ G.
modules and checks
                  BANK                    check (i)


BANK-RULES (R)
                 BANK-AP   BANK-PERMUTATION (R∼)



                                 BANK-C (Rc)
      BANK-PERMUTATION-RULES (R∼)

                           BANK-C-REDUCTION (Rc)
(i) Checking group actions

Implement the action ⟦∙⟧ of G on S as
       [[_]]_ : G State ->State .
… but we just need to implement the action of the generators.


Check that the we actually have a group action by showing:
      ⟦g⟧⟦g-1⟧(s) = s for each generator g of G.
      HINT: induction on S (structure of states).


For example, in the case of permutations one has to show
      [[ i <-> j]] ([[ i <-> j]] (s)) = s
(i) Checking group actions

Implement the action ⟦∙⟧ of G on S as
          [[_]]_ : G State ->State .
… but we just need to implement the action of the generators.


Check that the we actually have a group action by showing:
   ⟦e⟧(s) = s, for e the identity of G;
   ⟦g ∘ g'⟧(s) = ⟦g⟧(⟦g'⟧(s)) for each pair of generators g, g' of G;
   ⟦g⟧⟦g-1⟧(s) = s for each generator g of G.
HINT: induction on G (generators ) and S (structure of states).
modules and checks
                  BANK


BANK-RULES (R)
                 BANK-AP   BANK-PERMUTATION (R∼)



check (ii)                       BANK-C (Rc)
         BANK-PERMUTATION-RULES (R∼)

                           BANK-C-REDUCTION (Rc)
(ii) Checking that ∼ strongly preserves AP

IDEA: Define a rewrite theory R∼ to “move” inside orbits:

      R∼ = (Σ ⊎ Σ∼, E ∪ E∼ ∪ A , R∼ , ϕ)
where R∼ = { s => [[g]](s) }


Theorem: ∼ strongly preserves AP if AP is stable in R∼.
Can we check such stability automatically?
Yes, with InvA (under some conditions)
fmod BANK-AP is

  eq [two-dollars-eq] : two-dollars({ < i | s(s(x)) > c1 }) = true .

endfm



fmod BANK-PERMUTATION-RULES is

  rl [transposition] :    {                 < i | x > < j | y > c1    }

                         => { [[ i <-> j ]] ( < i | x > < j | y > c1) } .

endm



Maude> (analyze-stable two-dollars(s:State) in BANK-AP BANK-PERMUTATION-RULES .)

rewrites: 15571 in 16ms cpu (19ms real) (918643 rewrites/second)

Checking BANK-PERMUTATION-RULES ||- two-dollars => O two-dollars ...

Proof obligations generated:    2
                                         For non discharged proof obligations
Proof obligations discharged: 2           For non discharged proof obligations
Success!
                                         one can use the Maude ITP tool
                                          one can use the Maude ITP tool
modules and checks
                  BANK


BANK-RULES (R)
                 BANK-AP   BANK-PERMUTATION (R∼)


check (iii)
                                 BANK-C (Rc)
         BANK-PERMUTATION-RULES (R∼)

                           BANK-C-REDUCTION (Rc)
(iii) Checking that ∼ and R commute

                                                     R
                         u                                 v




                                                     R
                        u'                                 v'
For all equivalent states u, u' and for all R-transitions from u to v.
(iii) Checking that ∼ and R commute

                                                   R
                        u                                v




                     R∼                                      R∼
                      *                            R         *
                        u'                               v'
For all R∼reachable pairs of states u->u' and for all R-transitions from u to v.
(iii) Checking that ∼ and R commute

                                                    R
                         u                                  v
                     R∼                                          R∼
                                                    R            *
                        u1'                                v1'
                     R∼                                          R∼
                                                    R
                                                                 *
                        u2'                                v2'


                                                    R
                        u'                                 v'
For all R∼-transitions u->u' and for all R-transitions from u to v.
Consider:
                    Each R-rules from l => r
                    Each R∼-rules l' => r'

                         R
θ'(l') ≡A θ(l)                 θ(r)




                                    R∼
R∼
                           R        *
θ'(r')                          w
(iii) Checking that ∼ and R commute
              R                For all R∼-transitions u → u' and
 u                 v
                        R∼     for all R-transitions from u to v.
R∼
                        *
              R
 u'                v'
              R
θ(l)              θ(r)
                               For all R∼-rules l' => r' and
                               for all R-rules from l => r.


R∼                R∼        Similar functionalities (e.g. critical pair generation)
                              Similar functionalities (e.g. critical pair generation)
                            are already available in some Maude tools
             R          *     are already available in some Maude tools
θ'(r')             v'       (e.g. in the Coherence Checker).
                              (e.g. in the Coherence Checker).
(iii) Checking that ∼ and R commute

IDEA: Show joinability of critical pairs (R rules vs R∼)




Theorem: If all such pairs are joinable, ∼ is a bisimulation
modules and checks
                  BANK


BANK-RULES (R)
                 BANK-AP   BANK-PERMUTATION (R∼)

                                          check (iv)

                                 BANK-C (Rc)
      BANK-PERMUTATION-RULES (R∼)

                           BANK-C-REDUCTION (Rc)
(iv) checking that c is a ∼-canonizer


IDEA: Exploit the form of typical reduction strategies:
     Local strategies
     c({t}) = c([[g]]({t})) if [[g]]({t})<{t}
     c({t}) = {t} [owise]


     Enumeration strategies
     c({t}) = min{[[f]]({t})}
Can we use rewriting logic to...


 (i) generalize symmetry reduction techniques?
   ✔ Define the c-reduction of a Kripke structure;

   ✔ C-reductions subsume typical symmetry reductions.



(ii) provide some advantages?
   ✔ Define c-reductions using equations (not in the engine);

   ✔ Provide a tool supported verification methodology.



(iii) provide a faster state space exploration?
   ✔ Many experiments.
typical space reduction
states
explored
                                 no reduction
                                 strong reduction
                                 weak reduction




                                size of the
                                system
typical time reduction

runtime
                                   no reduction
                                   strong reduction
                                   weak reduction




                               size of the
                               system
will we have the same in Maude?




  Full symmetries in Maude [D.Rodriguez@WRLA'08]
will we have the same in Maude?


Q1. Overhead of meta-level based c-reductions?
Q2. Similar performance gains as model checkers?
Q3. Performance for c-reductions not based
     on full permutations (e.g. rotations)?
Q1. meta-level vs ad-hoc?
runtime
(seconds)
 90


 80
                                           meta-level
 70


 60


 50


 40


 30


 20                                        ad-hoc
 10


  0
      1   2     3   4   5   6   7      8

                                    size of the system
                                    (instance parameter)
Q2. Maude vs SymmSPIN?
relative time
reduction factor
     2
                                     no reduction
                                     symmSPIN
   1.5
                                     strong c-reduction
                                     weak c-reduction
     1



   0.5



     0
                                      size of the system
          2          3           4
                                      (instance parameter)
   -0.5



    -1
Q3. space reduction in dining philosophers?
Dining philosophers (rotational symmetries)




            ~              ~
                     = philosopher eating
                     = philosopher resting
Dining philosophers (msg. id's)

1      2          3         4           4   3


           ~
        msg id reuse            ~
                             msg id
                             permutation


                       ~
                       msg id abstraction
Q3. space reduction in dining philosophers
 states
                                     msg id reuse
 explored
        600000
                                     msg abstraction
                                     msg id reuse & permutations
                                     msg abstraction + philosopher rotation
        500000



        400000



        300000



        200000



        100000

                                                 size of the system
        0
    2            3   4   5   6   7   8       9   (instance parameter)
Q3. time reduction in dining philosophers
      states           msg reuse&permutation
                       msg abstraction
      explored         msg abstraction + philosopher rotation




  7              8                         9
                                    size of the system
                                    (instance parameter)
Q1. Overhead of meta-level based c-reductions?
  ✔ Significant improvement
           when not resorting to the meta-level.


Q2.Performance against model checkers?
  ✔ Similar in space reduction;
  ✔ Comparable time reduction.


Q3. Performance for c-reductions not based
         on full permutations (e.g. Rotations)?
  ✔ Significant space gains in rotational.
conclusion
Can we use rewriting logic to...


 (i) generalize symmetry reduction techniques?
   ✔ Define the c-reduction of a Kripke structure;

   ✔ C-reductions subsume typical symmetry reductions.



(ii) provide some advantages?
   ✔ Define c-reductions using equations (not in the engine);

   ✔ Provide a tool supported verification methodology.



(iii) provide a faster state space exploration?
   ✔ Many experiments.
Related work (Maude)

   Full symmetries in Maude [D.Rodriguez@WRLA'08]
    ✔ Full object permutations, meta-representation order;
    ✭ More symmetries and examples, no meta-representation order,
       verification methodology.


   Equational abstractions [Palomino et al.@JLAP'10]
    ✔ Identify states to reduce state space;
    ✭ Bisimulation, reduction application control.
Related work (ii)
   SymmSPIN et al. [Bosnacki et al.@SPIN'01]
    ✔ Heuristics for canonizers;
    ✭ No extension needed, object references allowed, formal checks;
   Groove [Rensink@GRABATS'06]
    ✔ Up-to-isomorphism GTS;
    ✭ Programmable reductions, not just iso.


   HD-automata [Montanari et al.@TCS'05]
    ✔ Name reuse techniques;
    ✭ On-the-fly reduction, algebraic state structure.
Current and Future Work
   Better integration in Maude
       Conciliate with other state space reduction techniques
        (equational abstractions, partial order reduction);
       Tool support and its integration in MFE.

   Beyond group theoretic symmetries
       Abstractions that yield bisimulations?
       Exploit axiomatisations of bisimulation for process algebras?

   Beyond bisimulation
       Weak bisimulation?
       Trace equivalence (for LTL)?
http://sysma.lab.imtlucca.it/tools/c-reducer/
thanks!
alberto.lluch@imtlucca.it
linkedin.com/in/albertolluch

Mais conteúdo relacionado

Destaque (6)

State space
State spaceState space
State space
 
State space models
State space modelsState space models
State space models
 
Lec2 state space
Lec2 state spaceLec2 state space
Lec2 state space
 
SDEE: Lecture 6
SDEE: Lecture 6SDEE: Lecture 6
SDEE: Lecture 6
 
State space analysis, eign values and eign vectors
State space analysis, eign values and eign vectorsState space analysis, eign values and eign vectors
State space analysis, eign values and eign vectors
 
Computational Motor Control: State Space Models for Motor Adaptation (JAIST s...
Computational Motor Control: State Space Models for Motor Adaptation (JAIST s...Computational Motor Control: State Space Models for Motor Adaptation (JAIST s...
Computational Motor Control: State Space Models for Motor Adaptation (JAIST s...
 

Semelhante a State Space c-Reductions of Concurrent Systems in Rewriting Logic @ ETAPS Workshop WRLA 2013

Linear algebra review
Linear algebra reviewLinear algebra review
Linear algebra reviewvevin1986
 
Lesson 21: Partial Derivatives in Economics
Lesson 21: Partial Derivatives in EconomicsLesson 21: Partial Derivatives in Economics
Lesson 21: Partial Derivatives in EconomicsMatthew Leingang
 
AA Section 2-1
AA Section 2-1AA Section 2-1
AA Section 2-1Jimbo Lamb
 
Lecture6
Lecture6Lecture6
Lecture6voracle
 
11X1 T12 09 locus problems
11X1 T12 09 locus problems11X1 T12 09 locus problems
11X1 T12 09 locus problemsNigel Simmons
 
Drools Expert and Fusion Intro : London 2012
Drools Expert and Fusion Intro  : London 2012Drools Expert and Fusion Intro  : London 2012
Drools Expert and Fusion Intro : London 2012Mark Proctor
 
Dunman High Emath Paper2_printed
Dunman High Emath Paper2_printedDunman High Emath Paper2_printed
Dunman High Emath Paper2_printedFelicia Shirui
 
The H.264 Integer Transform
The H.264 Integer TransformThe H.264 Integer Transform
The H.264 Integer TransformIain Richardson
 
Proofsummit2011a
Proofsummit2011aProofsummit2011a
Proofsummit2011atmiya
 

Semelhante a State Space c-Reductions of Concurrent Systems in Rewriting Logic @ ETAPS Workshop WRLA 2013 (13)

Linear algebra review
Linear algebra reviewLinear algebra review
Linear algebra review
 
Lesson 21: Partial Derivatives in Economics
Lesson 21: Partial Derivatives in EconomicsLesson 21: Partial Derivatives in Economics
Lesson 21: Partial Derivatives in Economics
 
AA Section 2-1
AA Section 2-1AA Section 2-1
AA Section 2-1
 
Lecture6
Lecture6Lecture6
Lecture6
 
11X1 T12 09 locus problems
11X1 T12 09 locus problems11X1 T12 09 locus problems
11X1 T12 09 locus problems
 
Drools Expert and Fusion Intro : London 2012
Drools Expert and Fusion Intro  : London 2012Drools Expert and Fusion Intro  : London 2012
Drools Expert and Fusion Intro : London 2012
 
Ef24836841
Ef24836841Ef24836841
Ef24836841
 
Dunman High Emath Paper2_printed
Dunman High Emath Paper2_printedDunman High Emath Paper2_printed
Dunman High Emath Paper2_printed
 
mmds
mmdsmmds
mmds
 
Eco558 1
Eco558 1Eco558 1
Eco558 1
 
The H.264 Integer Transform
The H.264 Integer TransformThe H.264 Integer Transform
The H.264 Integer Transform
 
Proofsummit2011a
Proofsummit2011aProofsummit2011a
Proofsummit2011a
 
Graddivcurl1
Graddivcurl1Graddivcurl1
Graddivcurl1
 

Mais de Alberto Lluch Lafuente

Many-to-Many Information Flow Policies
Many-to-Many Information Flow PoliciesMany-to-Many Information Flow Policies
Many-to-Many Information Flow PoliciesAlberto Lluch Lafuente
 
Aggregate Programming through a Soft Modal Logic
Aggregate Programming through a Soft Modal LogicAggregate Programming through a Soft Modal Logic
Aggregate Programming through a Soft Modal LogicAlberto Lluch Lafuente
 
Can we efficiently verify concurrent programs under relaxed memory models in ...
Can we efficiently verify concurrent programs under relaxed memory models in ...Can we efficiently verify concurrent programs under relaxed memory models in ...
Can we efficiently verify concurrent programs under relaxed memory models in ...Alberto Lluch Lafuente
 
Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...
Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...
Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...Alberto Lluch Lafuente
 
Adaptable Transition Systems @ ASCENS Meeting Prague 2013
Adaptable Transition Systems @ ASCENS Meeting Prague 2013Adaptable Transition Systems @ ASCENS Meeting Prague 2013
Adaptable Transition Systems @ ASCENS Meeting Prague 2013Alberto Lluch Lafuente
 
White Box Adaptation @ CINA Meeting 2013
White Box Adaptation @ CINA Meeting 2013White Box Adaptation @ CINA Meeting 2013
White Box Adaptation @ CINA Meeting 2013Alberto Lluch Lafuente
 
A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...
A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...
A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...Alberto Lluch Lafuente
 
A conceptual framework for behavioural adaptation @ Leicester 2011
A conceptual framework for behavioural adaptation @ Leicester 2011A conceptual framework for behavioural adaptation @ Leicester 2011
A conceptual framework for behavioural adaptation @ Leicester 2011Alberto Lluch Lafuente
 
Evaluating the performance of model transformation styles with Maude @ Sympos...
Evaluating the performance of model transformation styles with Maude @ Sympos...Evaluating the performance of model transformation styles with Maude @ Sympos...
Evaluating the performance of model transformation styles with Maude @ Sympos...Alberto Lluch Lafuente
 
A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011
A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011
A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011Alberto Lluch Lafuente
 
A Graph Syntax for Processes and Services @ Workshop WS-FM 2009
A Graph Syntax for Processes and Services @ Workshop WS-FM 2009A Graph Syntax for Processes and Services @ Workshop WS-FM 2009
A Graph Syntax for Processes and Services @ Workshop WS-FM 2009Alberto Lluch Lafuente
 

Mais de Alberto Lluch Lafuente (15)

Many-to-Many Information Flow Policies
Many-to-Many Information Flow PoliciesMany-to-Many Information Flow Policies
Many-to-Many Information Flow Policies
 
Aggregate Programming through a Soft Modal Logic
Aggregate Programming through a Soft Modal LogicAggregate Programming through a Soft Modal Logic
Aggregate Programming through a Soft Modal Logic
 
A Semiring-valued Temporal Logic
A Semiring-valued Temporal LogicA Semiring-valued Temporal Logic
A Semiring-valued Temporal Logic
 
Can we efficiently verify concurrent programs under relaxed memory models in ...
Can we efficiently verify concurrent programs under relaxed memory models in ...Can we efficiently verify concurrent programs under relaxed memory models in ...
Can we efficiently verify concurrent programs under relaxed memory models in ...
 
Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...
Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...
Collaborative Task Execution In Volunteer Clouds (or how to choose a sub-revi...
 
Adaptable Transition Systems @ ASCENS Meeting Prague 2013
Adaptable Transition Systems @ ASCENS Meeting Prague 2013Adaptable Transition Systems @ ASCENS Meeting Prague 2013
Adaptable Transition Systems @ ASCENS Meeting Prague 2013
 
White Box Adaptation @ CINA Meeting 2013
White Box Adaptation @ CINA Meeting 2013White Box Adaptation @ CINA Meeting 2013
White Box Adaptation @ CINA Meeting 2013
 
A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...
A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...
A White-box Perspective on Self-Adaptation and Self-Awareness (with a focus o...
 
A conceptual framework for behavioural adaptation @ Leicester 2011
A conceptual framework for behavioural adaptation @ Leicester 2011A conceptual framework for behavioural adaptation @ Leicester 2011
A conceptual framework for behavioural adaptation @ Leicester 2011
 
Evaluating the performance of model transformation styles with Maude @ Sympos...
Evaluating the performance of model transformation styles with Maude @ Sympos...Evaluating the performance of model transformation styles with Maude @ Sympos...
Evaluating the performance of model transformation styles with Maude @ Sympos...
 
A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011
A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011
A conceptual framework for behavioural adaptation @ Meeting ASCENS 2011
 
Maude .:° ASCENS 2011
Maude .:° ASCENS 2011Maude .:° ASCENS 2011
Maude .:° ASCENS 2011
 
IMT Welcome Day 2011
IMT Welcome Day 2011IMT Welcome Day 2011
IMT Welcome Day 2011
 
A Graph Syntax for Processes and Services @ Workshop WS-FM 2009
A Graph Syntax for Processes and Services @ Workshop WS-FM 2009A Graph Syntax for Processes and Services @ Workshop WS-FM 2009
A Graph Syntax for Processes and Services @ Workshop WS-FM 2009
 
An Algebra of Hierarchical Graphs
An Algebra of Hierarchical GraphsAn Algebra of Hierarchical Graphs
An Algebra of Hierarchical Graphs
 

Último

AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesZilliz
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfSeasiaInfotech2
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 

Último (20)

AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector Databases
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdf
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 

State Space c-Reductions of Concurrent Systems in Rewriting Logic @ ETAPS Workshop WRLA 2013

  • 1. State Space C-Reductions of Concurrent Systems in Rewriting Logic Alberto Lluch, Andrea Vandin José Meseguer IMT Lucca UIUC International Workshop on Rewriting Logic and its Applications (WRLA'12) Tallin, March 24-25, 2012
  • 2. state space explosion 0 3 8 ... 6 1 binary counter has ... 2 states 1 n-ary counter has ... n states (data abstraction) m n-ary counters Mn states! (symmetries, concurrency, etc.)
  • 3. running example $ = transfer of 1$ x$ = account with x$
  • 5. $ $ Isomorphic... Isomorphic... but syntactically different but syntactically different 0$ 0$ $ $ 1$ 0$ 0$ 1$ 1$ 1$
  • 6. symmetries in state space exploration problems
  • 7. some tools with symmetry reduction  Murphy [Ip&Dill@FMSD'96];  Symmetric SPIN [Bosnacki et al.@SPIN'00];  TopSPIN [Donaldson et al.@AMAST'06];  Groove [Rensink@GRABATS'06];  MiHDa [Montanari et al.@FMCO'02];  PRISM-symm [Ball et a@CAV06];  Planners, constraint solvers, etc.
  • 8. some drawbacks ✗ Symmetries denoted with extra primitives; ✗ Limited, fixed symmetry classes; ✗ Rigid “flexibility” vs “guarantees” tradeoff; ✗ Complex changes to model checker; ✗ Unofficial extensions of model checkers; ✗ No support for checking correctness.
  • 9. Can we use rewriting logic to... (i) generalize symmetry reduction techniques? ✔ Define the c-reduction of a Kripke structure; ✔ C-reductions subsume typical symmetry reductions. (ii) provide some advantages? ✔ Define c-reductions using equations (not in the engine); ✔ Provide a tool supported verification methodology. (iii) provide a faster state space exploration? ✔ Many experiments.
  • 10. Can we use rewriting logic to... (i) generalize symmetry reduction techniques? ✔ Define the c-reduction of a Kripke structure; ✔ C-reductions subsume typical symmetry reductions. (ii) provide some advantages? ✔ Define c-reductions using equations (not in the engine); ✔ Provide a tool supported verification methodology. (iii) provide a faster state space exploration? ✔ Many experiments.
  • 11. A Kripke structure is a tuple K = (S , → , L, AP) such that  S is a set of states;  → ⊆ S × S is a transition relation; $ $ p  AP are atomic propositions; 0$ 0$  L: S → 2AP maps states into AP subsets. $ p,q $ p,q 1$ 0$ 0$ 1$ p = there is some empty account q q = there are one or less dollars around 1$ 1$
  • 12. A bisimulation between two Kripke structures K and H is a binary relation ∼ ⊆ SK × SH such that s∼s' implies  LK(s) = LH(s');  s →K r implies s' →H r' and r∼r' for some r'; s →K r ≀ ≀  vice versa. s' →H r' p p $ $ $ $ 0$ 0$ 0$ 0$ p,q $ $ p,q $ p,q 1$ 0$ 0$ 1$ 0$ 1$ q q 1$ 1$ 1$ 1$
  • 13. A ∼-canonizer for – a Kripke structure K – and an equivalence (bisimilation) relation ∼ ⊆ S × S is a function c : S → S such that s∼c(s) for all states s. c $ c $ 1$ 0$ 0$ 1$
  • 14. A ∼-canonizer is strong if s∼s' implies c(s) = c(s') (i.e. if canonical representatives of ∼-equivalence classes are unique) 2$ 1$ 3$ 2$ 1$ 3$ 1$ 3$ 2$ c c 1$ 3$ 2$ c c c 1$ 2$ 3$ 1$ 2$ 3$ 2$ 3$ 1$ 2$ 3$ 1$ c 3$ 1$ 2$ c 3$ 1$ 2$ c 3$ 2$ 1$ 3$ 2$ 1$ otherwise we call them weak.
  • 15. The c-reduction of a Kripke structure K = (S , → , L, AP) $ $ is Kc = (S , →;c , L, AP) 0$ 0$ $ $ 1$ 0$ c 0$ 1$ 1$ 1$
  • 16. Th. If c is a ∼-canonizer then Kc ∼ K.
  • 17. Can we use rewriting logic to... (i) generalize symmetry reduction techniques? ✔ Define the c-reduction of a Kripke structure; ✔ C-reductions subsume typical symmetry reductions. (ii) provide some advantages? ✔ Define c-reductions using equations (not in the engine); ✔ Provide a tool supported verification methodology. (iii) provide a faster state space exploration? ✔ Many experiments.
  • 18. some symmetry reductions captured  Full symmetries;  Rotational symmetries;  Name reuse (garbage collection);  Name abstraction.
  • 19. Can we use rewriting logic to... (i) generalize symmetry reduction techniques? ✔ Define the c-reduction of a Kripke structure; ✔ C-reductions subsume typical symmetry reductions. (ii) provide some advantages? ✔ Define c-reductions using equations (not in the engine); ✔ Provide a tool supported verification methodology. (iii) provide a faster state space exploration? ✔ Many experiments.
  • 20. What is RL? A rewrite theory R is a tuple (Σ , E ∪ A , R , ϕ)  Σ = signature (e.g. syntax);  E = equations (e.g. functions); Not all equivalence relations ∼ Not all equivalence relations ∼ are tractable as axioms  A = axioms (e.g. ACI); are tractable as axioms  R = rules (e.g. non deterministic behaviour);  ϕ = frozennes map (e.g. rewrite strategy). Some assumptions:  R has good executability properties;  Topmost rules for a designated [State] kind.
  • 21. --- The main module defining the signature and one initial state fmod BANK is ... sorts Object Message Configuration State . subsort Message Object < Configuration . op <_|_> : Nat Nat -> Object [ctor] . op credit : Nat -> Message [ctor] . op __ : Configuration Configuration -> Configuration [ctor assoc comm] . op none : -> Configuration [ctor] . op {_} : Configuration -> State [ctor frozen] . --- A simple initial state $ $ op init : -> Configuration . 0$ 0$ eq init = < 0 | 0 > < 1 | 0 > credit(0) credit(1) . endfm
  • 22. --- The behavioural rules of the example mod BANK-RULES is $ inc BANK . vars i x : Nat . x$ x+1$ vars c1 : Configuration . --- A simple rule for crediting an account rl [credit] : { < i | x > credit(i) c1 } => { < i | s(x) > c1 } . endm
  • 23. search without reduction $ $ 0$ 0$ Maude> search in BANK-RULES : {init} =>* s:State . $ $ Solution 1 (state 0) 1$ 0$ 0$ 1$ s:State --> {credit(0) credit(1) < 0 | 0 > < 1 | 0 >} Solution 2 (state 1) 1$ 1$ s:State --> {credit(1) < 0 | 1 > < 1 | 0 >} symmetric states Solution 3 (state 2) s:State --> {credit(0) < 0 | 0 > < 1 | 1 >} Solution 4 (state 3) s:State --> {< 0 | 1 > < 1 | 1 >} No more solutions. states: 4 rewrites: 6 in 0ms cpu (2ms real) (9523 rewrites/second)
  • 24. c-extension The c-extension of a rewrite theory R = (Σ, E ∪ A , R, ϕ) is Rc = (Σ ⊎ Σc, E ∪ Gc ∪ A , R , ϕc) i.e. a correct extension of R with the definition of c.
  • 25. module architecture BANK BANK-RULES (R) BANK-C (Rc)
  • 26. c-extension (example of canonizer) --- The c-extension of BANK that defines the c-canonizer for object permutations mod BANK-C is ... op c : State -> [State] . vars i j x y : Nat . vars c1 : Configuration . ceq c( { < i | x > < j | y > c1 } ) = c( { [[ i <-> j ]]( < i | x > < j | y > c1 ) } ) if [[ i <-> j ]]( < i | x > < j | y > c1 ) <# < i | x > < j | y > c1 . eq c({c1}) = {c1} [ owise ] . endm
  • 27. module architecture BANK BANK-RULES (R) BANK-PERMUTATION BANK-C (Rc)
  • 28. c-extension (example of transpositions) --- Implementation of object permutations fmod BANK-PERMUTATION is ... op [[_<->_]] _ : Nat Nat Configuration -> Configuration [frozen] . op [[_<->_]] _ : Nat Nat Nat -> Nat . eq [[ i <-> j ]](none) = none . eq [[ i <-> j ]](obj1 c1) = ([[ i <-> j ]](obj1)) ([[ i <-> j ]](c1)) . eq [[ i <-> j ]](msg1 c1) = ([[ i <-> j ]](msg1)) ([[ i <-> j ]](c1)) . eq [[ i <-> j ]](< k | x >) = < [[ i <-> j ]](k) | x > . eq [[ i <-> j ]](credit(k)) = credit([[ i <-> j ]] k) .  eq [[ i <-> j ]](i) = j . eq [[ i <-> j ]](j) = i . ceq [[ i <-> j ]](k) = k if (i != k) / (j != k) . endfm
  • 29. Identification of symmetric states Maude> red c( {credit(0) < 0 | 0 > < 1 | 1 >}) . result State: {credit(1) < 0 | 1 > < 1 | 0 >} $ 0$ 1$ c $ 1$ 0$
  • 30. The c-reduction of a rewrite theory R = (Σ, E ∪ A , R , ϕ ) is Rc = (Σ ⊎ Σc, E ∪ Gc ∪ A , Rc , ϕc) cc where Rc is made of rules K(Rcc)= K (R) K(R ) = K (R) l => c(r) if cond for each rule of R l => r if cond
  • 31. module architecture BANK BANK-RULES (R) BANK-PERMUTATION BANK-C (Rc) BANK-C-REDUCTION (Rc)
  • 32. c-reduction (example) --- The c-reduction of BANK-RULES mod BANK-C-REDUCTION is inc BANK-C . rl [credit] : { < i | x > credit(i) c1 } => c({ < i | s(x) > c1 }) . endm
  • 33. search in c-reduced state space Maude> search in BANK-C-REDUCTION : {init} =>* s:State . search in BANK-C-REDUCTION : {init} =>* s:State . $ $ Solution 1 (state 0) 0$ 0$ s:State --> {credit(0) credit(1) < 0 | 0 > < 1 | 0 >} $ $ Solution 2 (state 1) c s:State --> {credit(1) < 0 | 1 > < 1 | 0 >} 1$ 0$ 0$ 1$ Solution 3 (state 2) s:State --> {< 0 | 1 > < 1 | 1 >} 1$ 1$ No more solutions. states: 3 rewrites: 25 in 0ms cpu (2ms real) (53648 rewrites/second)
  • 34. Can we use rewriting logic to... (i) generalize symmetry reduction techniques? ✔ Define the c-reduction of a Kripke structure; ✔ C-reductions subsume typical symmetry reductions. (ii) provide some advantages? ✔ Define c-reductions using equations (not in the engine); ✔ Provide a tool supported verification methodology. (iii) provide a faster state space exploration? ✔ Many experiments.
  • 35. Does c provide a correct c-reduction? Th 1. “K(Rc) is bisimilar to K(R)” (desiderata) Lemma 0. “Relation ∼ is an equivalence relation” (i) Check that the action of the group is correct. Lemma 1. “Relation∼ is a bisimulation” Proof plan for (ii) Check that ∼ strongly respects AP; group-theoretic (iii) Check that ∼ and R “commute”. reductions Lemma 2. “Function c is a ∼-canonizer” (iv) Check that c is a ∼-canonizer.
  • 36. modules and checks BANK check (i) BANK-RULES (R) BANK-AP BANK-PERMUTATION (R∼) check (iv) check (iii) check (ii) BANK-C (Rc) BANK-PERMUTATION-RULES (R∼) BANK-C-REDUCTION (Rc)
  • 37. group theoretic equivalence relations The action ⟦∙⟧ of a group G on S defines an equivalence relation: s∼s' iff ⟦ f ⟧(s) = s' for some f ∈ G.
  • 38. modules and checks BANK check (i) BANK-RULES (R) BANK-AP BANK-PERMUTATION (R∼) BANK-C (Rc) BANK-PERMUTATION-RULES (R∼) BANK-C-REDUCTION (Rc)
  • 39. (i) Checking group actions Implement the action ⟦∙⟧ of G on S as [[_]]_ : G State ->State . … but we just need to implement the action of the generators. Check that the we actually have a group action by showing: ⟦g⟧⟦g-1⟧(s) = s for each generator g of G. HINT: induction on S (structure of states). For example, in the case of permutations one has to show [[ i <-> j]] ([[ i <-> j]] (s)) = s
  • 40. (i) Checking group actions Implement the action ⟦∙⟧ of G on S as [[_]]_ : G State ->State . … but we just need to implement the action of the generators. Check that the we actually have a group action by showing:  ⟦e⟧(s) = s, for e the identity of G;  ⟦g ∘ g'⟧(s) = ⟦g⟧(⟦g'⟧(s)) for each pair of generators g, g' of G;  ⟦g⟧⟦g-1⟧(s) = s for each generator g of G. HINT: induction on G (generators ) and S (structure of states).
  • 41. modules and checks BANK BANK-RULES (R) BANK-AP BANK-PERMUTATION (R∼) check (ii) BANK-C (Rc) BANK-PERMUTATION-RULES (R∼) BANK-C-REDUCTION (Rc)
  • 42. (ii) Checking that ∼ strongly preserves AP IDEA: Define a rewrite theory R∼ to “move” inside orbits: R∼ = (Σ ⊎ Σ∼, E ∪ E∼ ∪ A , R∼ , ϕ) where R∼ = { s => [[g]](s) } Theorem: ∼ strongly preserves AP if AP is stable in R∼.
  • 43. Can we check such stability automatically? Yes, with InvA (under some conditions) fmod BANK-AP is eq [two-dollars-eq] : two-dollars({ < i | s(s(x)) > c1 }) = true . endfm fmod BANK-PERMUTATION-RULES is rl [transposition] : { < i | x > < j | y > c1 } => { [[ i <-> j ]] ( < i | x > < j | y > c1) } . endm Maude> (analyze-stable two-dollars(s:State) in BANK-AP BANK-PERMUTATION-RULES .) rewrites: 15571 in 16ms cpu (19ms real) (918643 rewrites/second) Checking BANK-PERMUTATION-RULES ||- two-dollars => O two-dollars ... Proof obligations generated: 2 For non discharged proof obligations Proof obligations discharged: 2 For non discharged proof obligations Success! one can use the Maude ITP tool one can use the Maude ITP tool
  • 44. modules and checks BANK BANK-RULES (R) BANK-AP BANK-PERMUTATION (R∼) check (iii) BANK-C (Rc) BANK-PERMUTATION-RULES (R∼) BANK-C-REDUCTION (Rc)
  • 45. (iii) Checking that ∼ and R commute R u v R u' v' For all equivalent states u, u' and for all R-transitions from u to v.
  • 46. (iii) Checking that ∼ and R commute R u v R∼ R∼ * R * u' v' For all R∼reachable pairs of states u->u' and for all R-transitions from u to v.
  • 47. (iii) Checking that ∼ and R commute R u v R∼ R∼ R * u1' v1' R∼ R∼ R * u2' v2' R u' v' For all R∼-transitions u->u' and for all R-transitions from u to v.
  • 48. Consider:  Each R-rules from l => r  Each R∼-rules l' => r' R θ'(l') ≡A θ(l) θ(r) R∼ R∼ R * θ'(r') w
  • 49. (iii) Checking that ∼ and R commute R For all R∼-transitions u → u' and u v R∼ for all R-transitions from u to v. R∼ * R u' v' R θ(l) θ(r) For all R∼-rules l' => r' and for all R-rules from l => r. R∼ R∼ Similar functionalities (e.g. critical pair generation) Similar functionalities (e.g. critical pair generation) are already available in some Maude tools R * are already available in some Maude tools θ'(r') v' (e.g. in the Coherence Checker). (e.g. in the Coherence Checker).
  • 50. (iii) Checking that ∼ and R commute IDEA: Show joinability of critical pairs (R rules vs R∼) Theorem: If all such pairs are joinable, ∼ is a bisimulation
  • 51. modules and checks BANK BANK-RULES (R) BANK-AP BANK-PERMUTATION (R∼) check (iv) BANK-C (Rc) BANK-PERMUTATION-RULES (R∼) BANK-C-REDUCTION (Rc)
  • 52. (iv) checking that c is a ∼-canonizer IDEA: Exploit the form of typical reduction strategies: Local strategies c({t}) = c([[g]]({t})) if [[g]]({t})<{t} c({t}) = {t} [owise] Enumeration strategies c({t}) = min{[[f]]({t})}
  • 53. Can we use rewriting logic to... (i) generalize symmetry reduction techniques? ✔ Define the c-reduction of a Kripke structure; ✔ C-reductions subsume typical symmetry reductions. (ii) provide some advantages? ✔ Define c-reductions using equations (not in the engine); ✔ Provide a tool supported verification methodology. (iii) provide a faster state space exploration? ✔ Many experiments.
  • 54. typical space reduction states explored no reduction strong reduction weak reduction size of the system
  • 55. typical time reduction runtime no reduction strong reduction weak reduction size of the system
  • 56. will we have the same in Maude? Full symmetries in Maude [D.Rodriguez@WRLA'08]
  • 57. will we have the same in Maude? Q1. Overhead of meta-level based c-reductions? Q2. Similar performance gains as model checkers? Q3. Performance for c-reductions not based on full permutations (e.g. rotations)?
  • 58. Q1. meta-level vs ad-hoc? runtime (seconds) 90 80 meta-level 70 60 50 40 30 20 ad-hoc 10 0 1 2 3 4 5 6 7 8 size of the system (instance parameter)
  • 59.
  • 60. Q2. Maude vs SymmSPIN? relative time reduction factor 2 no reduction symmSPIN 1.5 strong c-reduction weak c-reduction 1 0.5 0 size of the system 2 3 4 (instance parameter) -0.5 -1
  • 61. Q3. space reduction in dining philosophers?
  • 62. Dining philosophers (rotational symmetries) ~ ~ = philosopher eating = philosopher resting
  • 63. Dining philosophers (msg. id's) 1 2 3 4 4 3 ~ msg id reuse ~ msg id permutation ~ msg id abstraction
  • 64. Q3. space reduction in dining philosophers states msg id reuse explored 600000 msg abstraction msg id reuse & permutations msg abstraction + philosopher rotation 500000 400000 300000 200000 100000 size of the system 0 2 3 4 5 6 7 8 9 (instance parameter)
  • 65. Q3. time reduction in dining philosophers states msg reuse&permutation msg abstraction explored msg abstraction + philosopher rotation 7 8 9 size of the system (instance parameter)
  • 66. Q1. Overhead of meta-level based c-reductions? ✔ Significant improvement when not resorting to the meta-level. Q2.Performance against model checkers? ✔ Similar in space reduction; ✔ Comparable time reduction. Q3. Performance for c-reductions not based on full permutations (e.g. Rotations)? ✔ Significant space gains in rotational.
  • 68. Can we use rewriting logic to... (i) generalize symmetry reduction techniques? ✔ Define the c-reduction of a Kripke structure; ✔ C-reductions subsume typical symmetry reductions. (ii) provide some advantages? ✔ Define c-reductions using equations (not in the engine); ✔ Provide a tool supported verification methodology. (iii) provide a faster state space exploration? ✔ Many experiments.
  • 69. Related work (Maude)  Full symmetries in Maude [D.Rodriguez@WRLA'08] ✔ Full object permutations, meta-representation order; ✭ More symmetries and examples, no meta-representation order, verification methodology.  Equational abstractions [Palomino et al.@JLAP'10] ✔ Identify states to reduce state space; ✭ Bisimulation, reduction application control.
  • 70. Related work (ii)  SymmSPIN et al. [Bosnacki et al.@SPIN'01] ✔ Heuristics for canonizers; ✭ No extension needed, object references allowed, formal checks;  Groove [Rensink@GRABATS'06] ✔ Up-to-isomorphism GTS; ✭ Programmable reductions, not just iso.  HD-automata [Montanari et al.@TCS'05] ✔ Name reuse techniques; ✭ On-the-fly reduction, algebraic state structure.
  • 71. Current and Future Work  Better integration in Maude  Conciliate with other state space reduction techniques (equational abstractions, partial order reduction);  Tool support and its integration in MFE.  Beyond group theoretic symmetries  Abstractions that yield bisimulations?  Exploit axiomatisations of bisimulation for process algebras?  Beyond bisimulation  Weak bisimulation?  Trace equivalence (for LTL)?