Professional Documents
Culture Documents
Computers and The Science of Computing
Computers and The Science of Computing
Computers and The Science of Computing
computing
What is (Not) a computer
• Input, Process, output
Are these computers?
• Juice mixers
• Kitchen Grinders
• Washing Machines
A computer
• Makes significant decisions about it’s inputs
• Can even reject an input
• Is capable of storing inputs
• Is capable of making decisions about it’s
inputs and outputs
Focus of this course
• In this course, we deal with models of abstract
computing machines rather than the architecture
and design of a modern digital computer
• We consider computer as a machine that
computes an output for a given input while being
controlled by a program or table of instructions
• The essential core of a computing machine known
as automaton (Automata, in plural)
Idea of computing
• Input to computing machines are a single
string of symbols
• Symbols are taken from a set of all possible
input symbols known as input alphabet
• String is a sequence of zero or more symbols
from the alphabet
• Output- Yes or no
• A typical automaton does not produce any
real output
• We do not consider how fast or efficient a
computation is
• We focus only in checking whether the
computing machine can compute an output
for a given input.
Computing machines and Languages
• A problem can be stated in two ways
– As a conventional problem, Give input,
find/calculate/compute.. Print output
– As a yes-or-no (True or False) question
• Set of input strings is called a formal language
• The words problem and language are even
considered interchangeable
Why are they called languages?
• A language such as English can be considered
to be nothing but the set of all valid words,
phrases and clauses in English.
• Even a human or natural language such as
English is nothing but a set of strings.
• Since the set of strings that we consider in the
context of computing machines are not
natural to humans , we call them formal
languages.
Birth of the Science of Computing
• Alan Turing is considered to be Father of modern
Computer Science
• Famous paper in 1936
• Illustrated the idea of a general-purpose
computing machine with a central control unit
and a memory unit with a reading head.
• Turing also showed that any computing machine,
when asked to compute a function that is not
computable, goes to an in-finte loop and never
halts for some input strings.- Halting Problem
Why study science of computing?
• Essential science behind all computing
• Natural language processing and computational
linguistics
• Design of compilers
• Automata theory plays a major role in designing
ATMs, kiosks,etc.
• Basis for various aspects of digital and VLSI design
• Helps to frame a solid foundation to learn new
computing technologies and more programming
languages
Some Basics
What is automata theory
• Automata theory is the study of abstract
computational devices
• Abstract devices are (simplified) models of
real computations
• Computations happen everywhere: On your
laptop, on your cell phone, in nature, …
• Why do we need abstract models?
A simple computer
BATTERY
input: switch
output: light bulb
actions: flip switch
states: on, off
A simple “computer”
input: switch
output: light bulb bulb is on if and only if
there was an odd number
actions: f for “flip switch” of flips
states: on, off
Another “computer”
1
1 start off off
1
2 2 2 2
BATTERY
1
2
off on
1
?
5
BATTERY
• Examples
S1 = {a, b, c, d, …, z}: the set of letters in English
S2 = {0, 1, …, 9}: the set of (base 10) digits
S3 = {a, b, …, z, #}: the set of letters plus the
special symbol #
S4 = {(, )}: the set of open and closed brackets
Strings
A string over alphabet S is a finite sequence
of symbols in S.