CS 172: Computability and Complexity Introduction and Course Overview, Study notes of Theory of Computation

An introduction and course overview of CS 172: Computability and Complexity. The course is taught by Sanjit A. Seshia, an Assistant Professor at EECS, UC Berkeley. a problem to solve, course logistics, motivation for the course, and grading policies. The course is about models of computation and the limits of computation. a brief introduction to proof and finite automata. The document could be useful as study notes with a rate of 7 out of 10.

Typology: Study notes

2021/2022

Uploaded on 05/11/2023

percyval
percyval 🇺🇸

4

(13)

227 documents

1 / 17

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
1
CS 172: Computability and Complexity
Introduction and
Course Overview
Sanjit A. Seshia
EECS, UC Berkeley
Acknowledgments: L.von Ahn, L. Blum, M. Blum, R. Jhala
S. A. Seshia 2
A Problem
Suppose A
{1, 2, …, 2n}
TRUE or FALSE: There are always two
numbers in A such that one divides the other
with |A| = n+1
(work out the answer with proof)
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff

Partial preview of the text

Download CS 172: Computability and Complexity Introduction and Course Overview and more Study notes Theory of Computation in PDF only on Docsity!

CS 172: Computability and Complexity

Introduction and

Course Overview

Sanjit A. Seshia

EECS, UC Berkeley

Acknowledgments: L.von Ahn, L. Blum, M. Blum, R. Jhala

S. A. Seshia 2

A Problem

Suppose A ⊆⊆⊆⊆ {1, 2, …, 2n}

TRUE or FALSE: There are always two numbers in A such that one divides the other

with |A| = n+

(work out the answer with proof)

S. A. Seshia 3

What we’ll do today

  • Introduction to course staff and students
  • Motivation
  • Course logistics
  • Basics of proof and finite automata
  • A quick survey at the end of class
  • Pick up
    • course information handout
    • survey form

S. A. Seshia 4

About Me

B.Tech., Computer Sc. & Engg., IIT Bombay

M.S. & Ph.D., Computer Science, Carnegie Mellon University, Pittsburgh

Assistant Professor, EECS, UC Berkeley Office: 566 Cory

S. A. Seshia 7

A 3-Question Course

  • Automata Theory:

What are the mathematical models of

computation?

  • Computability Theory:

What problems can(not) computers solve?

  • Complexity Theory:

What makes some problems computationally

hard and others easy?

S. A. Seshia 8

More Succinctly

This course is about

models of computation

and the limits of computation

S. A. Seshia 9

More Succinctly

This course is about

models of computation

and the limits of computation

WHY SHOULD WE CARE?

S. A. Seshia 10

Motivation for this Course

  • Relevant for practical applications
  • Foundation for theoretical work
  • It’s fun!

S. A. Seshia 13

Model: Free Body Diagram

Analyzing a model helps us build reliable bridges, in a cost-effective & timely way

Why not do the same for computers?

S. A. Seshia 14

Programs and Pushdown Automata

  • Sequential (single-threaded) programs

can be mathematically modeled as

“ pushdown automata ”

  • E.g., Microsoft’s Static Driver Verifier searches for bugs in device driver code after creating a pushdown automaton model of the program

S. A. Seshia 15

Programs and Pushdown Automata

  • Variants of pushdown automata are even

used in modeling structure of RNA!

  • This course is not just about computers, it’s about computation!

S. A. Seshia 16

Analyzing correctness of computers is hard!

Limits of computation

S. A. Seshia 19

Grading & Policies

  • 10 homeworks: 30% weightage
  • 2 mid-terms: 20% each
  • 1 final: 30%
  • Homeworks assigned approx. weekly, due

in class/drop-box

  • First homework out next Monday
  • No late homeworks
  • Must list collaborators and references
  • Important! See webpage for course policies

S. A. Seshia 20

Back to the Problem

Suppose A ⊆⊆⊆⊆ {1, 2, …, 2n}

TRUE or FALSE: There are always two numbers in A such that one divides the other

with |A| = n+

TRUE

S. A. Seshia 21

Got Proof?

  • Hint #1: the Pigeonhole Principle

If you put 4 pigeons in 3 holes, at least

one hole will contain > 1 pigeon

  • Hint #2:

Every integer a can be written as a = 2k^ m,

where m is an odd number

S. A. Seshia 22

Suppose A (^) ⊆⊆⊆⊆ {1, 2, …, 2n}

Write every number in A as a = 2km, where m is an odd number between 1 and 2n-

How many odd numbers in {1, …, 2n-1}? (^) n

Since |A| = n+1, there must be two numbers in A with the same odd part (pigeonhole)

with |A| = n+

Say a 1 and a 2 have the same odd part m. Then a 1 = 2im and a 2 = 2jm, so one must divide the other

S. A. Seshia 25

Double Standards?

  • During lectures, my proofs might only have

the first two levels

  • There’s a lot to cover in each class
  • I have to keep you awake
  • I KNOW that my proofs are correct ☺

S. A. Seshia 26

More on Proofs & Background

  • Read Sipser, Chapter 0

S. A. Seshia 27

Introduction to

Finite Automata

(Finite State Machines)

S. A. Seshia 28

The machine accepts a string if the process ends in a double circle

S. A. Seshia 31

q 3

q 0

q 1

q 2

M = (Q, Σ , δδδδ , q 0 , F) What are

**1. Q

  1. F 3.** Σ 4. δδδδ

S. A. Seshia 32

Applications of Finite Automata

  • String matching
  • Modeling sequential digital circuits
  • Embedded controllers in your car

S. A. Seshia 33

Next Steps

  • Read Sipser 1.1 in preparation for next

lecture