We consider the almost-sure (a.s.) termination problem for probabilistic programs, which are a stochastic extension of classical imperative programs. Lexicographic ranking functions provide a sound and practical approach for termination of non-probabilistic programs, and their extension to probabilistic programs is achieved via lexicographic ranking supermartingales (LexRSMs). However, LexRSMs introduced in the previous work have a limitation that impedes their automation: all of their components have to be non-negative in all reachable states. This might result in LexRSM not existing even for simple terminating programs. Our contributions are twofold: First, we introduce a generalization of LexRSMs which allows for some components to be negative. This standard feature of non-probabilistic termination proofs was hitherto not known to be sound in the probabilistic setting, as the soundness proof requires a careful analysis of the underlying stochastic process. Second, we present polynomial-time algorithms using our generalized LexRSMs for proving a.s. termination in broad classes of linear-arithmetic programs.
翻译:我们认为,概率方案几乎(a.s.)的终止问题(a.s.)是典型必要方案的随机延伸。 词汇排序功能为终止非概率方案提供了一种合理和实用的方法,而将其延伸至概率方案是通过地名录排序超边线(LexRSMs)实现的。然而,以往工作中引入的LexRSMs有一个限制,妨碍了其自动化:所有组成部分在所有可达状态中都必须是非负的。这可能导致LexRSM系统甚至不存在简单的终止程序。我们的贡献具有双重性:首先,我们引入了LexRSMs的一般化方法,允许某些组成部分为负的。在概率环境下,这种非概率性终止证据的标准特征迄今尚不为人所知,因为正确性证据要求仔细分析基本的诊断过程。第二,我们使用我们通用的LexRSMs.s.s.s. 来提供多时算法,以证明.s.