1.4 Theory of computation Flashcards

1
Q

Define automation

A

Creating a computer model of a real-life situation and putting it into action

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Define representational abstraction

A

The process of removing unnecessary details so that only information that is required to solve the problem remains

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Define abstraction by generalisation / categorisation

A

The concept of reducing problems by putting similar aspects of a problem into hierarchical catgegories

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Define top-down design

A

Starts with the main system at the top and breaks it down into smaller units

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Define functional abstraction

A

Breaking down a complex problem into a series of reusable functions

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Define data abstraction

A

Hiding how data is represented so that it is easier to build a new kind of data object, for example building a stack from an array

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Define problem abstraction

A

Removing unnecessary details in a problem until the underlying problem is identified to see if this is the same as a problem that has already been solved

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Define information hiding

A

The process of hiding all details of an object that do not contribute to its essential characteristics

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Define finite state machine

A

Any device that stores its current status and whose status can change as the result of an input. Mainly used as a conceptual model for designing and describing systems. There are a finite number of transitions that may take place

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is a state transition diagram?

A

A visual representation of an FSM using circles and arrows

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Define accepting state

A

The state that identifies whether an output has been accepted

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Define state transition table

A

A tabular representation of an FSM showing inputs, current state, and next state

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Define Mealy machine

A

A type of finite state machine with outputs

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is a Turing machine?

A

A theoretical model of computation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is the alphabet of a Turing machine?

A

The acceptable symbols (characters, numbers) for a given Turing machine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Define read/write head

A

The theoretical device that writes or reads from the current cell of tape in a Turing machine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Define halting state

A

The state that stops a Turing machine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Define start state

A

The initial state of a Turing machine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Define transition function/rule

A

A method of notating how a Turing machine moves from one state to another and how the data on the tape changes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

Define state transition diagram

A

A visual representation of the transition function of a Turing machine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

How does a Turing machine operate?

A
  • Tape divided into an infinite number of cells which are used as memory
  • Each cell will contain a symbol, either a character or number, the range of acceptable symbols is the alphabet
  • The read/write head can either read what is in the cell, write to the cell, or erase its contents
  • The tape can move left or right one cell at a time so every cell is accessible by a read/write head
  • The machine can halt at any point if it enters the halting state or if the whole input has been processed
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

What is needed to represent programs with a Turing machine?

A
  • A start state
  • A halting state
  • An alphabet
  • Movement
  • A transition function
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

Define instruction table

A

A method of describing a Turing machine in tabular form

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

Define universal machine

A

A machine that can simulate a Turing machine by reading a description of the machine along with the input of its own tape

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Define a regular language
Any language that can be described using regular expressions
26
Define a regular expression
Notation that contains strings of characters that can be matched to the content of a set
27
What symbol represents or in regex?
|
28
What symbol represents zero or more of a character?
*
29
What symbol represents one or more of a character?
+
30
What symbol represents zero or one of a character?
?
31
What symbol represents a wildcard character?
.
32
Define a context-free language
An unambiguous way of describing the syntax of a language useful when a language is context
33
Define Backus-Naur Form (BNF)
A form of notation for describing the syntax used by a programming language
34
Define terminal in BNF
The final element that requires no further rules
35
Define syntax diagram
A method of visualising rules written in BNF or any other context-free language
36
Define set comprehension
The process of creating sets by describing them using notation rather than listing the elements
37
Define finite set
A set where the elements can be counted using natural numbers up to a particular number, an infinite set is the opposite of this
38
Define cardinality
The number of elements in a set
39
Define countable set
A finite set where the elements can be counted using natural numbers
40
Define countably infinite sets
Sets where the elements can be put into a one-to-one correspondence with the set of natural numbers
41
Define cartesian product
Combining the elements of two or more sets to create a set of ordered pairs
42
Define union
Where two sets are joined and all of the elements of both sets are included in the joined set
43
Define intersection
Describes which elements are common to both sets when two sets are joined
44
Define difference
Describes which elements differ when two sets are joined together
45
Define subset
A set where the elements of one are entirely contained within the other; can include two sets that are exactly the same
46
Define proper subset
Where one set is wholly contained within another and the other set has additional elements
47
Define space complexity
The concept of how much space an algorithm requires
48
Define input size
In Big O notation this is the size of whatever data you are asking an algorithm to work with
49
Define time complexity
The concept of how much time an alogrithm requires
50
Define constant time
In Big O notation where the time taken to run an algorithm does not vary with the input size
51
Define linear time
In Big O notation where the time taken to run an algorithm increases in direct proportion with the input size
52
Define exponential time
In Big O notation where the time taken to run an algorithm increases as an exponential function of the number of inputs
53
Define logarithmic time
In Big O notation where the time taken to run an algorithm increases or decreases in line with a logarithm
54
Define polynomial time
In Big O notation where the time taken to run an algorithm is a polynomial function of the input size
55
What is Big O notation?
Big O notation is a way of describing the time spcae complexity of an algorithm, looking at the maximum time it could take an algorithm to complete
56
Define tractable problem
A problem that can be solved in an acceptable amount of time
57
Define intractable problem
A problem that cannot be solved within an acceptable time frame
58
Define heuristic
With algorithms, it is a method for producing an acceptable but not necessarily best solution to an intractable problem
59
Define unsolvable problem
A problem that has been proven that it cannot be solved computationally
60
What is the halting problem?
An example of an unsolvable problem where it is impssible to write a program that can work out whether another problem will halt given a particular input