SlideShare uma empresa Scribd logo
1 de 39
cs1120 Fall 2011 | David Evans | 14 November 2011
Announcements
Don’t forget to submit your PS8 choice before
5pm today!
  If you don’t submit anything, you are
  expected to do all three options!
Friday’s Class: Rice Hall Dedication
     11am: Dedication
     12-3pm: Tours (Visit our lab in Rice 442)
     3pm: Dean Kamen talk
     5pm: Scavenger Hunt
                                                 2
Exam 2
Out: Monday, 21 November (one week from today)
Due: Wednesday, 30 November, 11:01am
Covers everything in the course
  Classes 1-37 (through Friday’s class – yes there
      may be a question about Rice Dedication)
  Course book Chapters 1-12 (Entire book!)
  Problem Sets 1-7 (and posted comments)
Emphasis on material since Exam 1
You will be allowed to use Scheme, Python, and
  Charme interpreters

                                                     3
Recap Last Class
Since Aristotle, humans have been trying to
  formalize reasoning.
An axiomatic system is a set of axioms and
  inference rules.
Russell and Whitehead wrote Principia
  Mathematica (1910-1913) to formalize all
  number knowledge as an axiomatic system.
Encountered paradoxes…but claimed a
  complete and consistent system.

                                              4
Epimenides “Paradox”



Greece




         Crete




                         5
In its absolutely barest
form, Gödel’s discovery involves
the translation of an ancient
paradox in philosophy into
mathematical terms. That
paradox is the so-called
Epimenides paradox, or liar
paradox. Epimenides was a
Cretan who made one immortal
statement: “All Cretans are
liars.” A sharper version of the
statement is simply “I am lying”;
or, “This statement is false.”


                                    6
What Epimenides Really Said

Τφμβον ἐτεκτιναντο σζκεν, κφδιστε μζγιστε,
Κρῆτες, ἀεὶ ψευδεῖς, κακὰ κθρία,
     γαστζρες ἀργαί.
Ἀλλὰ σὺ γ᾽ οὐ κνῇσκεις,
     ἕστθκας γὰρ ηοὸς αίεί,
Ἐν γὰρ σοὶ ηῶμεν καὶ κινφμεκ᾽ ἠδὲ καὶ ἐσμζν.


                     Rendal Harris (hypothetical) text of Cretica

                                                                    7
What Epimenides “Really” Said
They fashioned a tomb for
thee, O holy and high one
The Cretans, always
liars, evil beasts, idle
bellies!
But thou art not dead: thou
livest and abidest forever,
For in thee we live and
move and have our being.
— Epimenides, Cretica
    (as quoted, no actual     Minos speaking to Zeus
        text survived)
                                                       8
One of Crete’s own prophets has said it:
“Cretans are always liars, evil brutes, lazy
gluttons”.
He has surely told the truth.
— First Epistle of Paul to Titus
   (in the New Testament Bible)




                                               9
The Real Paradox
This statement is false.

What Gödel did:
 Showed the formal system in Principia
 Mathematica could state a sentence
 equivalent to: “This statement has no proof.”



                                                 10
Gödel’s Stronger Result

All consistent axiomatic formulations of
number theory include undecidable
propositions.

        undecidable: cannot be proven either
        true or false inside the system.
The Information, Chapter 6

                     Kurt Gödel
Born 1906 in Brno (now
  Czech Republic, then
  Austria-Hungary)
1931: publishes Über formal
  unentscheidbare Sätze der
  Principia Mathematica und
  verwandter Systeme (On
  Formally Undecidable
  Propositions of Principia
  Mathematica and Related
  Systems)
1939: flees Vienna
Institute for Advanced
  Study, Princeton
Died in 1978 –
  convinced everything
  was poisoned and
  refused to eat
Gödel’s Theorem
All logical systems of any complexity
are incomplete: there are statements
that are true that cannot be proven
within the system.
Proof – General Idea

Theorem: In the Principia
 Mathematica system, there are
 statements that cannot be
 proven either true or false.
Proof: Find such a statement
Gödel’s Statement
G:     This statement does not
       have any proof in the
       system of Principia
       Mathematica.

G is unprovable, but true!
Gödel’s Proof Idea
G: This statement does not have any
proof in the system of PM.

If G is provable, PM would be inconsistent.
If G is unprovable, PM would be incomplete.

Thus, PM cannot be complete and consistent!
Gödel’s Statement
G: This statement does not have
   any proof in the system of PM.
Gödel’s Statement
G: This statement does not have
   any proof in the system of PM.

 Possibilities:
 1. G is true G has no proof
       System is incomplete
 2. G is false G has a proof
       System is inconsistent
incomplete      Pick one:                     some false
                                                 statements


                                    Derives all true
           Derives              statements, and some
   some, but not all true
 statements, and no false     false statements starting
statements starting from a     from a finite number of
  finite number of axioms        axioms and following
 and following mechanical
       inference rules.
                                      mechanical
                                    inference rules.

     Incomplete              Inconsistent Axiomatic
  Axiomatic System                   System
Inconsistent Axiomatic System

                              Derives
                              all true
                  statements, and some false
                   statements starting from a
                     finite number of axioms
                    and following mechanical
                          inference rules.      some false

Once you can prove one false statement,         statements
everything can be proven! false anything
Finishing The Proof
Turn G into a statement in the Principia
  Mathematica system
Is PM powerful enough to express G:
 “This statement does not have any
     proof in the PM system.”
 ?
How to express “does not have any
     proof in the system of PM”
What does “have a proof of S in PM” mean?
  There is a sequence of steps that follow the
    inference rules that starts with the initial axioms
    and ends with S
What does it mean to “not have any proof of S
 in PM”?
  There is no sequence of steps that follow the
    inference rules that starts with the initial axioms
    and ends with S
Can PM express unprovability?
There is no sequence of steps that follows the
  inference rules that starts with the initial
  axioms and ends with S
Sequence of steps:
    T0, T1, T2, ..., TN
   T0 must be the axioms
   TN must include S
   Every step must follow from the previous
         using an inference rule
Can we express
          “This statement”?
Yes!
  If you don’t believe me (and you
  shouldn’t) read Gödel, Escher, Bach over
  winter break.
  We can write every statement as a
  number, so we can turn “This statement
  does not have any proof in the system”
  into a number which can be written in PM.
Gödel’s Proof
G: This statement does not have any proof
in the system of PM.

If G is provable, PM would be inconsistent.
If G is unprovable, PM would be incomplete.
PM can express G.
Thus, PM cannot be complete and consistent!
Generalization

All logical systems of any
complexity are incomplete:
there are statements that are true
that cannot be proven within the
system.
“Practical” Implications
There are mathematical truths that cannot be
  determined mechanically.
We can write a program that automatically
  proves only true theorems about number
  theory, but if it cannot prove something we do
  not know whether or not it is a true theorem.

Mathematicians will never be completely replaced by computers.
What does it mean for an axiomatic system
    to be complete and consistent?

               Derives all true
         statements, and no false
        statements starting from a
          finite number of axioms
         and following mechanical
               inference rules.
What does it mean for an axiomatic system
    to be complete and consistent?


 It means the axiomatic system is weak.

 Indeed, it is so weak, it cannot express:
   “This statement has no proof.”
Impossibility Results
Mathematics (Declarative Knowledge)
 Gödel: Any powerful axiomatic system cannot be
 both complete and consistent
       If it is possible to express “This statement has no
       proof.” in the system, it must be incomplete or
       inconsistent.
Computer Science (Imperative Knowledge)
  Are there (well-defined) problems that cannot be
  solved by any algorithm?
    Alan Turing (and Alonzo Church): Yes!
Computability
A problem is computable if there is an
algorithm that solves it.
What is an algorithm?                 A procedure that always finishes.

What is a procedure? A precise description of a series of steps
                                  that can be followed mechanically*
                                  (without any thought).
        *A formal definition of computable requires a more formal definition of a procedure.

What does it mean to have an algorithm that solves
a problem?
 We have a procedure that always finished, and always provides
 a correct output for any problem instance.
Computability
 Is there an algorithm that solves a problem?

Computable (decidable) problems can be solved by some
  algorithm.
      Make a photomosaic, sorting, drug discovery,
      winning chess (it doesn’t mean we know the
      algorithm, but there is one)
Noncomputable (undecidable) problems cannot be
  solved by any algorithm.
      There might be a procedure (but it doesn’t
      finish for some inputs).
The (Pythonized) Halting Problem
 Input: a string representing a Python
   program.

 Output: If evaluating the input
  program would ever finish, output
  true. Otherwise, output false.
Suppose halts solves Halting Problem
                         Input: a string representing a
      def halts(code):   Python program.
                         Output: If evaluating the input
        ... ? ...
                         program would ever finish, output
                         true. Otherwise, output false.
>>> halts('3 + 3')
True
>>> halts("""
   i=0
   while i < 100:
      i = i * 2""")
False
Halting Examples
>>> halts("""                       >>> halts("""
def fact(n):                        def fact(n):
  if n = 1: return 1                  if n = 1: return 1
  else: return n * fact(n - 1)        else: return n * fact(n - 1)
fact(7)                             fact(0)
""")                                """)
 True                                False
             halts(''''''
                def fibo(n):
                    if n == 1 or n == 2: return 1
                    else: return fibo(n 1) + fibo(n 2)
                fibo(60)
             '''''')
Can we define halts?
  Attempt #1:                           Attempt #2:

def halts(code):                 def halts(code):
  eval(code)                       try:
  return True                        with Timer(100):
                                        eval(code)
                                        return True
                                   except Timer:
                                      return False

   These two approaches fail, but not a proof it cannot be done!
Impossibility of Halts
Recall how Gödel showed incompleteness of PM:
  Find a statement that leads to a contradiction
  Gödel’s statement: “This statement has no proof.”




   Is there an input to halts that leads to a contradiction?
Charge
Wednesday’s class (and Chapter 12):
 Are there any noncomputable problems?

Problem Set 8 Commitments:
  Due before 5pm today
Problem Set 7: Due Wednesday (but not until
  after class)


                                              39

Mais conteúdo relacionado

Semelhante a Class 35: Self-Reference

Modernism Science and Uncertainty
Modernism Science and UncertaintyModernism Science and Uncertainty
Modernism Science and Uncertainty
ron shigeta
 
Can computers think
Can computers thinkCan computers think
Can computers think
GTClub
 

Semelhante a Class 35: Self-Reference (20)

Is it important to explain a theorem? A case study in UML and ALCQI
Is it important to explain a theorem? A case study in UML and ALCQIIs it important to explain a theorem? A case study in UML and ALCQI
Is it important to explain a theorem? A case study in UML and ALCQI
 
artficial intelligence
artficial intelligenceartficial intelligence
artficial intelligence
 
Incompleteness Theorems: Logical Necessity of Inconsistency
Incompleteness Theorems:  Logical Necessity of InconsistencyIncompleteness Theorems:  Logical Necessity of Inconsistency
Incompleteness Theorems: Logical Necessity of Inconsistency
 
Introduction to logic and prolog - Part 1
Introduction to logic and prolog - Part 1Introduction to logic and prolog - Part 1
Introduction to logic and prolog - Part 1
 
4AMT122-PART 1-SLIDES.pptx
4AMT122-PART 1-SLIDES.pptx4AMT122-PART 1-SLIDES.pptx
4AMT122-PART 1-SLIDES.pptx
 
Discrete Math Lecture 01: Propositional Logic
Discrete Math Lecture 01: Propositional LogicDiscrete Math Lecture 01: Propositional Logic
Discrete Math Lecture 01: Propositional Logic
 
Undecidability Basic definitions.pptx
Undecidability Basic definitions.pptxUndecidability Basic definitions.pptx
Undecidability Basic definitions.pptx
 
Computability
Computability Computability
Computability
 
Phil6334 day#4slidesfeb13
Phil6334 day#4slidesfeb13Phil6334 day#4slidesfeb13
Phil6334 day#4slidesfeb13
 
On theories
On theoriesOn theories
On theories
 
[DSC Europe 22] Amazing things that happen with Human-AI synergy - Petar Veli...
[DSC Europe 22] Amazing things that happen with Human-AI synergy - Petar Veli...[DSC Europe 22] Amazing things that happen with Human-AI synergy - Petar Veli...
[DSC Europe 22] Amazing things that happen with Human-AI synergy - Petar Veli...
 
The axiomatic power of Kolmogorov complexity
The axiomatic power of Kolmogorov complexity The axiomatic power of Kolmogorov complexity
The axiomatic power of Kolmogorov complexity
 
Chapter 3 introduction to algorithms handouts (with notes)
Chapter 3 introduction to algorithms handouts (with notes)Chapter 3 introduction to algorithms handouts (with notes)
Chapter 3 introduction to algorithms handouts (with notes)
 
Logic and mathematics history and overview for students
Logic and mathematics history and overview for studentsLogic and mathematics history and overview for students
Logic and mathematics history and overview for students
 
Modernism Science and Uncertainty
Modernism Science and UncertaintyModernism Science and Uncertainty
Modernism Science and Uncertainty
 
What is an axiom?
What is an axiom?What is an axiom?
What is an axiom?
 
Introduction to set theory by william a r weiss professor
Introduction to set theory by william a r weiss professorIntroduction to set theory by william a r weiss professor
Introduction to set theory by william a r weiss professor
 
Can computers think
Can computers thinkCan computers think
Can computers think
 
Theory of Knowledge - mathematics philosophies
Theory of Knowledge -  mathematics philosophiesTheory of Knowledge -  mathematics philosophies
Theory of Knowledge - mathematics philosophies
 
A NOTE ON GÖDEL´S THEOREM
A NOTE ON GÖDEL´S THEOREMA NOTE ON GÖDEL´S THEOREM
A NOTE ON GÖDEL´S THEOREM
 

Mais de David Evans

Mais de David Evans (20)

Cryptocurrency Jeopardy!
Cryptocurrency Jeopardy!Cryptocurrency Jeopardy!
Cryptocurrency Jeopardy!
 
Trick or Treat?: Bitcoin for Non-Believers, Cryptocurrencies for Cypherpunks
Trick or Treat?: Bitcoin for Non-Believers, Cryptocurrencies for CypherpunksTrick or Treat?: Bitcoin for Non-Believers, Cryptocurrencies for Cypherpunks
Trick or Treat?: Bitcoin for Non-Believers, Cryptocurrencies for Cypherpunks
 
Hidden Services, Zero Knowledge
Hidden Services, Zero KnowledgeHidden Services, Zero Knowledge
Hidden Services, Zero Knowledge
 
Anonymity in Bitcoin
Anonymity in BitcoinAnonymity in Bitcoin
Anonymity in Bitcoin
 
Midterm Confirmations
Midterm ConfirmationsMidterm Confirmations
Midterm Confirmations
 
Scripting Transactions
Scripting TransactionsScripting Transactions
Scripting Transactions
 
How to Live in Paradise
How to Live in ParadiseHow to Live in Paradise
How to Live in Paradise
 
Bitcoin Script
Bitcoin ScriptBitcoin Script
Bitcoin Script
 
Mining Economics
Mining EconomicsMining Economics
Mining Economics
 
Mining
MiningMining
Mining
 
The Blockchain
The BlockchainThe Blockchain
The Blockchain
 
Becoming More Paranoid
Becoming More ParanoidBecoming More Paranoid
Becoming More Paranoid
 
Asymmetric Key Signatures
Asymmetric Key SignaturesAsymmetric Key Signatures
Asymmetric Key Signatures
 
Introduction to Cryptography
Introduction to CryptographyIntroduction to Cryptography
Introduction to Cryptography
 
Class 1: What is Money?
Class 1: What is Money?Class 1: What is Money?
Class 1: What is Money?
 
Multi-Party Computation for the Masses
Multi-Party Computation for the MassesMulti-Party Computation for the Masses
Multi-Party Computation for the Masses
 
Proof of Reserve
Proof of ReserveProof of Reserve
Proof of Reserve
 
Silk Road
Silk RoadSilk Road
Silk Road
 
Blooming Sidechains!
Blooming Sidechains!Blooming Sidechains!
Blooming Sidechains!
 
Useful Proofs of Work, Permacoin
Useful Proofs of Work, PermacoinUseful Proofs of Work, Permacoin
Useful Proofs of Work, Permacoin
 

Último

CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service 🕶
CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service  🕶CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service  🕶
CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service 🕶
anilsa9823
 
Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️
Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️
Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️
soniya singh
 
CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service 👔
CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service  👔CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service  👔
CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service 👔
anilsa9823
 
Rohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No AdvanceRohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Call Girls In Delhi Whatsup 9873940964 Enjoy Unlimited Pleasure
 
Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️
Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️
Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️
soniya singh
 
Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...
Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...
Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...
baharayali
 
Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...
Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...
Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...
Call Girls In Delhi Whatsup 9873940964 Enjoy Unlimited Pleasure
 

Último (20)

The King Great Goodness Part 2 ~ Mahasilava Jataka (Eng. & Chi.).pptx
The King Great Goodness Part 2 ~ Mahasilava Jataka (Eng. & Chi.).pptxThe King Great Goodness Part 2 ~ Mahasilava Jataka (Eng. & Chi.).pptx
The King Great Goodness Part 2 ~ Mahasilava Jataka (Eng. & Chi.).pptx
 
CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service 🕶
CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service  🕶CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service  🕶
CALL ON ➥8923113531 🔝Call Girls Nishatganj Lucknow best Female service 🕶
 
Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️
Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️
Call Girls in majnu ka tila Delhi 8264348440 ✅ call girls ❤️
 
CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service 👔
CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service  👔CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service  👔
CALL ON ➥8923113531 🔝Call Girls Singar Nagar Lucknow best Night Fun service 👔
 
Jude: The Acts of the Apostates (Jude vv.1-4).pptx
Jude: The Acts of the Apostates (Jude vv.1-4).pptxJude: The Acts of the Apostates (Jude vv.1-4).pptx
Jude: The Acts of the Apostates (Jude vv.1-4).pptx
 
MEIDUNIDADE COM JESUS PALESTRA ESPIRITA1.pptx
MEIDUNIDADE COM JESUS  PALESTRA ESPIRITA1.pptxMEIDUNIDADE COM JESUS  PALESTRA ESPIRITA1.pptx
MEIDUNIDADE COM JESUS PALESTRA ESPIRITA1.pptx
 
Deerfoot Church of Christ Bulletin 4 28 24
Deerfoot Church of Christ Bulletin 4 28 24Deerfoot Church of Christ Bulletin 4 28 24
Deerfoot Church of Christ Bulletin 4 28 24
 
black magic specialist amil baba pakistan no 1 Black magic contact number rea...
black magic specialist amil baba pakistan no 1 Black magic contact number rea...black magic specialist amil baba pakistan no 1 Black magic contact number rea...
black magic specialist amil baba pakistan no 1 Black magic contact number rea...
 
Rohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No AdvanceRohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
Rohini Sector 21 Call Girls Delhi 9999965857 @Sabina Saikh No Advance
 
Pradeep Bhanot - Friend, Philosopher Guide And The Brand By Arjun Jani
Pradeep Bhanot - Friend, Philosopher Guide And The Brand By Arjun JaniPradeep Bhanot - Friend, Philosopher Guide And The Brand By Arjun Jani
Pradeep Bhanot - Friend, Philosopher Guide And The Brand By Arjun Jani
 
