Algorithm pseudo code and flow charts , Electrical Engineering

Assignment Help:

Algorithm  pseudo code and flow  charts

Algorithm:   before  writing  the program  the programmer must understand  the problem  for which are  program is to  be written. Then  algorithm can be  written. An algorithm is the step  wise  program  definition written  in simple  and precise language  in which  the large  problems  is broken  into unbreakable  steps.  So that  each step can be easily  converted into programming  statement. For writing  the algorithm  knowledge of computer language is not required . an  algorithm has followings  features.

a.Finiteness : must  terminate  after a fixed number of steps.

b.Definiteness -  each step must be  precisely defined.

c.Effectiveness - all operations used in  algorithm should be the  basic  operations and  can be  converted  into  programming  instructions directly.

For  example  if we  want to write  a program  to add   two  numbers.  The algorithm for it  which is independent  of any  programming  language  may be  written  as follows:

Algorithm to add  two  numbers:

a.Read  first  number.

b.Read  second number.

c.Add numbers and  save the sum.

d.Display results .

Pseudo code :  An  algorithm  may be  written  in simple  language  as initially we may not  know  which  programming language will be  used to  implement the  algorithm. Some  times  it may  be difficult to convert an algorithm into the  computer  program. Hence an  intermediate language, which is in  between  teh algorithm and actual programming language is used. This language is called pseudo code.

For example  the algorithm written above to add two  numbers may be  converted to the  pseudo  code  as follows if programming is to  be done  in assembly  language of 8085 .

A-FIRST NO

B-SECOND NO

A-A+B

DISPLAY PORT  - A (SUM)

Flow chart : flow  chart is  the  graphical  representation of the algorithm which  shows the flow of  program  execution. It uses  various  symbols  to represent different  processors. The  symbols which  are used  in the book  are explained  below.


Related Discussions:- Algorithm pseudo code and flow charts

Determine the angular frequency, Q. For given asymptotic Bode plots. (a)...

Q. For given asymptotic Bode plots. (a) Find ¯H 1 , ¯H 2 , and ¯H 3 at ω = 5 rad/s. (b) At what angular frequency ω is the magnitude of ¯H 4 (jω) one-half of the magnitude o

Dual-ramp analog to digital converter, Q. Dual-ramp analog to digital conve...

Q. Dual-ramp analog to digital converter? Figure (a) shows the block diagram of a dual-ramp (dual-slope) A/D converter. After a start-of-conversion pulse, the counter is cleare

What is enhancement mosfets, Q. What is Enhancement MOSFETS? Figure ill...

Q. What is Enhancement MOSFETS? Figure illustrates the cross-sectional structure of an n-channel enhancement MOSFET and its symbol showing as a normally off device when used fo

Gate source cut off voltage, Q. Gate source cut off voltage? It is the ...

Q. Gate source cut off voltage? It is the gate source voltage where the channel is completely cut off and the drain current becomes zero.It is interesting to note that the valu

Silicon Photonics, How does a Mach-Zehnder Modulator work in Silicon?

How does a Mach-Zehnder Modulator work in Silicon?

Basic principles of electromechanical energy conversion, Q. Basic principle...

Q. Basic principles of electromechanical energy conversion? Energy available in many forms is often converted to and from electrical form because electric energy can be transmi

Transfer characteristics , Transfer Characteristics The  transfer char...

Transfer Characteristics The  transfer characteristics of power MOSFET   transfer characteristic shown the variation of ID with V GS    denote the drain current  with shorted

Explain the neg instruction, Explain the NEG instruction. NEG: Two's c...

Explain the NEG instruction. NEG: Two's complement or arithmetic sign inversion (NEG). The NEG instruction two's complements a number that means that the arithmetic sign of a

Electromagnetic torque produced, A dc machine, operating as a generator, de...

A dc machine, operating as a generator, develops 400 V at its armature terminals, corresponding to a field current of 4 A, when the rotor is driven at 1200 r/min and the armature c

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd