CS314: FORMAL LANGUAGES AND AUTOMATA THEORY€¦ · CS314: FORMAL LANGUAGES AND AUTOMATA THEORY L....
Transcript of CS314: FORMAL LANGUAGES AND AUTOMATA THEORY€¦ · CS314: FORMAL LANGUAGES AND AUTOMATA THEORY L....
Chapter 6. Advanced topics in computability theory
CS314: FORMAL LANGUAGES
AND AUTOMATA THEORY L. NADA ALZABEN
Quick Note
Cs314pnu.wordpress.com
Computer Science Department
2
6.1 The recursion theory
It concerns the possibility of making machines that can
construct replicas of themselves.
To consider the recursion theory:
1. Living things are machines • (modern biology assumption ,operate in a mechanistic way).
2. Living things can self-reproduce
• (essential characteristic of every biology species).
3. Machines cannot self-reproduce • (assuming the reproducing of machines by themselves is false, ex. SELF TM)
SELF - REFERENCE
Make a Turing machine that ignores its input and print outs
a copy of its own description , we call it SELF.
SELF - REFERENCE
The job of A is to print out a description of B, and conversely
the job of B is to print out a description of A.
The result is the desired description of SELF.
The jobs are similar, but they are carried out differently.
Our description of A depends on having a description of B.
So we can't complete the description of A until we construct
B.
SELF - REFERENCE
For A we use the machine P<B>, described by q(<B>).
q(<B>) means applying the function q to <B>.
If B can obtain <B>, it can apply q to that and obtain <A>.
B only needs to look at the tape to obtain <B>.
Then after B computes q(<B>) = <A>, it combines A and B
into a single machine and writes its description <AB> =
<SELF> on the tape.
SELF - REFERENCE
SELF - REFERENCE
This can be implemented by any programming language
even plain English “ Print out this line”.
6.1 The recursion theory
TERMINOLOGY FOR THE RECURSION THEOREM
recursion theorem in TM - (If you are designing a machine M,
you can include the phrase "obtain own description <M>" in
the informal description of M's algorithm.)
Two ways:
1. use any other computed value <SELF>
2. simulate <M>.
TERMINOLOGY FOR THE RECURSION
THEOREM
Applications computer Viruses
Another application giving minimal TM
Quick Note
Cs314pnu.wordpress.com
Computer Science Department
12
6.2 Decidability of Logic Theories
Mathematics logic is a branch of mathematics that investigate mathematics itself. It address questions like:
What is a theorem?
What is a proof?
What is truth?
Can an algorithm decide which statements are true?
Are all true statements provable?
We will focus on the problem of:
Determining if the mathematical statements are true or false
And investigate the decidability of the problem. ( depending on the domain of the statements)
Two domains:
1. To decide truth
2. To state its un-decidable
6.2 Decidability of Logic Theories
Remember Boolean operations:
6.2 Decidability of Logic Theories
Statement 1 - infinitely many prime numbers exist - solved.
Statement 2 is Fermat' last theorem - solved, and
Statement 3 - infinitely many prime pairs1 exist - unsolved.
To determine these statements are true we treat each statement as strings and define a language consisting of those statements that are true. Then we ask if the language is decidable.
6.2 Decidability of Logic Theories
The form of the alphabet of this language is:
Formulas are in the prenex normal form if the quantifier
appears in the front of the formula.
Formulas are called statements or sentences if they have
no free variables.
Example:
6.2 Decidability of Logic Theories
To determine the meaning of the variables and relations
we need to determine:
1. The universe over which the variables may take values.
2. A universe together with an assignment of relations to
relation symbols is called a model ( we say M is a tuple
(U,P1,…..,Pk))
Example: (is it true or not)
6.2 Decidability of Logic Theories
Example 6.11: (is it true or not)
Let
If M2=(R,PLUS)?
If M2=(N,PLUS)?
DECIDABLE THEORY:
DECIDABLE THEORY:
No algorithm can decide whether statements in the number
theory are true or false.
Let (N,+) be the model and its theory is Th(N,+):