Elite Class ➥8448380779▻ Call Girls In Mehrauli Gurgaon Road Delhi NCR
Elite Class ➥8448380779▻ Call Girls In Mehrauli Gurgaon Road Delhi NCRElite Class ➥8448380779▻ Call Girls In Mehrauli Gurgaon Road Delhi NCR
Elite Class ➥8448380779▻ Call Girls In Mehrauli Gurgaon Road Delhi NCR
 
+92343-7800299 No.1 Amil baba in Pakistan amil baba in Lahore amil baba in Ka...
+92343-7800299 No.1 Amil baba in Pakistan amil baba in Lahore amil baba in Ka...+92343-7800299 No.1 Amil baba in Pakistan amil baba in Lahore amil baba in Ka...
+92343-7800299 No.1 Amil baba in Pakistan amil baba in Lahore amil baba in Ka...
 
English - The Story of Ahikar, Grand Vizier of Assyria.pdf
English - The Story of Ahikar, Grand Vizier of Assyria.pdfEnglish - The Story of Ahikar, Grand Vizier of Assyria.pdf
English - The Story of Ahikar, Grand Vizier of Assyria.pdf
 
Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️
Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️
Call Girls in sarojini nagar Delhi 8264348440 ✅ call girls ❤️
 
Genesis 1:8 || Meditate the Scripture daily verse by verse
Genesis 1:8  ||  Meditate the Scripture daily verse by verseGenesis 1:8  ||  Meditate the Scripture daily verse by verse
Genesis 1:8 || Meditate the Scripture daily verse by verse
 
Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...
Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...
Amil baba, Kala ilam expert in Multan and Black magic specialist in Sindh and...
 
Lucknow 💋 (Call Girls) in Lucknow | Book 8923113531 Extreme Naughty Call Girl...
Lucknow 💋 (Call Girls) in Lucknow | Book 8923113531 Extreme Naughty Call Girl...Lucknow 💋 (Call Girls) in Lucknow | Book 8923113531 Extreme Naughty Call Girl...
Lucknow 💋 (Call Girls) in Lucknow | Book 8923113531 Extreme Naughty Call Girl...
 
Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...
Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...
Russian Call Girls Rohini Sector 39 💓 Delhi 9999965857 @Sabina Modi VVIP MODE...
 
St. John's Church Parish Magazine - May 2024
St. John's Church Parish Magazine - May 2024St. John's Church Parish Magazine - May 2024
St. John's Church Parish Magazine - May 2024
 
Genesis 1:10 || Meditate the Scripture daily verse by verse
Genesis 1:10  ||  Meditate the Scripture daily verse by verseGenesis 1:10  ||  Meditate the Scripture daily verse by verse
Genesis 1:10 || Meditate the Scripture daily verse by verse
 

