DESIGN AND ANALYSIS
OF ALGORITHMS:
INTRODUCTION
DESIGN
and
ANALYSIS
of
ALGORITHMS
 al-Khwārizmī : Persian mathematician,
astronomer
 “On the calculation with Hindu numerals”; 825 AD
decimal positional number system
ALGORITHMS
ZERO (500 AD)
ALGORITHMS
 algorithm  recipe
 an effective method expressed as a finite list of
well-defined instructions for calculating a
function
 Formally, algorithms are Turing machines
BISI BELE BATH
• Take rice and dal, wash and soak for 10 min.
• Soak tamarind in water; extract juice
• Cook the dal till it is half done
• Roast the spices. Mix them with coconut; add turmeric powder,.
• Grind mixture into a thick paste using a little bit of water.
• Heat oil in pan. Burst mustard seeds and add curry leaves.
• Add onions and stir fry till soft.
• Add tamarind juice and 2 cups of water to the onions and bring to boil.
• Add rice, vegetables, tomatoes, half-cooked dal, spice mixture and salt.
Cook on a low flame till done.
• Garnish with coriander leaves.
Source: Wikipedia
ALGORITHMS
In this course:
 Instructions are basic instructions a computer
can do.
 However, we will be independent of
programming
languages/architectures/machines.
 Imperative programming.
Computation
al
problem to
solve
Algorithm Program
Design &
Analysis Programming
DESIGN PARADIGMS
Design paradigm:
An underlying design principle that forms the
basis
of many algorithms.
Example: Towers of Hanoi / Brahma cone
Design principle: Recursion / divide-and-conquer
When subproblems merge: dynamic
DESIGN PARADIGMS
 Brute force
 Divide and conquer
 Dynamic programming
 Greedy method
 Decrease and conquer
 Transform and conquer (aka reductions)
TYPES OF PROBLEMS
 SORTING
 SEARCHING
 STRING PROCESSING
 GRAPH PROBLEMS
 COMBINATORIAL PROBLEMS
 GEOMETRIC PROBLEMS
 NUMERICAL PROBLEMS
UI
NET-
WORK
ALG
LIBRA-
RIES
DB
WE
B
FILE
MGMT
ALGORITHMS AND SOFT.
ENGG.
SYSTEM WEB SEARCH:
google/bing
key algorithms:
indexing for
fast
search;
ranking.
THIS MEC
SYSTEM:
video
key algorithms:
ALGORITHM DESIGN AND ANALYSIS
 CORE OF COMPUTATIONAL THINKING
Useful for your entire career as a computer
engineer.

Modules 1 and 2 introduction

  • 1.
    DESIGN AND ANALYSIS OFALGORITHMS: INTRODUCTION
  • 2.
  • 3.
     al-Khwārizmī :Persian mathematician, astronomer  “On the calculation with Hindu numerals”; 825 AD decimal positional number system ALGORITHMS ZERO (500 AD)
  • 4.
    ALGORITHMS  algorithm recipe  an effective method expressed as a finite list of well-defined instructions for calculating a function  Formally, algorithms are Turing machines BISI BELE BATH • Take rice and dal, wash and soak for 10 min. • Soak tamarind in water; extract juice • Cook the dal till it is half done • Roast the spices. Mix them with coconut; add turmeric powder,. • Grind mixture into a thick paste using a little bit of water. • Heat oil in pan. Burst mustard seeds and add curry leaves. • Add onions and stir fry till soft. • Add tamarind juice and 2 cups of water to the onions and bring to boil. • Add rice, vegetables, tomatoes, half-cooked dal, spice mixture and salt. Cook on a low flame till done. • Garnish with coriander leaves. Source: Wikipedia
  • 5.
    ALGORITHMS In this course: Instructions are basic instructions a computer can do.  However, we will be independent of programming languages/architectures/machines.  Imperative programming. Computation al problem to solve Algorithm Program Design & Analysis Programming
  • 6.
    DESIGN PARADIGMS Design paradigm: Anunderlying design principle that forms the basis of many algorithms. Example: Towers of Hanoi / Brahma cone Design principle: Recursion / divide-and-conquer When subproblems merge: dynamic
  • 7.
    DESIGN PARADIGMS  Bruteforce  Divide and conquer  Dynamic programming  Greedy method  Decrease and conquer  Transform and conquer (aka reductions)
  • 8.
    TYPES OF PROBLEMS SORTING  SEARCHING  STRING PROCESSING  GRAPH PROBLEMS  COMBINATORIAL PROBLEMS  GEOMETRIC PROBLEMS  NUMERICAL PROBLEMS
  • 9.
    UI NET- WORK ALG LIBRA- RIES DB WE B FILE MGMT ALGORITHMS AND SOFT. ENGG. SYSTEMWEB SEARCH: google/bing key algorithms: indexing for fast search; ranking. THIS MEC SYSTEM: video key algorithms:
  • 10.
    ALGORITHM DESIGN ANDANALYSIS  CORE OF COMPUTATIONAL THINKING Useful for your entire career as a computer engineer.