SlideShare uma empresa Scribd logo
1 de 1
Lecture Note-1: Algorithm and Its Properties 18 Jan 2016
By Rajesh K Shukla, HOD, Department of CSE, SIRTE Bhopal
Downloaded from www.RajeshkShukla.com
Definition of algorithms
An algorithm is a tool for solving any computational problem. It may be defined as a sequence of finite,
precise and unambiguous instructions which are applied either to perform a computation or to solve a
computational problem. These instructions are applied on some raw data called the input, and the
solution of the problem produced is called the output. It is shown in the diagram given below
It was named after 9th century (780-850) Persian mathematician Abu Ja ’far Muhammad ibn-i Musa al-
Khwarizmi and these were originally used in mathematical calculations but they are now widely used in
computer programs.
Properties of algorithms
Algorithms generally share a set of properties
 Input
An algorithm must be supplied with zero or some finite input values externally from a specified set
in order to solve the computational problem and generate some output. The input data is
transformed during the computation in order to produce the output
 Output
The algorithm produces some finite set of outputs after applying some operations on the given set
of input values. The output values are the solution. The output can be anything from data returned
to the calling algorithm, displaying the message, printing the calculation etc. It is possible to have
no output.
 Finiteness
The algorithm must be terminated after executing the finite number of steps so an algorithm must
be a well-defined, ordered set of instructions.
 Definiteness
Each step of an algorithm must be clear and unambiguous so that the actions can be carried out
without any ambiguity. For Example same symbol should not be used to mean multiplication as
well as division in two different places in the algorithm.
 Effectiveness
The algorithm must perform each step correctly and in a finite amount of time therefore time tends
to be more important in calculating the effectiveness of an algorithm. The space and other resources
taken up by algorithm also plays vital role in effectiveness of an algorithm. Effectiveness is precisely
measured after translating the algorithm into a computer program.
 Correctness.
An algorithm must produce the correct output values for all legal input instances of the problem
 Generality
The algorithm should be applicable to all problems of a similar form
 Multiple view
Same algorithm may be represented in different ways
 Multiple Availability
Several algorithms for solving the same problem may exist - with different properties

Mais conteúdo relacionado

Mais procurados

Asymptotic notations
Asymptotic notationsAsymptotic notations
Asymptotic notations
Nikhil Sharma
 
DESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMSDESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMS
Gayathri Gaayu
 
03 algorithm properties
03 algorithm properties03 algorithm properties
03 algorithm properties
Lincoln School
 
Algorithm and pseudo codes
Algorithm and pseudo codesAlgorithm and pseudo codes
Algorithm and pseudo codes
hermiraguilar
 

Mais procurados (20)

Asymptotic notations
Asymptotic notationsAsymptotic notations
Asymptotic notations
 
Daa unit 1
Daa unit 1Daa unit 1
Daa unit 1
 
DESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMSDESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMS
 
02 order of growth
02 order of growth02 order of growth
02 order of growth
 
Unit 1-problem solving with algorithm
Unit 1-problem solving with algorithmUnit 1-problem solving with algorithm
Unit 1-problem solving with algorithm
 
Theory of Computation
Theory of ComputationTheory of Computation
Theory of Computation
 
Performance analysis(Time & Space Complexity)
Performance analysis(Time & Space Complexity)Performance analysis(Time & Space Complexity)
Performance analysis(Time & Space Complexity)
 
Data Structures and Algorithm Analysis
Data Structures  and  Algorithm AnalysisData Structures  and  Algorithm Analysis
Data Structures and Algorithm Analysis
 
Lecture 2 role of algorithms in computing
Lecture 2   role of algorithms in computingLecture 2   role of algorithms in computing
Lecture 2 role of algorithms in computing
 
03 algorithm properties
03 algorithm properties03 algorithm properties
03 algorithm properties
 
Presentation on Breadth First Search (BFS)
Presentation on Breadth First Search (BFS)Presentation on Breadth First Search (BFS)
Presentation on Breadth First Search (BFS)
 
NFA or Non deterministic finite automata
NFA or Non deterministic finite automataNFA or Non deterministic finite automata
NFA or Non deterministic finite automata
 
Introduction to SQL
Introduction to SQLIntroduction to SQL
Introduction to SQL
 
Big o notation
Big o notationBig o notation
Big o notation
 
15 puzzle problem using branch and bound
15 puzzle problem using branch and bound15 puzzle problem using branch and bound
15 puzzle problem using branch and bound
 
Complexity of Algorithm
Complexity of AlgorithmComplexity of Algorithm
Complexity of Algorithm
 
Algorithm and pseudo codes
Algorithm and pseudo codesAlgorithm and pseudo codes
Algorithm and pseudo codes
 
Graph in data structure
Graph in data structureGraph in data structure
Graph in data structure
 
Algorithms and Flowcharts
Algorithms and FlowchartsAlgorithms and Flowcharts
Algorithms and Flowcharts
 
Symbol table in compiler Design
Symbol table in compiler DesignSymbol table in compiler Design
Symbol table in compiler Design
 

Semelhante a Lecture Note-1: Algorithm and Its Properties

