Algorithm
The term algorithm is often used to refer to the logic of a program It is a step-by step description of how to arrive at the solution of the given problem. It may be formally defined as a sequence of instructions, designed in a manner that, if the instructions are executed in the specified sequence, the desired results will be obtained. In order to qualify as an algorithm, a sequence of instructions must possess the following characteristics:

Sample Algorithms

50 Students in a class appeared in their final examination. Their mark sheets have been given to you. The division column of the mark sheet contain the division (FIRST, SECOND, THIRD or FAIL) obtained by the student. Write an algorithm to calculate and print the total number of students who passed in FIRST division.

Algorithm
Step 1: Initialize Total, First Division, Total _Mark sheets _Checked to zero. Step 2: Take the mark sheet of the next student.
Step 3: Check the division column of the mark sheet to see if it is FIRST. If no, go to Step 5. Step 4: Add 1 to Total First Division.
Step 5: Add I to Total_Marksheets_Checked
Step 6: Is Total_Marksheets_Checked = 50? ifno, go to Step 2. Step 7: Print TotaI First_Division.
Step 8: Stop.
There are 100 employees in an organization. The organization wants to distribute annual bonus to the employees based on their performance. The performance of the employees is recorded in their annual appraisal forms. Every employee's appraisal form contains his/her basic salary, and the grade for his/her performance during the year. The grade is of three categories - 'A' for outstanding, 'B' for good, and 'c' for average performance. It has been decided that the bonus of an employee will be 100% of the basic salary for outstanding performance, 70% of the basic salary for good performance, 40% of the basic. salary for average performance, and zero for all other cases. Write an algorithm to calculate and print the total bonus amount to be distributed...

...INFORMATION TECHNOLOGY ASSIGNMENT
ON ALGORITHM
Done by
Densil Hamilton
INTRODUCTION
This Assignment was done to show the methods of algorithm. It outlines the meaning of algorithm and steps to be carried out to complete a give problem. Examples were also shown for the methods of representing algorithm.
What is an Algorithm?
An algorithm consists of a set of explicit and unambiguous finite steps which, when carried out for a given set of initial conditions, produce the corresponding output and terminate in finite time. (How to Solve it by Computer, RG Dromey, Prentice Hall UK, 1982)
This is done by a series of steps:
1. Input: there are zero or more quantities which are externally supplied;
2. Output: at least one quantity is produced;
3. Definiteness: each instruction must be clear and unambiguous;
4. Finiteness: if we trace out the instructions of an algorithm, then for all cases the algorithm will terminate after a finite number of steps;
5. Effectiveness: every instruction must be sufficiently basic that a person using only pencil and paper can in principle carry it out. It is not enough that each operation is definite, but it must also be feasible.
WAYS OF REPRESENTING ALGORITHMS
Two ways of represent an algorithm are:
Flowcharts
Pseudo Code
FLOWCHARTS...

...CSE115
Computing Concepts
Monday, May 28, 2012
CSE115: Lecture 11
Chapter 1: Introduction
Overview:
Misconception about Computer Science
what’s Computer Science
algorithms
the importance of algorithmic problem
solving
Pseudocode
Monday, May 28, 2012
CSE115: Lecture 1
2
Misconception about Computer
Science: What it is not
There is a lot of misconception about this area of
study
Unlike physics, chemistry or biology, most of us do
not have an intuitive feeling for Computer Science
It is not the study of
Computers
how to write programs
the uses and applications of computers and
software
These are not necessarily incorrect; rather
incomplete definition of Computer Science
Monday, May 28, 2012
CSE115: Lecture 1
3
Computer Science: What it is not
The study of computers:
Some of the earliest and most fundamental
theoretical work in computer science took place
well before there was any computer (1920 –1940)
There are still branches of computer science that
are quite distinct from a study of “real” machine.
For example in theoretical CS studies the logical
and mathematical properties of problems and their
solutions are based on formal models of
computation and not with actual computers.
Computer is just a tool to computer scientists like
microscope to biologists or telescope to
astronomers.
Monday, May 28, 2012
CSE115:...

...Activity Activity Activity Activity Activity Activity 8 - IntroIntro IntroIntroduction tduction tduction t duction t duction tduction t o Programming Programming Programming Programming Programming Programming Programming
Submit you answers in MS Word format to the D2L dropbox
1. The two major components of any computer system are its _____.
a. input and output
b. data and programs
c. hardware and software
d. memory and disk drives
2. The major computer operations include _____.
a. hardware and software
b. input, processing, output, and storage
c. sequence and looping
d. spreadsheets, word processing, and data communications
3. Another term meaning “computer instructions” is _____.
a.hardware
b. software
c. queries
d. data
4. Visual Basic, C++, and Java are all examples of computer _____.
a. operating systems
b. hardware
c. machine languages
d. programming languages
5. A programming language’s rules are its _____.
a. syntax
b. logic
c. format
d. options
6. The most important task of a compiler or interpreter is to _____.
a. create the rules for a programming language
b. translate English statements into a language such as Java
c. translate programming language statements into machine language
d. execute machine language programs to perform useful tasks
7. Which of the following is a typical input instruction?
a. get accountNumber
b. calculate balanceDue
c. print customerIdentificationNumber
d. total = janPurchase +...

