probabilities in higher order languages
play

Probabilities in Higher-Order Languages Valeria Vignudelli - PowerPoint PPT Presentation

Probabilities in Higher-Order Languages Valeria Vignudelli University of Bologna/Inria FOCUS (Joint work with Marco Bernardo, University of Urbino and Davide Sangiorgi, University of Bologna/Inria FOCUS) June 21, 2014 Vignudelli


  1. Probabilities in Higher-Order Languages Valeria Vignudelli University of Bologna/Inria FOCUS (Joint work with Marco Bernardo, University of Urbino and Davide Sangiorgi, University of Bologna/Inria FOCUS) June 21, 2014 Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 1 / 24

  2. Higher-order languages Variables may be instantiated with terms of the language itself (e.g. terms can be copied) functions ( λ -calculus) → M { N / ( λ x . M ) N − x } higher-order communication (Higher-Order π -calculus) → M { N / a ( x ) . M | a � N � . R − x } | R action on locations (kells), as with passivation → N { M / [ [ M ] ] l | pass l ( x ) . N − x } M is a running term [Schmitt,Stefani GC’04, Lenglet et al. Inf.Comp.’11, Pi´ erard,Sumii FOSSACS’12, Koutavas,Hennessy CONCUR’13] Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 2 / 24

  3. Probabilistic processes nondeterministic (LTSs) Vs. reactive probabilistic (RPLTSs) P P a a a ∆ 1 2 • • 3 3 b d b • • b d • • • b • • • c c • • external & internal nondeterminism only external nondeterminism [Larsen,Skou POPL’89, van Breugel et al. Theor.Comp.Sci.’05] Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 3 / 24

  4. A contextual/testing approach Discriminating power of higher-order languages and interplay between probabilities, concurrency, higher-order operators Plan of the talk 1 main ingredients 2 results in the nondeterministic setting 3 results in the probabilistic setting [Bernardo,Sangiorgi,Vignudelli CSL-LICS’14] Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 4 / 24

  5. The discriminating power of a language A testing language L , a set of tested terms P , Q . . . � P ≃ L Q C [ P ] and C [ Q ] ‘equally successful’ , ∀ contexts C of L Otherwise: P , Q are discriminated by L Two classes of first-order (CCS-like) processes as tested terms P , Q : nondeterministic reactive probabilistic Comparison of testing languages L with different constructs: sequential higher-order ( λ -calculus) higher-order communication (HO π ) ordinary first-order concurrency (CCS) passivation no probabilities in L refusal Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 5 / 24

  6. Higher-order sequential languages: Kell λ -calculus ( K Λ) M is evaluated in kell N (of process type) → � N ′ ; M ′ � � N ; M � − Contexts interact with the kell by: testing actions → � P ′ ; true � a → P ′ � P ; a ? � − if P − � a � P ; a ? � − → � P ; false � if P − → reading (passivating) and rewriting the kell � P ; � P ′ ; M �� − → � P ′ ; M � � P ; pass � − → � P ; P � Variants: - call by name ( K Λ N ) and call by value ( K Λ V ) - refusal free ( K Λ N − ref , K Λ V − ref ) Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 6 / 24

  7. Concurrent languages Interactions between context and process: action synchronization (CCS) P ′ | M a → P ′ P | a . M − → if P − higher-order communication (HO π ) → M { P / a ( x ) . M | a � P � . N − x } | N refusal on kells (CCS ref , HO π ref ) � a [ [ P ] ] l | � a l . M − → [ [ P ] ] l | M if P − → passivation of kells (HO π pass , HO π pass , ref ) → M { P / [ [ P ] ] l | pass l ( x ) . M − x } Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 7 / 24

  8. Testing nondeterministic processes Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 8 / 24

  9. ‘Success’ on nondeterministic processes � P ≃ L Q C [ P ] and C [ Q ] ‘equally successful’ , ∀ contexts C of L C [ P ] P is an LTS, C [ P ] ⇓ • • Success states • are: ω − → in CCS , HO π M • • • � N ; true � in K Λ • Success is ⇓ ( = a success state • is reachable) [may success] Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 9 / 24

  10. The Spectrum on LTSs ready simulation equivalence K Λ V = HO π ref , pass simulation equivalence failure trace equivalence K Λ V − ref = HO π pass K Λ N = HO π ref = CCS ref K Λ N − ref = HO π = CCS trace equivalence CBV = passivation in HO π sequential = concurrent first-order communication = higher-order communication Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 10 / 24

  11. Call By Name & Call By Value P does a a T a � a ? � P ; a ? � ⇓ − → iff P P refuses a � a T ¬ a � if a ? then false else true � P ; T ¬ a � ⇓ iff P − → P passes T 1 and T 2 in sequence ⇒� P ′ ; true � ∧ � P ′ ; T 2 �⇓ � P ; Seq ( λ. T 1 )( λ. T 2 ) �⇓ iff � P ; T 1 � = � for Seq λ x .λ y . if x ⋆ then y ⋆ else false λ. M thunking M ⋆ unthunking Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 11 / 24

  12. Example: discriminating LTSs Q P a a a P 1 P 2 Q 1 b c b b c P 3 P 4 P 5 Q 2 Q 3 C [ P ] ⇓ C [ Q ] �⇓ C = � · ; Seq T a T ¬ c � completed trace/simulation equivalent but not failure equivalent processes [see van Glabbeek ’90 spectrum] Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 12 / 24

  13. Call By Value P passes both T 1 and T 2 � P ; And ( λ. T 1 )( λ. T 2 ) � ⇓ iff � P ; T 1 � ⇓ ∧ � P ; T 2 � ⇓ � for λ x .λ y . (( λ z . if x ⋆ then � z ; y ⋆ � else false) pass ) And a b C [ P ] ⇓ iff P − → ∧ P − → � P ; ( λ x . if a ? then � x ; b ? � else false) pass � − → � P ; ( λ x . if a ? then � x ; b ? � else false) P � − → � P ; if a ? then � P ; b ? � else false � → � P ′ ; if true then � P ; b ? � else false � − → � P ′ ; � P ; b ? �� − − → � P ; b ? � ⇓ Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 13 / 24

  14. Call By Value P passes both T 1 and T 2 � P ; And ( λ. T 1 )( λ. T 2 ) � ⇓ iff � P ; T 1 � ⇓ ∧ � P ; T 2 � ⇓ � for λ x .λ y . (( λ z . if x ⋆ then � z ; y ⋆ � else false) pass ) And a b C [ P ] ⇓ iff P − → ∧ P − → � P ; ( λ x . if a ? then � x ; b ? � else false) pass � − → � P ; ( λ x . if a ? then � x ; b ? � else false) P � − → � P ; if a ? then � P ; b ? � else false � → � P ′ ; if true then � P ; b ? � else false � − → � P ′ ; � P ; b ? �� − − → � P ; b ? � ⇓ Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 13 / 24

  15. Call By Value P passes both T 1 and T 2 � P ; And ( λ. T 1 )( λ. T 2 ) � ⇓ iff � P ; T 1 � ⇓ ∧ � P ; T 2 � ⇓ � for λ x .λ y . (( λ z . if x ⋆ then � z ; y ⋆ � else false) pass ) And a b C [ P ] ⇓ iff P − → ∧ P − → � P ; ( λ x . if a ? then � x ; b ? � else false) pass � − → � P ; ( λ x . if a ? then � x ; b ? � else false) P � − → � P ; if a ? then � P ; b ? � else false � → � P ′ ; if true then � P ; b ? � else false � − → � P ′ ; � P ; b ? �� − − → � P ; b ? � ⇓ Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 13 / 24

  16. Call By Value P passes both T 1 and T 2 � P ; And ( λ. T 1 )( λ. T 2 ) � ⇓ iff � P ; T 1 � ⇓ ∧ � P ; T 2 � ⇓ � for λ x .λ y . (( λ z . if x ⋆ then � z ; y ⋆ � else false) pass ) And a b C [ P ] ⇓ iff P − → ∧ P − → � P ; ( λ x . if a ? then � x ; b ? � else false) pass � − → � P ; ( λ x . if a ? then � x ; b ? � else false) P � − → � P ; if a ? then � P ; b ? � else false � → � P ′ ; if true then � P ; b ? � else false � − → � P ′ ; � P ; b ? �� − − → � P ; b ? � ⇓ Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 13 / 24

  17. Call By Value P passes both T 1 and T 2 � P ; And ( λ. T 1 )( λ. T 2 ) � ⇓ iff � P ; T 1 � ⇓ ∧ � P ; T 2 � ⇓ � for λ x .λ y . (( λ z . if x ⋆ then � z ; y ⋆ � else false) pass ) And a b C [ P ] ⇓ iff P − → ∧ P − → � P ; ( λ x . if a ? then � x ; b ? � else false) pass � − → � P ; ( λ x . if a ? then � x ; b ? � else false) P � − → � P ; if a ? then � P ; b ? � else false � → � P ′ ; if true then � P ; b ? � else false � − → � P ′ ; � P ; b ? �� − − → � P ; b ? � ⇓ Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 13 / 24

  18. Call By Value P passes both T 1 and T 2 � P ; And ( λ. T 1 )( λ. T 2 ) � ⇓ iff � P ; T 1 � ⇓ ∧ � P ; T 2 � ⇓ � for λ x .λ y . (( λ z . if x ⋆ then � z ; y ⋆ � else false) pass ) And a b C [ P ] ⇓ iff P − → ∧ P − → � P ; ( λ x . if a ? then � x ; b ? � else false) pass � − → � P ; ( λ x . if a ? then � x ; b ? � else false) P � − → � P ; if a ? then � P ; b ? � else false � → � P ′ ; if true then � P ; b ? � else false � − → � P ′ ; � P ; b ? �� − − → � P ; b ? � ⇓ Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 13 / 24

  19. Example: discriminating LTSs Q P a a a P 1 P 2 Q 1 b b b b P 3 P 4 Q 2 Q 3 c c d d P 5 P 6 Q 4 Q 5 C [ P ] �⇓ C [ Q ] ⇓ C = � · ; Seq T a ( And ( Seq T b T c )( Seq T b T d )) � ready trace equivalent but not simulation equivalent processes Vignudelli (Bologna-Inria) Probabilities in H-O June 21, 2014 14 / 24

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend