Algorithms & Computation

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/15

flashcard set

Earn XP

Description and Tags

week 1 + week 2 computation lecture

16 Terms

1
New cards

What is an algorithm?

a set of instructions for any input that gives a way to compute the correct output

2
New cards

What is computation?

the physical implementation of an algorithm

3
New cards

What is the babylonian algorithm?

Finding a perfect square

<p>Finding a perfect square</p>
4
New cards

What is the babylonian method?

knowt flashcard image
5
New cards

What is the pseudocode for the babylonian algorithm?

knowt flashcard image
6
New cards

What happens in each iteration of the loop in the babylonian algorithm?

we’re cutting the maximum possible distance to the solution in half

7
New cards

What are the 2 problems with the babylonian algorithm?

  • the algortihm can fail due to roudning errors

  • (may) only work for perfect squares


8
New cards
9
New cards

What is all data stored on computers stored in?

bits (0 or 1)

10
New cards

What is an ordered set of 8 bits?

a byte

11
New cards

What was the famous decision problem Hilbert formylate in 1928?

Does there exist an algorithm that takes as input any mathematical statement (in first order logic) and gives as output whether the statement is true or false

12
New cards

Who were the 2 mathematicians that solved the decision problem independently and what did they do to solve it?

  • Church - developed new branch of mathematics λ-calculus

  • Turing - Turing machine


13
New cards

What is a turing machine?

  • infinite tape divided into cells - each cell 0/1

  • tape head - move up & down tape + read symbol directly underneath

  • machine has fixed internal memory (finite set of possible internal states)

  • at each state the machine will:

    • overwrite current symbol w/ diff symbol

    • change internal state

    • move one step left/right

    • halt


14
New cards

What is the input and the output for a turing machine?

  • INPUT - initially whole tape = blank, except for finite string of 0s & 1s starting directly underneath the head extending right

  • OUTPUT - once TM halts, symbol directly beneath the head


15
New cards

What is the halting problem?

  • there is no Turing machine that is guarenteed to halt for all possible input

    • problem is undecidable/uncomputable

  • therefore the halting problem is uncomputable


16
New cards

What are the repercussions of the halting problem?

  • in programming - there is no way to verify whether that program ever terminates

  • in computer science - there are some problems that cannot be computed

  • in maths - there are mathematical truths that cannot be proven

  • in physics - some processes that can never occur in the universe (naturally or otherwise)