2-Algorithms and Complexit data structurey.pdf
2-Algorithms and Complexit data structurey.pdf2-Algorithms and Complexit data structurey.pdf
2-Algorithms and Complexit data structurey.pdf
ishan743441
 
1.1 the introduction of design and analysis of algorithm
1.1 the introduction of design and analysis of algorithm1.1 the introduction of design and analysis of algorithm
1.1 the introduction of design and analysis of algorithm
Mohammed khaja Jamaluddin
 
01 Introduction to analysis of Algorithms.pptx
01 Introduction to analysis of Algorithms.pptx01 Introduction to analysis of Algorithms.pptx
01 Introduction to analysis of Algorithms.pptx
ssuser586772
 

Semelhante a Lecture Note-1: Algorithm and Its Properties (20)

What is algorithm
What is algorithmWhat is algorithm
What is algorithm
 
Introduction to data structure
Introduction to data structureIntroduction to data structure
Introduction to data structure
 
Introduction to algorithms
Introduction to algorithmsIntroduction to algorithms
Introduction to algorithms
 
Data structures algorithms basics
Data structures   algorithms basicsData structures   algorithms basics
Data structures algorithms basics
 
Daa chapter 1
Daa chapter 1Daa chapter 1
Daa chapter 1
 
Introduction to Algorithms Complexity Analysis
Introduction to Algorithms Complexity Analysis Introduction to Algorithms Complexity Analysis
Introduction to Algorithms Complexity Analysis
 
Algorithm - Introduction
Algorithm - IntroductionAlgorithm - Introduction
Algorithm - Introduction
 
Design and Analysis of Algorithm ppt for unit one
Design and Analysis of Algorithm ppt for unit oneDesign and Analysis of Algorithm ppt for unit one
Design and Analysis of Algorithm ppt for unit one
 
Algorithm Analysis.pdf
Algorithm Analysis.pdfAlgorithm Analysis.pdf
Algorithm Analysis.pdf
 
2-Algorithms and Complexit data structurey.pdf
2-Algorithms and Complexit data structurey.pdf2-Algorithms and Complexit data structurey.pdf
2-Algorithms and Complexit data structurey.pdf
 
11 Unit 1 Problem Solving Techniques
11  Unit 1 Problem Solving Techniques11  Unit 1 Problem Solving Techniques
11 Unit 1 Problem Solving Techniques
 
AOA Week 01.ppt
AOA Week 01.pptAOA Week 01.ppt
AOA Week 01.ppt
 
GE8151 notes pdf.pdf
GE8151 notes pdf.pdfGE8151 notes pdf.pdf
GE8151 notes pdf.pdf
 
1.1 the introduction of design and analysis of algorithm
1.1 the introduction of design and analysis of algorithm1.1 the introduction of design and analysis of algorithm
1.1 the introduction of design and analysis of algorithm
 
DA lecture 3.pptx
DA lecture 3.pptxDA lecture 3.pptx
DA lecture 3.pptx
 
chapter 1
chapter 1chapter 1
chapter 1
 
Algorithms notes 2 tutorials duniya
Algorithms notes 2   tutorials duniyaAlgorithms notes 2   tutorials duniya
Algorithms notes 2 tutorials duniya
 
01 Introduction to analysis of Algorithms.pptx
01 Introduction to analysis of Algorithms.pptx01 Introduction to analysis of Algorithms.pptx
01 Introduction to analysis of Algorithms.pptx
 
Unit 2 algorithm
Unit   2 algorithmUnit   2 algorithm
Unit 2 algorithm
 
Introduction To Algorithms
Introduction To AlgorithmsIntroduction To Algorithms
Introduction To Algorithms
 

Mais de Rajesh K Shukla

Mais de Rajesh K Shukla (9)

Quiz 2
Quiz 2Quiz 2
Quiz 2
 
Quiz 1
Quiz 1Quiz 1
Quiz 1
 
Pop operation
Pop operationPop operation
Pop operation
 
Stack: Recursion and Iteration
Stack: Recursion and IterationStack: Recursion and Iteration
Stack: Recursion and Iteration
 
Little o and little omega
Little o and little omegaLittle o and little omega
Little o and little omega
 
Theta notation
Theta notationTheta notation
Theta notation
 
The bog oh notation
The bog oh notationThe bog oh notation
The bog oh notation
 
Big omega
Big omegaBig omega
Big omega
 
Lecture Note-2: Performance analysis of Algorithms
Lecture Note-2: Performance analysis of AlgorithmsLecture Note-2: Performance analysis of Algorithms
Lecture Note-2: Performance analysis of Algorithms
 

Último

Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
jaanualu31
 
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
"Lesotho Leaps Forward: A Chronicle of Transformative Developments"
"Lesotho Leaps Forward: A Chronicle of Transformative Developments""Lesotho Leaps Forward: A Chronicle of Transformative Developments"
"Lesotho Leaps Forward: A Chronicle of Transformative Developments"
mphochane1998
 
DeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesDeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakes
MayuraD1
 
notes on Evolution Of Analytic Scalability.ppt
notes on Evolution Of Analytic Scalability.pptnotes on Evolution Of Analytic Scalability.ppt
notes on Evolution Of Analytic Scalability.ppt
MsecMca
 

