Most Programs Stop Quickly or Never Halt
Cristian S. Calude, Michael A. Stay
Abstract
Since many real-world problems arising in the fields of compiler optimisation, automated software engineering, formal proof systems, and so forth are equivalent to the Halting Problem--the most notorious undecidable problem--there is a growing interest, not only academically, in understanding the problem better and in providing alternative solutions. Halting computations can be recognised by simply running them; the main difficulty is to detect non-halting programs. Our approach is to have the probability space extend over both space and time and to consider the probability that a random N-bit program has halted by a random time. We postulate an a priori computable probability distribution on all possible runtimes and we prove that given an integer k>0, we can effectively compute a time bound T such that the probability that an N-bit program will eventually halt given that it has not halted by T is smaller than 2-k. We also show that the set of halting programs (which is computably enumerable, but not computable) can be written as a disjoint union of a computable set and a set of effectively vanishing probability. Finally, we show that ``long'' runtimes are effectively rare. More formally, the set of times at which an N-bit program can stop after the time 2N+constant has effectively zero density.
Create a lesson
Related papers
Deterministic Identification over Additive Gaussian Channels
Jonathan E. W. Huffmann, Holger Boche
Knowledge Distillation Driven Semantic NOMA with GAN Refinement for 6G Robotic Vehicle Networks
Qifei Wang, Zhen Gao, Li Qiao et al.
Real-Time Reconstruction of Markov Sources over MPR Channels
Pansee S. Elessawy, Nikolaos Pappas
Minimum Rate For Partially Observable Linear System with Side Information: LQG Plant and Gaussian-Markov Source
Sijie Li, Hyeji Kim
Spectral Approximation and Ergodic-Capacity Convergence of HMIMO Channels under Spatial-Wavenumber Domain Mismatch
Hangsong Yan, Hong Yang, Shu Sun
Sharp Minimax Regret for Infinite-Memory Logistic Prediction
Vaneet Aggarwal