Upload
dinhtram
View
216
Download
0
Embed Size (px)
Citation preview
Semantics of Probabilistic Processes
Yuxin Deng
Semantics of ProbabilisticProcesses
An Operational Approach
2123
Yuxin DengShanghai Jiao Tong UniversityShanghaiChina
ISBN 978-3-662-45197-7 ISBN 978-3-662-45198-4 (eBook)DOI 10.1007/978-3-662-45198-4
Jointly published with Shanghai Jiao Tong University Press
ISBN: 978-7-313-12083-0 Shanghai Jiao Tong University Press
Library of Congress Control Number: 2014957854
Springer Heidelberg New York Dordrecht London© Shanghai Jiao Tong University Press, Shanghai and Springer-Verlag Berlin Heidelberg 2014This work is subject to copyright. All rights are reserved by the Publishers, whether the whole or part ofthe material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation,broadcasting, reproduction on microfilms or in any other physical way, and transmission or informationstorage and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodologynow known or hereafter developed.The use of general descriptive names, registered names, trademarks, service marks, etc. in this publicationdoes not imply, even in the absence of a specific statement, that such names are exempt from the relevantprotective laws and regulations and therefore free for general use.The publishers, the authors and the editors are safe to assume that the advice and information in this bookare believed to be true and accurate at the date of publication. Neither the publishers nor the authors orthe editors give a warranty, express or implied, with respect to the material contained herein or for anyerrors or omissions that may have been made.
Printed on acid-free paper
Springer is part of Springer Science + Business Media (www.springer.com)
Preface
Probabilistic concurrency theory aims to specify and analyse quantitative behaviourof concurrent systems, which necessarily builds on solid semantic foundations ofprobabilistic processes. This book adopts an operational approach to describing thebehaviour of nondeterministic and probabilistic processes, and that the semanticcomparison of different systems are based on appropriate behavioural relations suchas bisimulation equivalence and testing preorders.
It mainly consists of two parts. The first part provides an elementary account ofbisimulation semantics for probabilistic processes from metric, logical and algorith-mic perspectives. The second part sets up a general testing framework and specialisesit to probabilistic processes with nondeterministic behaviour. The resulting testingsemantics is treated in depth. A few variants of it are shown to coincide, and theycan be characterised in terms of modal logics and coinductively defined simulationrelations. Although in the traditional (nonprobabilistic) setting, simulation semanticsis in general finer than testing semantics because it distinguishes more processes fora large class of probabilistic processes, the gap between simulation and testing se-mantics disappears. Therefore, in this case, we have a semantics where both negativeand positive results can be easily proved: to show that two processes are not relatedin the semantics, we just give a witness test, and to prove that two processes arerelated, we only need to establish a simulation relation.
While most of the results have been announced before, they are spread over severalpapers in the period from 2007 to 2014, and sometimes with different terminologyand notation. This prevents us from having a comprehensive understanding of thebisimulation and testing semantics of probabilistic processes. In order to improvethe situation, the current work brings all the related concepts and proof techniquesto form a coherent and self-contained text.
Besides presenting the recent research advances in probabilistic concurrency the-ory, the book exemplifies the use of many mathematical techniques to solve problemsin Computer Science, which is intended to be accessible to postgraduate students inComputer Science and Mathematics. It can also be used by researchers and practi-tioners either for advanced study or for technical reference. The reader is assumed tohave some basic knowledge in discrete mathematics. Familiarity with real analysisis not a prerequisite, but would be helpful.
v
vi Preface
Most of the work reported in this book was carried out during the last few yearswith a number of colleagues. The testing semantics for probabilistic processes wasdeveloped in conjunction with Rob van Glabbeek, Matthew Hennessy, Carroll Mor-gan and Chenyi Zhang. The various characterisations of probabilistic bisimulationin Chap. 3 are based on joint work with Wenjie Du.
The BASICS laboratory at Shanghai Jiao Tong University has offered a creativeand pleasant working atmosphere. Therefore, I would like to express my gratitude toYuxi Fu and all other members of the laboratory. Thanks go also to Barry Jay, MatthewHennessy and Carroll Morgan for having read parts of the first draft and provideduseful feedback. My research on probabilistic concurrency theory has been sponsoredby the National Natural Science Foundation of China under grants 61173033 and61261130589, as well as ANR 12IS02001 “PACE”.
Finally, my special gratitude goes to my family, for their unfailing support.
Shanghai Yuxin DengSeptember, 2014
Contents
1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.1 Background . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.2 Synopsis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
2 Mathematical Preliminaries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72.1 Lattice Theory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72.2 Induction and Coinduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102.3 Topological Spaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132.4 Metric Spaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152.5 Probability Spaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182.6 Linear Programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
3 Probabilistic Bisimulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233.2 Probabilistic Labelled Transition Systems . . . . . . . . . . . . . . . . . . . . . . 253.3 Lifting Relations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273.4 Justifying the Lifting Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
3.4.1 Justification by the Kantorovich Metric . . . . . . . . . . . . . . . . . . 323.4.2 Justification by Network Flow . . . . . . . . . . . . . . . . . . . . . . . . . . 38
3.5 Probabilistic Bisimulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 423.6 Logical Characterisation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
3.6.1 An Adequate Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 453.6.2 An Expressive Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
3.7 Metric Characterisation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 523.8 Algorithmic Characterisation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
3.8.1 A Partition Refinement Algorithm . . . . . . . . . . . . . . . . . . . . . . 563.8.2 An “On-the-Fly” Algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
3.9 Bibliographic Notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
vii
viii Contents
3.9.1 Probabilistic Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 633.9.2 Probabilistic Bisimulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
4 Probabilistic Testing Semantics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 714.1 A General Testing Framework . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 714.2 Testing Probabilistic Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 734.3 Bounded Continuity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 774.4 Reward Testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
4.4.1 A Geometric Property . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 814.4.2 Nonnegative Rewards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
4.5 Extremal Reward Testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 854.6 Extremal Reward Testing Versus Resolution-Based Reward Testing . 88
4.6.1 Must Testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 894.6.2 May Testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
4.7 Vector-Based Testing Versus Scalar Testing . . . . . . . . . . . . . . . . . . . . . 974.8 Bibliographic Notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
5 Testing Finite Probabilistic Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1035.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1035.2 The Language pCSP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
5.2.1 The Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1055.2.2 The Operational Semantics . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1065.2.3 The Precedence of Probabilistic Choice . . . . . . . . . . . . . . . . . . 1085.2.4 Graphical representation of pCSP processes . . . . . . . . . . . . . . 1085.2.5 Testing pCSP Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109
5.3 Counterexamples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1125.4 Must Versus May Testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1165.5 Forward and Failure Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118
5.5.1 The Simulation Preorders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1205.5.2 The Simulation Preorders are Precongruences . . . . . . . . . . . . 1255.5.3 Simulations Are Sound for Testing Preorders . . . . . . . . . . . . . 127
5.6 A Modal Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1335.7 Characteristic Tests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1355.8 Equational Theories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1375.9 Inequational Theories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1385.10 Completeness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1405.11 Bibliographic Notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
5.11.1 Probabilistic Equivalences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1445.11.2 Probabilistic Simulations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146
Contents ix
6 Testing Finitary Probabilistic Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . 1496.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1496.2 The Language rpCSP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1526.3 A General Definition of Weak Derivations . . . . . . . . . . . . . . . . . . . . . . 153
6.3.1 Lifting Relations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1546.3.2 Weak Transitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1596.3.3 Properties of Weak Transitions . . . . . . . . . . . . . . . . . . . . . . . . . 162
6.4 Testing rpCSP Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1676.4.1 Testing with Extremal Derivatives . . . . . . . . . . . . . . . . . . . . . . 1686.4.2 Comparison with Resolution-Based Testing . . . . . . . . . . . . . . 172
6.5 Generating Weak Derivatives in a Finitary pLTS . . . . . . . . . . . . . . . . . 1756.5.1 Finite Generability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1766.5.2 Realising Payoffs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1816.5.3 Consequences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
6.6 The Failure Simulation Preorder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1916.6.1 Two Equivalent Definitions and Their Rationale . . . . . . . . . . . 1926.6.2 A Simple Failure Similarity for Finitary Processes . . . . . . . . . 1966.6.3 Precongruence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1986.6.4 Soundness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205
6.7 Failure Simulation is Complete for Must Testing . . . . . . . . . . . . . . . . 2066.7.1 Inductive Characterisation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2076.7.2 The Modal Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2116.7.3 Characteristic Tests for Formulae . . . . . . . . . . . . . . . . . . . . . . . 213
6.8 Simulations and May Testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2196.8.1 Soundness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2206.8.2 Completeness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
6.9 Real-Reward Testing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2236.10 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
7 Weak Probabilistic Bisimulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2337.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2337.2 A Simple Bisimulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2347.3 Compositionality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2387.4 Reduction Barbed Congruence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2407.5 Bibliographic Notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244
Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
List of Symbols
P(X) 9N 9R≥0 15⊕i∈Ipi · ϕi 24〈a〉ψ 45� 103p⊕ 73rec x.P 149∼ 42≺ 43 43≤Ho 72�may 72�may 72�pmay 76�Ω
pmay 76�Ω
ermay 87�Ω
nrmay 84�Ω
rrmay 224�Emay
138�L 104 s 120�S 104�S 121 o
FS128
kFS
207�k
S 151 S
FS196
≈ 233→R 74P+(O) 71
xi
xii List of Symbols
R 13R
n 15ϕ1p⊕ϕ2 45[a]ψ 49� 103|A 74F(R) 196∼n 42≺− 53
=L 44≤Sm 72�must 72�must 72�pmust 76�Ω
pmust 76�Ω
ermust 87�Ω
nrmust 84�Ω
rrmust 224�Emust 138�F 104
FS120
�FS
104�
FS121
�∞FS
210 e
FS192
cFS
199≈s 234→ep 91a−→ 23τ−→ 119a⇒ 120⇒� 168⇒ δ,dp 183�−→X 104⇒ �−→A 120Ch 84Ch
min 86V 75V
hmin 87
Vδ,h 93
Vδ,hmin 93
A(T , P ) 71Ah
min 87Ad(T , P ) 169
List of Symbols xiii
R† 24�ωX 157�Δ� 19s 19D(S) 19P(X) 33m 36Hd (X, Y ) 54Imgf (Θ) 73T 74h ·O 81Tϕ 104[[P]] 107→ω 130Δ×
k 159Ch(R) 155[s] 168dp(s) ↓ 176$Θ 169P
δ,rmax 181
V(Δ) 205Derdp 177α⇒ 104⇒ 159α⇒ω 128⇒δ 181τ−→p 200
ref(X) 104C 75Cδ,h 93Ch
max 87V
h 84V
hmax 87
Vf 110V
δ,hmax 93
Ah(T , P ) 84Ah
max 87R 11�X 16�R 154|Δ| 19‖f ‖ 33Dsub(S) 19[[ϕ]] 45
xiv List of Symbols
m 34Ω 73ExpΔ(f ), f (Δ) 73Tn 74ϕP 104vϕ 135Actωτ 109Q[x�→ P] 152Δ→
k 159ε 150[Δ] 168dp (s) ↑ 176P
rmax 177
Pδ,dp,r 184
Fδ,dp,r 182div 211