Último (20)

HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptxHOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
 
Online electricity billing project report..pdf
Online electricity billing project report..pdfOnline electricity billing project report..pdf
Online electricity billing project report..pdf
 
Block diagram reduction techniques in control systems.ppt
Block diagram reduction techniques in control systems.pptBlock diagram reduction techniques in control systems.ppt
Block diagram reduction techniques in control systems.ppt
 
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptxA CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
A CASE STUDY ON CERAMIC INDUSTRY OF BANGLADESH.pptx
 
Bridge Jacking Design Sample Calculation.pptx
Bridge Jacking Design Sample Calculation.pptxBridge Jacking Design Sample Calculation.pptx
Bridge Jacking Design Sample Calculation.pptx
 
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptxS1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
 
Engineering Drawing focus on projection of planes
Engineering Drawing focus on projection of planesEngineering Drawing focus on projection of planes
Engineering Drawing focus on projection of planes
 
Computer Networks Basics of Network Devices
Computer Networks  Basics of Network DevicesComputer Networks  Basics of Network Devices
Computer Networks Basics of Network Devices
 
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in South Ex (delhi) call me [🔝9953056974🔝] escort service 24X7
 
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKARHAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
HAND TOOLS USED AT ELECTRONICS WORK PRESENTED BY KOUSTAV SARKAR
 
Unleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leapUnleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leap
 
"Lesotho Leaps Forward: A Chronicle of Transformative Developments"
"Lesotho Leaps Forward: A Chronicle of Transformative Developments""Lesotho Leaps Forward: A Chronicle of Transformative Developments"
"Lesotho Leaps Forward: A Chronicle of Transformative Developments"
 
DeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakesDeepFakes presentation : brief idea of DeepFakes
DeepFakes presentation : brief idea of DeepFakes
 
Double Revolving field theory-how the rotor develops torque
Double Revolving field theory-how the rotor develops torqueDouble Revolving field theory-how the rotor develops torque
Double Revolving field theory-how the rotor develops torque
 
notes on Evolution Of Analytic Scalability.ppt
notes on Evolution Of Analytic Scalability.pptnotes on Evolution Of Analytic Scalability.ppt
notes on Evolution Of Analytic Scalability.ppt
 
Design For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the startDesign For Accessibility: Getting it right from the start
Design For Accessibility: Getting it right from the start
 
Hazard Identification (HAZID) vs. Hazard and Operability (HAZOP): A Comparati...
Hazard Identification (HAZID) vs. Hazard and Operability (HAZOP): A Comparati...Hazard Identification (HAZID) vs. Hazard and Operability (HAZOP): A Comparati...
Hazard Identification (HAZID) vs. Hazard and Operability (HAZOP): A Comparati...
 
Hostel management system project report..pdf
Hostel management system project report..pdfHostel management system project report..pdf
Hostel management system project report..pdf
 
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
COST-EFFETIVE  and Energy Efficient BUILDINGS ptxCOST-EFFETIVE  and Energy Efficient BUILDINGS ptx
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
 

Lecture Note-1: Algorithm and Its Properties

  • 1. Lecture Note-1: Algorithm and Its Properties 18 Jan 2016 By Rajesh K Shukla, HOD, Department of CSE, SIRTE Bhopal Downloaded from www.RajeshkShukla.com Definition of algorithms An algorithm is a tool for solving any computational problem. It may be defined as a sequence of finite, precise and unambiguous instructions which are applied either to perform a computation or to solve a computational problem. These instructions are applied on some raw data called the input, and the solution of the problem produced is called the output. It is shown in the diagram given below It was named after 9th century (780-850) Persian mathematician Abu Ja ’far Muhammad ibn-i Musa al- Khwarizmi and these were originally used in mathematical calculations but they are now widely used in computer programs. Properties of algorithms Algorithms generally share a set of properties  Input An algorithm must be supplied with zero or some finite input values externally from a specified set in order to solve the computational problem and generate some output. The input data is transformed during the computation in order to produce the output  Output The algorithm produces some finite set of outputs after applying some operations on the given set of input values. The output values are the solution. The output can be anything from data returned to the calling algorithm, displaying the message, printing the calculation etc. It is possible to have no output.  Finiteness The algorithm must be terminated after executing the finite number of steps so an algorithm must be a well-defined, ordered set of instructions.  Definiteness Each step of an algorithm must be clear and unambiguous so that the actions can be carried out without any ambiguity. For Example same symbol should not be used to mean multiplication as well as division in two different places in the algorithm.  Effectiveness The algorithm must perform each step correctly and in a finite amount of time therefore time tends to be more important in calculating the effectiveness of an algorithm. The space and other resources taken up by algorithm also plays vital role in effectiveness of an algorithm. Effectiveness is precisely measured after translating the algorithm into a computer program.  Correctness. An algorithm must produce the correct output values for all legal input instances of the problem  Generality The algorithm should be applicable to all problems of a similar form  Multiple view Same algorithm may be represented in different ways  Multiple Availability Several algorithms for solving the same problem may exist - with different properties