Beale number: Difference between revisions
en>قلی زادگان No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
The | |||
In [[computer science]], a '''computation history''' is a sequence of steps taken by an [[abstract machine]] in the process of computing its result. Computation histories are frequently used in [[Mathematical proof|proofs]] about the capabilities of certain machines, and particularly about the [[undecidable problem|undecidability]] of various [[formal languages]]. | |||
Formally, a computation history is a (normally [[Finite set|finite]]) sequence of '''configurations''' of a formal [[automaton]]. Each configuration fully describes the status of the machine at a particular point. To be valid, certain conditions must hold: | |||
* the first configuration must be a valid initial configuration of the automaton and | |||
* each transition between adjacent configurations must be valid according to the transition rules of the automaton. | |||
In addition, to be '''complete''', a computation history must be finite and | |||
* the final configuration must be a valid terminal configuration of the automaton. | |||
The definitions of "valid initial configuration", "valid transition", and "valid terminal configuration" vary for different kinds of formal machines. | |||
A [[deterministic]] automaton has exactly one computation history for a given initial configuration, though the history may be infinite and therefore incomplete. | |||
== Finite State Machines == | |||
For a [[finite state machine]] <math>M</math>, a configuration is simply | |||
the current state of the machine, together with the remaining input. The first configuration must be the initial state of <math>M</math> and the complete input. A transition from a configuration <math>(S,I)</math> to | |||
a configuration <math>(T,J)</math> is allowed if <math>I=aJ</math> for | |||
some input symbol <math>a</math> and if <math>M</math> has a transition from | |||
<math>S</math> to <math>T</math> on input <math>a</math>. The final | |||
configuration must have the empty string <math>\epsilon</math> as its remaining | |||
input; whether <math>M</math> has accepted or rejected the input depends | |||
on whether the final state is an accepting state. <ref name="MumfordJain2009">{{cite book|author1=Christine L. Mumford|author2=Lakhmi C. Jain|title=Computational Intelligence: Collaboration, Fusion and Emergence|url=http://books.google.com/books?id=eECU8WrC99wC&pg=PA337|accessdate=25 March 2012|year=2009|publisher=Springer|isbn=978-3-642-01798-8|page=337}}</ref> | |||
== Turing Machines == | |||
Computation histories are more commonly used in reference to [[Turing machines]]. The configuration of a single-tape Turing machine consists of the contents of the tape, the position of the read/write head on the tape, and the current state of the associated state machine; this is usually written | |||
<math>...0011010101q00110101010...</math> | |||
where <math>q</math> is the current state of the machine, represented in some | |||
way that's distinguishable from the tape language, and where <math>q</math> is | |||
positioned immediately before the position of the read/write head. | |||
Consider a Turing machine <math>M</math> on input <math>w</math>. The first | |||
configuration must be <math>q_0 w_0 w_1 ...</math>, where <math>q_0</math> | |||
is the initial state of the Turing machine. The machine's state in the final | |||
configuration must be either <math>q_a</math> (the accept state) or <math>q_r</math> | |||
(the reject state). A configuration <math>c_{i+1}</math> is a valid successor | |||
to configuration <math>c_i</math> if there's a transition from the state in | |||
<math>c_i</math> to the state in <math>c_{i+1}</math> which manipulates the | |||
tape and moves the read/write head in a way that produces the result in | |||
<math>c_{i+1}</math>.<ref name="Blass2010">{{cite book|author=Andreas Blass|title=Fields of Logic and Computation: Essays Dedicated to Yuri Gurevich on the Occasion of His 70th Birthday|url=http://books.google.com/books?id=HqIRT51n74YC&pg=PA468|accessdate=25 March 2012|date=22 October 2010|publisher=Springer|isbn=978-3-642-15024-1|page=468}}</ref> | |||
=== Decidability results === | |||
Computation histories can be used to show that certain problems for | |||
[[pushdown automata]] are [[undecidable problem|undecidable]]. This is because the language of | |||
non-accepting computation histories of a Turing machine <math>M</math> | |||
on input <math>w</math> is a [[context-free language]] recognizable by a | |||
non-deterministic pushdown automaton. | |||
We encode a Turing computation history <math>c_0,c_1,...,c_n</math> as the | |||
string <math>C_0 \# C^r_1 \# C_2 \# C^r_3 \# ... \# C_n</math>, where <math>C_i</math> | |||
is the encoding of configuration <math>c_i</math>, as discussed above, and where | |||
every other configuration is written in reverse. Before reading a particular | |||
configuration, the pushdown automaton makes a non-deterministic choice | |||
to either ignore the configuration or read it completely onto the stack. | |||
* If the pushdown automaton decides to ignore the configuration, it simply reads and discards it completely and makes the same choice for the next one. | |||
* If it decides to process the configuration, it pushes it completely onto the stack, then verifies that the next configuration is a valid successor according to the rules of <math>M</math>. Since successive configurations are always written in opposite orders, this can be done by, for each tape symbol in the new configuration, popping off a symbol from the stack and checking if they're the same. Where they disagree, it must be accountable for by a valid transition of <math>M</math>. If, at any point, the automaton decides that the transition is invalid, it immediately enters a special accept state which ignores the rest of the input and accepts at the end. | |||
In addition, the automaton verifies that the first configuration is the correct | |||
initial configuration (if not, it accepts) and that the state of the final | |||
configuration of the history is the accept state (if not, it accepts). Since | |||
a non-deterministic automaton accepts if there's any valid way for it to accept, | |||
the automaton described here will discover if the history is not a valid | |||
accepting history and will accept if so, and reject if not. <ref name="Blum1998">{{cite book|author=Lenore Blum|title=Complexity and real computation|url=http://books.google.com/books?id=zxtrVqUP-AwC&pg=PA31|accessdate=25 March 2012|year=1998|publisher=Springer|isbn=978-0-387-98281-6|page=31}}</ref> | |||
This same trick cannot be used to recognize ''accepting'' computation histories | |||
with an NPDA, since non-determinism could be used to skip past a test that would | |||
otherwise fail. A linear-bounded Turing machine is sufficient to recognize | |||
accepting computation histories. | |||
This result allows us to prove that <math>ALL_{PDA}</math>, the language | |||
of pushdown automata which accept all input, is undecidable. Suppose | |||
we have a decider for it, <math>D</math>. For any Turing machine | |||
<math>M</math> and input <math>w</math>, we can form the pushdown automaton | |||
<math>P</math> which accepts non-accepting computation histories for that | |||
machine. <math>D(P)</math> will accept if and only if there are no | |||
accepting computation histories for <math>M</math> on <math>w</math>; this | |||
would allow us to decide <math>A_{TM}</math>, which we know to be undecidable. | |||
==References== | |||
{{reflist}} | |||
[[Category:Theory of computation]] |
Latest revision as of 09:28, 19 December 2013
In computer science, a computation history is a sequence of steps taken by an abstract machine in the process of computing its result. Computation histories are frequently used in proofs about the capabilities of certain machines, and particularly about the undecidability of various formal languages.
Formally, a computation history is a (normally finite) sequence of configurations of a formal automaton. Each configuration fully describes the status of the machine at a particular point. To be valid, certain conditions must hold:
- the first configuration must be a valid initial configuration of the automaton and
- each transition between adjacent configurations must be valid according to the transition rules of the automaton.
In addition, to be complete, a computation history must be finite and
- the final configuration must be a valid terminal configuration of the automaton.
The definitions of "valid initial configuration", "valid transition", and "valid terminal configuration" vary for different kinds of formal machines.
A deterministic automaton has exactly one computation history for a given initial configuration, though the history may be infinite and therefore incomplete.
Finite State Machines
For a finite state machine , a configuration is simply the current state of the machine, together with the remaining input. The first configuration must be the initial state of and the complete input. A transition from a configuration to a configuration is allowed if for some input symbol and if has a transition from to on input . The final configuration must have the empty string as its remaining input; whether has accepted or rejected the input depends on whether the final state is an accepting state. [1]
Turing Machines
Computation histories are more commonly used in reference to Turing machines. The configuration of a single-tape Turing machine consists of the contents of the tape, the position of the read/write head on the tape, and the current state of the associated state machine; this is usually written
where is the current state of the machine, represented in some way that's distinguishable from the tape language, and where is positioned immediately before the position of the read/write head.
Consider a Turing machine on input . The first configuration must be , where is the initial state of the Turing machine. The machine's state in the final configuration must be either (the accept state) or (the reject state). A configuration is a valid successor to configuration if there's a transition from the state in to the state in which manipulates the tape and moves the read/write head in a way that produces the result in .[2]
Decidability results
Computation histories can be used to show that certain problems for pushdown automata are undecidable. This is because the language of non-accepting computation histories of a Turing machine on input is a context-free language recognizable by a non-deterministic pushdown automaton.
We encode a Turing computation history as the string , where is the encoding of configuration , as discussed above, and where every other configuration is written in reverse. Before reading a particular configuration, the pushdown automaton makes a non-deterministic choice to either ignore the configuration or read it completely onto the stack.
- If the pushdown automaton decides to ignore the configuration, it simply reads and discards it completely and makes the same choice for the next one.
- If it decides to process the configuration, it pushes it completely onto the stack, then verifies that the next configuration is a valid successor according to the rules of . Since successive configurations are always written in opposite orders, this can be done by, for each tape symbol in the new configuration, popping off a symbol from the stack and checking if they're the same. Where they disagree, it must be accountable for by a valid transition of . If, at any point, the automaton decides that the transition is invalid, it immediately enters a special accept state which ignores the rest of the input and accepts at the end.
In addition, the automaton verifies that the first configuration is the correct initial configuration (if not, it accepts) and that the state of the final configuration of the history is the accept state (if not, it accepts). Since a non-deterministic automaton accepts if there's any valid way for it to accept, the automaton described here will discover if the history is not a valid accepting history and will accept if so, and reject if not. [3]
This same trick cannot be used to recognize accepting computation histories with an NPDA, since non-determinism could be used to skip past a test that would otherwise fail. A linear-bounded Turing machine is sufficient to recognize accepting computation histories.
This result allows us to prove that , the language of pushdown automata which accept all input, is undecidable. Suppose we have a decider for it, . For any Turing machine and input , we can form the pushdown automaton which accepts non-accepting computation histories for that machine. will accept if and only if there are no accepting computation histories for on ; this would allow us to decide , which we know to be undecidable.
References
43 year old Petroleum Engineer Harry from Deep River, usually spends time with hobbies and interests like renting movies, property developers in singapore new condominium and vehicle racing. Constantly enjoys going to destinations like Camino Real de Tierra Adentro.
- ↑ 20 year-old Real Estate Agent Rusty from Saint-Paul, has hobbies and interests which includes monopoly, property developers in singapore and poker. Will soon undertake a contiki trip that may include going to the Lower Valley of the Omo.
My blog: http://www.primaboinca.com/view_profile.php?userid=5889534 - ↑ 20 year-old Real Estate Agent Rusty from Saint-Paul, has hobbies and interests which includes monopoly, property developers in singapore and poker. Will soon undertake a contiki trip that may include going to the Lower Valley of the Omo.
My blog: http://www.primaboinca.com/view_profile.php?userid=5889534 - ↑ 20 year-old Real Estate Agent Rusty from Saint-Paul, has hobbies and interests which includes monopoly, property developers in singapore and poker. Will soon undertake a contiki trip that may include going to the Lower Valley of the Omo.
My blog: http://www.primaboinca.com/view_profile.php?userid=5889534