Understanding the Halting Problem: A Simple Example

  • Thread starter Thread starter teng125
  • Start date Start date
  • Tags Tags
    Example
Click For Summary

Discussion Overview

The discussion revolves around the Halting Problem, specifically seeking simple examples that illustrate both a program whose halting status is uncertain and the standard proof of the Halting Problem's noncomputability. The scope includes conceptual understanding and examples related to theoretical computer science.

Discussion Character

  • Exploratory
  • Conceptual clarification
  • Homework-related

Main Points Raised

  • One participant requests a simple example to demonstrate the Halting Problem.
  • Another participant seeks clarification on whether the example should be a specific program or the standard proof of noncomputability.
  • A participant proposes the 3n + 1 problem as an example of a program that may or may not halt, describing a specific algorithmic approach to illustrate this uncertainty.
  • There is a suggestion that any unsolved mathematical problem can serve as an example of the Halting Problem.
  • A participant points out that a provided link to an explanation of the 3n + 1 problem is not functioning and requests a reposting of the link.
  • A later reply successfully reposts the link, clarifying a formatting issue with the original post.

Areas of Agreement / Disagreement

The discussion does not reach a consensus on what constitutes a suitable example for the standard proof of the Halting Problem's noncomputability, and participants express differing views on the nature of examples needed.

Contextual Notes

Participants have not fully defined what they mean by "simple example" or clarified the boundaries of the examples they are discussing, leading to ambiguity in the requests and responses.

teng125
Messages
416
Reaction score
0
can somnbody pls give me a simple example to show halting problem

pls

thanx
 
Physics news on Phys.org
What exactly do you want an example of? A program which we don't know whether it halts? Or are you just looking for the standard proof of the halting problem's noncomputability?
 
a simple example program which explains a program which we don't know whether it halts and also a simple example for the standard proof of the halting problem's noncomputability

thanx
 
Well, I don't know what an "example" would be for the standard proof of the halting problem's noncomputability. If you want the proof itself you can find it on wikipedia.

For an example of a program which may or may not halt, consider the 3n + 1 problem. (find an explanation at http://acm.uva.es/p/v1/100.html) . Now write a program which does the following:

i <- 0
start:
i <- i + 1
run the 3n + 1 algorithm starting from i until one of the following two things happen:
if the sequence entered a finite loop of numbers that repeat over and over and do not include 1, return 0
otherwise if the sequence generated by that algorithm terminated in 1, goto start

You can turn any unsolved problem in mathematics into this kind of "example" of the halting problem. For example you could do: "Iterate through all legal proofs in ZFC. If one of them is a proof for Goldbach's conjecture, return 0. Otherwise keep iterating."
 
Last edited by a moderator:
the link above is not found,
pls re - posted

thanx
 
http://acm.uva.es/p/v1/100.html
for some reason the parenthesis was considered part of the link
 
Last edited by a moderator:

Similar threads

  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 54 ·
2
Replies
54
Views
7K
  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 9 ·
Replies
9
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 16 ·
Replies
16
Views
4K
  • · Replies 8 ·
Replies
8
Views
2K