...IMPLEMENTATION OF IMAGE PROCESSING ALGORITHMS ON FPGA
ABSTRACT
This presents the use of a high language programming technique to implement image processing algorithms. FPGA is very instrumental in real time image processing because of the properties it holds. For example, FPGA has a structure that has ability to use temporal and special parallelism. This property is only unique to this kind of gates. Hardware constraints of the machine are another factor to consider because it affects the parallelism. Besides hardware constrains, processing mode is also another factor that affects parallelism. Computer engineers have sometimes been forced to change the settings of the algorithm sine the constraints were so illusive and in compatible. This paper is geared towards dealing with some sets of constraints for different types of image processing.
INTRODUCTION
Computer scientists have always been challenged in their bid to implement real time image processing on serial processors. These difficulties have always been brought up by image properties such as large data sets, and complex operations that need to be performed on the image. In real time processing, 25 frames are witnessed every second. This alone contributes to redundancy and also adds to the slowing down of processing brought about by overheads of retrieval and storing of picture ingredients. In order to counteract the limitations that come with real time image...

...
Notes on Algorithms, Pseudocode, and Flowcharts
Introduction
Do you like hot sauce? Here is an ‘algorithm’ for how to make a good one:
Volcanic Hot Sauce
10-12 scotch bonnets or Habanero, serrano, jalapeno
6 cloves Garlic, peeled and chopped
1/3 c Fresh lime juice
1/3 c Distilled white vinegar
2 tbl Dijon style mustard
2 tbl Olive oil
1 tsp Molasses
1/2 tsp Turmeric
1 tbl Salt or to taste
1. Combine the pepper, garlic, lime juice, vinegar, mustard, oil, molasses, turmeric, and
salt in a blender and puree until smooth. Correct the seasoning, adding more salt or
molasses to taste.
2. Transfer the sauce to a clean bottle. You can use it right away, but the flavor will improve
if you let it age for a few days. Volcanic Hot Sauce will keep almost indefinitely,
refrigerated or at room temperature. Just give it a good shake before using.
As you can see, this ‘algorithm’ is a really a recipe, that is, a set of step-by-step instructions that
takes raw ingredients and produces a tasty result. In general, an algorithm can be described as a
procedure to solve a problem.
In the context of computer programming, an algorithm, is defined as a:
“well-ordered collection of unambiguous and effectively computable operations, that
when executed, produces a result and halts in a finite amount of time.” 1
...

...Algorithm
is a list of instructions for carrying out some process step by step
Flowchart
is a diagram representing the logical sequence in which a combination of steps or operations is to be performed
Types of Flowcharts
Program Flowchart – describes graphically in detail the logical operations and steps within a program and sequence in which these steps are to be executed for the transformation of data to produce the needed output
System Flowchart – is a graphic representation of the procedures involved in converting data on input media to data in output form
Flowcharting Symbols
[pic]
Basic Control Structure
SEQUENCE – process is executed from one to another in a straight forward manner
SELECTION – a choice is provided between two alternatives based on conditions outcome as either TRUE or FALSE
ITERATION – or loop, enables certain operations/tasks/instructions to repeat. These tasks are repeated based on conditions outcome as either TRUE or FALSE
Sequence
[pic]
Examples
The length of a rectangle is equal to 5cm and its width is equals to 3cm. Create a flowchart that will display the area and perimeter of the rectangle.
Given three numbers A=3, B=6, C=9, and D=5. Draw a flowchart to compute and print out the sum, average, and product of the given values.
Selection
[pic]
Examples
Create a flowchart for a program that will accept two inputted values. And based on the inputted values the program will display the...

...Analysis of Algorithm:
INTRODUCTION – ANALYZING CONTROL STRUCTURES-AVERAGE CASE ANALYSIS-SOLVING RECURRENCES.
ALGORITHM
Informal Definition:
An Algorithm is any well-defined computational procedure that takes some value or set of values as Input and produces a set of values or some value as output. Thus algorithm is a sequence of computational steps that transforms the i/p into the o/p.
Formal Definition:
An Algorithm is a finite set of instructions that, if followed, accomplishes a particular task. In addition, all algorithms should satisfy the following criteria.
1. INPUT Zero or more quantities are externally supplied.
2. OUTPUT At least one quantity is produced.
3. DEFINITENESS Each instruction is clear and unambiguous.
4. FINITENESS If we trace out the instructions of an algorithm, then for all cases, the algorithm terminates after a finite number of steps.
5. EFFECTIVENESS Every instruction must very basic so that it can be carried out, in principle, by a person using only pencil & paper.
Issues or study of Algorithm:
• How to device or design an algorithm creating and algorithm.
• How to express an algorithm definiteness.
• How to analysis an algorithm time and space complexity.
• How...