Class 35: Self-Reference

  • 1. cs1120 Fall 2011 | David Evans | 14 November 2011
  • 2. Announcements Don’t forget to submit your PS8 choice before 5pm today! If you don’t submit anything, you are expected to do all three options! Friday’s Class: Rice Hall Dedication 11am: Dedication 12-3pm: Tours (Visit our lab in Rice 442) 3pm: Dean Kamen talk 5pm: Scavenger Hunt 2
  • 3. Exam 2 Out: Monday, 21 November (one week from today) Due: Wednesday, 30 November, 11:01am Covers everything in the course Classes 1-37 (through Friday’s class – yes there may be a question about Rice Dedication) Course book Chapters 1-12 (Entire book!) Problem Sets 1-7 (and posted comments) Emphasis on material since Exam 1 You will be allowed to use Scheme, Python, and Charme interpreters 3
  • 4. Recap Last Class Since Aristotle, humans have been trying to formalize reasoning. An axiomatic system is a set of axioms and inference rules. Russell and Whitehead wrote Principia Mathematica (1910-1913) to formalize all number knowledge as an axiomatic system. Encountered paradoxes…but claimed a complete and consistent system. 4
  • 6. In its absolutely barest form, Gödel’s discovery involves the translation of an ancient paradox in philosophy into mathematical terms. That paradox is the so-called Epimenides paradox, or liar paradox. Epimenides was a Cretan who made one immortal statement: “All Cretans are liars.” A sharper version of the statement is simply “I am lying”; or, “This statement is false.” 6
  • 7. What Epimenides Really Said Τφμβον ἐτεκτιναντο σζκεν, κφδιστε μζγιστε, Κρῆτες, ἀεὶ ψευδεῖς, κακὰ κθρία, γαστζρες ἀργαί. Ἀλλὰ σὺ γ᾽ οὐ κνῇσκεις, ἕστθκας γὰρ ηοὸς αίεί, Ἐν γὰρ σοὶ ηῶμεν καὶ κινφμεκ᾽ ἠδὲ καὶ ἐσμζν. Rendal Harris (hypothetical) text of Cretica 7
  • 8. What Epimenides “Really” Said They fashioned a tomb for thee, O holy and high one The Cretans, always liars, evil beasts, idle bellies! But thou art not dead: thou livest and abidest forever, For in thee we live and move and have our being. — Epimenides, Cretica (as quoted, no actual Minos speaking to Zeus text survived) 8
  • 9. One of Crete’s own prophets has said it: “Cretans are always liars, evil brutes, lazy gluttons”. He has surely told the truth. — First Epistle of Paul to Titus (in the New Testament Bible) 9
  • 10. The Real Paradox This statement is false. What Gödel did: Showed the formal system in Principia Mathematica could state a sentence equivalent to: “This statement has no proof.” 10
  • 11. Gödel’s Stronger Result All consistent axiomatic formulations of number theory include undecidable propositions. undecidable: cannot be proven either true or false inside the system.
  • 12. The Information, Chapter 6 Kurt Gödel Born 1906 in Brno (now Czech Republic, then Austria-Hungary) 1931: publishes Über formal unentscheidbare Sätze der Principia Mathematica und verwandter Systeme (On Formally Undecidable Propositions of Principia Mathematica and Related Systems)
  • 13. 1939: flees Vienna Institute for Advanced Study, Princeton Died in 1978 – convinced everything was poisoned and refused to eat
  • 14. Gödel’s Theorem All logical systems of any complexity are incomplete: there are statements that are true that cannot be proven within the system.
  • 15. Proof – General Idea Theorem: In the Principia Mathematica system, there are statements that cannot be proven either true or false. Proof: Find such a statement
  • 16. Gödel’s Statement G: This statement does not have any proof in the system of Principia Mathematica. G is unprovable, but true!
  • 17. Gödel’s Proof Idea G: This statement does not have any proof in the system of PM. If G is provable, PM would be inconsistent. If G is unprovable, PM would be incomplete. Thus, PM cannot be complete and consistent!
  • 18. Gödel’s Statement G: This statement does not have any proof in the system of PM.
  • 19. Gödel’s Statement G: This statement does not have any proof in the system of PM. Possibilities: 1. G is true G has no proof System is incomplete 2. G is false G has a proof System is inconsistent
  • 20. incomplete Pick one: some false statements Derives all true Derives statements, and some some, but not all true statements, and no false false statements starting statements starting from a from a finite number of finite number of axioms axioms and following and following mechanical inference rules. mechanical inference rules. Incomplete Inconsistent Axiomatic Axiomatic System System
  • 21. Inconsistent Axiomatic System Derives all true statements, and some false statements starting from a finite number of axioms and following mechanical inference rules. some false Once you can prove one false statement, statements everything can be proven! false anything
  • 22. Finishing The Proof Turn G into a statement in the Principia Mathematica system Is PM powerful enough to express G: “This statement does not have any proof in the PM system.” ?
  • 23. How to express “does not have any proof in the system of PM” What does “have a proof of S in PM” mean? There is a sequence of steps that follow the inference rules that starts with the initial axioms and ends with S What does it mean to “not have any proof of S in PM”? There is no sequence of steps that follow the inference rules that starts with the initial axioms and ends with S
  • 24. Can PM express unprovability? There is no sequence of steps that follows the inference rules that starts with the initial axioms and ends with S Sequence of steps: T0, T1, T2, ..., TN T0 must be the axioms TN must include S Every step must follow from the previous using an inference rule
  • 25. Can we express “This statement”? Yes! If you don’t believe me (and you shouldn’t) read Gödel, Escher, Bach over winter break. We can write every statement as a number, so we can turn “This statement does not have any proof in the system” into a number which can be written in PM.
  • 26. Gödel’s Proof G: This statement does not have any proof in the system of PM. If G is provable, PM would be inconsistent. If G is unprovable, PM would be incomplete. PM can express G. Thus, PM cannot be complete and consistent!
  • 27. Generalization All logical systems of any complexity are incomplete: there are statements that are true that cannot be proven within the system.
  • 28. “Practical” Implications There are mathematical truths that cannot be determined mechanically. We can write a program that automatically proves only true theorems about number theory, but if it cannot prove something we do not know whether or not it is a true theorem. Mathematicians will never be completely replaced by computers.
  • 29. What does it mean for an axiomatic system to be complete and consistent? Derives all true statements, and no false statements starting from a finite number of axioms and following mechanical inference rules.
  • 30. What does it mean for an axiomatic system to be complete and consistent? It means the axiomatic system is weak. Indeed, it is so weak, it cannot express: “This statement has no proof.”
  • 31. Impossibility Results Mathematics (Declarative Knowledge) Gödel: Any powerful axiomatic system cannot be both complete and consistent If it is possible to express “This statement has no proof.” in the system, it must be incomplete or inconsistent. Computer Science (Imperative Knowledge) Are there (well-defined) problems that cannot be solved by any algorithm? Alan Turing (and Alonzo Church): Yes!
  • 32. Computability A problem is computable if there is an algorithm that solves it. What is an algorithm? A procedure that always finishes. What is a procedure? A precise description of a series of steps that can be followed mechanically* (without any thought). *A formal definition of computable requires a more formal definition of a procedure. What does it mean to have an algorithm that solves a problem? We have a procedure that always finished, and always provides a correct output for any problem instance.
  • 33. Computability Is there an algorithm that solves a problem? Computable (decidable) problems can be solved by some algorithm. Make a photomosaic, sorting, drug discovery, winning chess (it doesn’t mean we know the algorithm, but there is one) Noncomputable (undecidable) problems cannot be solved by any algorithm. There might be a procedure (but it doesn’t finish for some inputs).
  • 34. The (Pythonized) Halting Problem Input: a string representing a Python program. Output: If evaluating the input program would ever finish, output true. Otherwise, output false.
  • 35. Suppose halts solves Halting Problem Input: a string representing a def halts(code): Python program. Output: If evaluating the input ... ? ... program would ever finish, output true. Otherwise, output false. >>> halts('3 + 3') True >>> halts(""" i=0 while i < 100: i = i * 2""") False
  • 36. Halting Examples >>> halts(""" >>> halts(""" def fact(n): def fact(n): if n = 1: return 1 if n = 1: return 1 else: return n * fact(n - 1) else: return n * fact(n - 1) fact(7) fact(0) """) """) True False halts('''''' def fibo(n): if n == 1 or n == 2: return 1 else: return fibo(n 1) + fibo(n 2) fibo(60) '''''')
  • 37. Can we define halts? Attempt #1: Attempt #2: def halts(code): def halts(code): eval(code) try: return True with Timer(100): eval(code) return True except Timer: return False These two approaches fail, but not a proof it cannot be done!
  • 38. Impossibility of Halts Recall how Gödel showed incompleteness of PM: Find a statement that leads to a contradiction Gödel’s statement: “This statement has no proof.” Is there an input to halts that leads to a contradiction?
  • 39. Charge Wednesday’s class (and Chapter 12): Are there any noncomputable problems? Problem Set 8 Commitments: Due before 5pm today Problem Set 7: Due Wednesday (but not until after class) 39