Abstract
Probabilistic techniques in computer programs are becoming more and more widely used. Therefore, there is a big interest in methods for formal specification, verification, and development of probabilistic programs. In this paper, we present a constructive framework to develop probabilistic programs formally. To achieve this goal, we first introduce a Z-based formalism that assists us to specify probabilistic programs simply. This formalism is mainly based on a new notion of Z operation schemas, called probabilistic schemas, and a new set of schema calculus operations that can be applied on probabilistic schemas as well as ordinary operation schemas. We show the resulting formalism can be used to specify any discrete-time Markov chain. We also reason how one can derive functional probabilistic programs from correctness proofs of formal specifications written in the new formalism. In this way, a completely formal solution to develop probabilistic programs will be proposed.
Keywords
- formal program development
- probabilistic specification
- functional probabilistic program
- CZ set theory
- type theory
This research has been done using research credits of Shahid Beheshti University, G.C. under Contract Number: 600/177.
This is a preview of subscription content, access via your institution.
Buying options
Tax calculation will be finalised at checkout
Purchases are for personal use only
Learn about institutional subscriptionsPreview
Unable to display preview. Download preview PDF.
References
Agha, G., Meseguer, J., Sen, K.: PMaude: Rewrite-based Specification Language for Probabilistic Object Systems. ENTCS 153(2), 213–239 (2006)
Di Pierro, A., Hankin, C., Wiklicky, H.: Probabilistic λ-calculus and Quantitative Program Analysis. Journal of Logic and Computation 15(2) (2005)
Haghighi, H., Mirian-Hosseinabadi, S.H.: An Approach to Nondeterminism in Translation of CZ Set Theory into Type Theory. In: FSEN 2005. ENTCS, vol. 159 (2006)
Haghighi, H., Mirian-Hosseinabadi, S.H.: Nondeterminism in Constructive Z. Fundamenta Informaticae 88(1-2), 109–134 (2008)
Haghighi, H.: Nondeterminism in CZ Specification Language. Ph.D. dissertation, Sharif Univ. of Technology, Iran (2009)
Jonsson, B., Larsen, K.G.: Specification and Refinement of Probabilistic Processes. In: Sixth Annual IEEE Symposium on Logic in Computer Science (1991)
Kozen, D.: Semantics of Probabilistic Programs. Journal of Computer and System Sciences, 328–350 (1981)
Meyn, S., Tweedie, R.L.: Markov Chains and Stochastic Stability, 2nd edn. Cambridge University Press (2008)
Martin-Löf, P.: An Intuitionistic Theory of Types: Predicative Part. In: Rose, H.E., Sheperdson, J.C. (eds.), pp. 73–118. North Holland (1975)
McIver, A., Morgan, C.: Abstraction and Refinement in Probabilistic Systems. ACM SIGMETRICS Performance Evaluation Review 32(4), 41–47 (2005)
McIver, A., Morgan, C.: Developing and Reasoning About Probabilistic Programs in pGCL. In: Cavalcanti, A., Sampaio, A., Woodcock, J. (eds.) PSSE 2004. LNCS, vol. 3167, pp. 123–155. Springer, Heidelberg (2006)
Mirian-Hosseinabadi, S.H.: Constructive Z. Ph.D. dissertation, Essex Univ. (1997)
Morgan, C., McIver, A., Hurd, J.: Probabilistic Guarded Commands Mechanised in HOL. Theoretical Computer Science, pp. 96–112 (2005)
Nordstrom, B., Petersson, K., Smith, J.M.: Programming in Martin-Löf’s Type Theory: An Introduction. Oxford University Press (1990)
Park, S., Pfenning, F., Thrun, S.: A Probabilistic Language Based Upon Sampling Functions. In: ACM Symp. on Principles of Prog. Lang., pp. 171–182 (2005)
Ramsey, N., Pfeffer, A.: Stochastic Lambda Calculus and Monads of Probability Distributions. In: 29th ACM Symp. on Principles of Prog. Lang. (2002)
Woodcock, J., Davies, J.: Using Z, Specifications, Refinement and Proof. Prentice-Hall (1996)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2012 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Haghighi, H., Javanmard, M.M. (2012). Constructive Development of Probabilistic Programs. In: Arbab, F., Sirjani, M. (eds) Fundamentals of Software Engineering. FSEN 2011. Lecture Notes in Computer Science, vol 7141. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-29320-7_6
Download citation
DOI: https://doi.org/10.1007/978-3-642-29320-7_6
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-29319-1
Online ISBN: 978-3-642-29320-7
eBook Packages: Computer ScienceComputer Science (R0)
