SlideShare ist ein Scribd-Unternehmen logo
1 von 74
“LIST OF LABS”
1. Implementing simple calculator in labview.
2. Computing formulas in labview.
3. Loops and if statements.
4. Implementing tables in labview.
5. Automatic lights switching in labview.
6. Traffic lights control in labview.
7. Water level control.
8. Automatic gear selector.
9. Image processing.
10.Audio signal processing.
11.Arithmetic operations on signals.
12.Noise and filtering.
LAB#01
“IMPLEMENTINGSIMPLECALCULATORINLABVIEW”
TASK:
Make a simple calculatorusinglabview.
TOOLS:
 Numericcontrols.
 Numericindicator.
 Case structure.
 Enum.
 Addoperator.
 Subtract operator.
 Multiplyoperator.
 Divide operator.
 Square operator.
 Square root operator.
FRONT PANEL:
The front panel of the projectincludesthe:
1. Numeric controls: This tool is used to input numbers to perform different
operations on them.
2. Enum: This tool contains list of operations. The user can switch between
different options to select operation.
3. Numeric indicator: This tool is used to display results.
BLOCK DIAGRAM:
The block diagram showsthe developmentstepsof project.The blockdiagramwindow has
the:
1. Numericindicators.
2. Case structure.
The case structure decidesthe true case ineach operation.The case structure containsthe gain
blockfor eachoperation.Thenthe numericindicatorisconnectedatthe otherendtodisplaythe
results.The enumselectsthe operationof the user’schoice.
RESULT:
LAB#02
“COMPUTINGFORMULAS INLABVIEW”
TASK 1:
Find the power factor of the following power triangle diagram using labview.
The formula for power factor is given as:
.
P
P f
A

cos
.
VI
P f
VI


. cosP f 
TOOLS:
 Numeric controls.
 Numeric indicators.
 Multiply.
 Divide.
 Cos.
 Formula.
PROJECT DEVELOPMENT:
The project development steps are as follows:
FRONT PANEL:
The front panel only contains:
1. Numeric Controls: To input the value for V and I to be used in the formula of power factor.
2. Numeric Indicators: To display the results of power factor in each case.
The front panel is as follows:
BLOCK DIAGRAM:
The block diagram contains:
1. Numeric indicators: They show the result of the calculation.
2. Numericcontrols:Theyare usedtoinputthe valuesforvoltage andcurrent.Theyare actually
used from the front panel.
3. Gain: There are two types of gain used. One is multiply and other is divide since the
calculations require multiplication and division of certain terms.
4. Formula: It is used to build or input some formula that will automaticallybe calculatedand
will generate the results.
5. Cos: This element is used to find the cos of some value being input to it.
TASK 2:
Prove the Pythagoras theorem using labview.
Pythagoras theorem states that:
“In a right angled trianglethe square of the hypotenuse is equal to the sum of the squares
of the other two sides.”
2 2 2
hypotenuse perpendicular base 
2 2
hypotenuse perpendicular base 
So let us assume a triangle with the following lengths:
Base = 3cm
Hypotenuse = 5cm
Perpendicular = 4cm
Then,the labview implementationwillhave the followingarrangement.Square the inputsfor
base and perpendicular and add them together and take the square root at the end. The result will
give the length of hypotenuse of the given triangle.
FRONT PANEL:
The projectissimple withtwoinputsandone output.Forinputnumericcontrolsare usedand
for out a numeric indicator is used.
BLOCK DIAGRAM:
The block diagram has the square gain to square the values of base and perpendicular of
triangle.Thenthe addgainadds upthe squaredvaluesandfinallythe square rootgaintakesthe root
of the end result and sends to the numeric indicator to display.
TASK 3:
Implement the following temperature conversion formulas in labview.
1. Centigrade to Fahrenheit.
2. Fahrenheit to centigrade.
3. Centigrade to kelvin.
The conversion formulas for temperature are as follows:
Centigrade to Fahrenheit:
9
32
5
F C 
Fahrenheit to Centigrade:
5
( 32)
9
C F 
Centigrade to Kelvin:
273K C 
FRONT PANEL:
BLOCK DIAGRAM:
The block diagram contains the numeric controls for inputting the temperature. The
temperature value isbeingfedtoformulablockwhichcontainsthe conversionformulaforeachtype
of conversion. Then the result is being displayed on numeric indicator.
The conversion for the giveninput of 20 for each type generates the following results when
calculated manually using a calculator.
200
C=2930
K
200
F=-6.666660
F
200
C=680
F
Comparing the results with labview model, it can be seen that the results are correct.
LAB#03
“LOOPSANDIFSTATEMENTSINLABVIEW”
LOOPS:
Loops are a set of statements whichare to be executedseveral times or are to be repeated
again and again with different values.
In C++ programming, there are three types of loops, namely;
1. While loop.
2. For loop.
3. Do while loop.
WHILE LOOP:
The syntax of while loop is;
( )
{
;
}
while condition
code
The while loopisusedwhenitisnotsure that whenthe loopisto be stopped.Soa condition
is placed in the while condition. The loop continues till the condition in the code is true. When the
conditionbecomesfalse,the loopstopsexecution.The codinginsidewhileloopwillneverbe executed
if the condition comes to be true.
FOR LOOP:
The for loop has the following syntax;
( 0; ; )
{
;
}
for i i x i
code
   
Where i is the loop counter and x is the number of times the loop will be executed. The for
loop is used when the number of terms a loop is executed is known.
DO WHILE LOOP:
The syntax for do while loop is;
{
;
}
( );
do
code
while condition
The do while loopresemblesthe while loop.The onlydifference isthatthe statementsinside
the do while loopwillbe executedatleastonce even if the condition for while is found to be false.
LOOPS IN LAB VIEW:
The loops used in C++ programming can be implemented in labview via block diagrams. The
procedure for implementation is as follows:
WHILE LOOP:
The block diagram representation of while loop in labview is as given below:
This symbol in the diagram of while loop is named to be “loop iteration”.It tells us
the number of times a loop has been executed.
Thissymbol inthe diagramisthe representationof “loopcondition”.Itdecideswhen
the loopis to be stopped.We can create a control withthisconditionsymbol tomanuallycontrol the
execution of certain loop.
The option of while loop can be found in labview by the following steps;
Go tofunctionpaletteandselectthe programmingoption.Thengotostructuresandselectwhileloop.
FOR LOOP:
The for loop is represented by the following symbol in lab view;
Thissymbol isnamedtobe “loopiteration”andfunctionsthe same asincase of while
loop.
This symbol is named to be “loopcount”. The number of times we want the loop to
be executed is fed to this terminal of the loop. The loop executes up to that value.
The for loop is found in the labview as follows:
IF-ELSE STATEMENT:
It is the conditional statement inwhichwe use differentconditionsinsidesame block.The if
statement decides which block of statements to enter for execution. The compiler executes the
statementsorset of statementswhen ifconditionis foundtrue.If the conditionisfoundto be false,
then the else block is executed.
The syntax for if statement is as given below:
( )
{
;
}
{
;
}
if condition
code
else
code
IF-ELSE STATEMENT IN LABVIEW:
The if statement in labview is listed as “case structure”. The diagram for case structure is as
follows:
Bydefault,there are onlytwoconditionseithertrue orfalse.If the requiredconditionisfound
true,the true blockis executed.If the conditionisfoundtobe false,the blockinthe falseconditionis
executed.
This block is named to be “case label”. It is the block in which the conditional
cases are added. There is at least one default case for each condition. For each condition, there is a
separate block diagram. The input and output is common for each condition.
This block is called as “case selector”. This block selects the case to be executed.
TASK-1:
Usingwhileloopimplementa model inlabviewwhichinputsa randomnumber andthen multiplyit
with some nominal temperature and display it on a thermometer scale.
FRONT PANEL:
The front panel of the model contains a
 Thermometer:The thermometershowsthe changesoccurring in temperature on the scale.
 Loop Control: The loop control is a manual control which allows to stop the loop whenever
wanted.
The front panel appears to be as follows:
BLOCK DIAGRAM:
The block diagram of the model contains:
 Random Number: the random number is set of numbers ranging from 0-1. It is found in the
following block of elements.
 NumericConstant: It isa constantnumber.Itisbeingusedas a multiplicationfactorwiththe
random number to range it from 1-10. It is also being used to add the random number with
some nominal temperature value.
 Gain: Two types of gain are being used. One is multiplication and other is addition.
 While Loop: The while loop block executes the function of the block diagram continuously
until being interrupted by the control switch which is connected to the loop condition.
The block diagram of the model is as follows:
RESULTS:
The resultsof the abovemodelgenerateaconstantlychangingtemperature rangingfrom 250
-350
.The
results are as follows:
TASK-2:
Multiply two numbers using while loop and determine the number of times the loop has been
executed.
FRONT PANEL:
The front panel of the model has the following blocks:
 Loop Control: The loopcontrol isa stopbuttonto stopthe loopexecutionwheneverdesired.
 NumericDisplay:One numericdisplaydisplaysthe resultsof the multiplicationof the entered
numbers. The other display outputs the results of the number of times the loop has been
executed.
BLOCK DIAGRAM:
The block diagram contains the following:
 Numerical Constants: The numerical constants are two numbers being multiplied.
 Gain: The gain block is the multiplication of the numbers.
 While Loop:The whileloopexecutesthe multiplicationof numbersagainandagain.The block
i is connected to the body of while loop and then to the numeric display.
RESULTS:
The results of the execution are as follows:
The numeric 2 is displaying the no of times the loop has executed.
TASK-3:
Implement the table of 2 and 5 using fro loop in the labview model.
FRONT PANEL:
The front panel of the model contains:
 NumericControl: It controlsthe max value of loopcounter.The loopexecutesthe number
of timesthe numberenteredinthisblock.
 Array Values: The array values displays the numbers in the for loop.
BLOCK DIAGRAM:
The block diagram contains the following blocks:
 NumericConstant: The numberforwhichthe table isto be displayediswritteninthisblock.
 Increment: It increments the value of loop counter.
 Gain: It multiplies the number for which the table is to be generated by the number in the
loop counter.
 Array: It generates an array of numbers.
 For Loop: It is usedto execute the same commandagain and againusingdifferentvaluesfor
each execution.
RESULTS:
Table of 2:
Table of 5:
Task-4:
Using case structure implement temperature conversion formulas.
FRONT PANEL:
The front panel contains:
 Enum: Enumprovideslistof optionstobe writtenintoit.Itisusedwhennoof commandsare
to be added to the same loop.
 Numeric Control: The temperature which is to be converted to other form is written in this
block.
 Thermometer: It displays the resultant temperature on the scale.
BLOCK DIAGRAM:
The block diagram contains:
 Enum: it allows to add different controls to case structure.
 Case Structure: It is the if else statement of labview. In this block the controls for each
command are added.
 Numeric Control: The temperature to be converted is added in this block.
 Formula Block: The formula block contains conversion formula.
 Thermometer: The result of conversion are shown on thermometer scale.
RESULTS:
The results of conversion are as follows:
LAB#04
“IMPLEMENTINGTABLESINLABVIEW”
TASK-1:
Make a calculator using case structure in lab view.
FRONT PANEL:
The front panel of the project includes the:
 Numeric controls: It is used to input numbers for any kind of operation.
 Enum: it is used to select operation to be performed on numbers.
 Numeric indicator: It is used to display results.
BLOCK DIAGRAM:
The block diagram shows the development steps of project. The block diagram window has
the:
 Numeric Control: to input numbers for the operation.
 Numeric Indicator: To display the results of operation.
 Enum: To select the desired operation.
 Case Structure: To decide the true case in each operation.
 Case Structure: The case structure decides the true case in each operation. The case
structure contains the gain block for each operation. Then the numeric indicator is
connectedat the otherendto displaythe results.The enumselectsthe operationof the
user’s choice.
RESULT:
TASK 2:
Implement the tables from 2-5 in labview using case structures and loops.
FRONT PANEL:
The front panel of the project contains:
 NumericControl: It controlsthe max value of loopcounter.The loopexecutesthe numberof
times the number entered in this block.
 Array Values: The array values displays the numbers in the “for loop”.
BLOCK DIAGRAM:
The block diagram contains the following blocks:
 Numeric Control: Three numeric controls are there:
Numeric control 3 contains the numbers of which table is being displayed.
Numeric control 4 contains the case value.
Numeric control 5 is displaying the value of loop counts.
 Increment: It increments the value of loop counter.
 Gain: It multiplies the number for which the table is to be generated by the number in the
loop counter.
 Array: It generates an array of numbers.
 For Loop: It is usedto execute the same commandagain and againusingdifferentvalues for
each execution.
 Case Structure: It is used to decide the correct case for the input number.
RESULTS:
The result-s of the simulation are as follows:
Table of 2:
Table of 3:
Table of 4:
Table of 5:
LAB#05
“AUTOMATICLIGHTSSWITCHINGINLABVIEW”
LIGHT DETECTING RESISTORS:
The lightdetectingresistorsare calledas LDR’s. These are variable resistorswhose resistance
decreases with increasing light intensity. This phenomenon is called as photoconductivity. Theyare
constructed with high resistance semiconductor material that is why the resistance of LDR’s is very
high. The resistance lies in the range of mega-ohms. They are used in light sensing applications.
If incident light on a photoresistor exceeds a certain frequency, photons absorbed by the
semiconductorgive bound electrons enoughenergytojumpintothe conductionband.The resulting
free electronsconductelectricity,therebylowering resistance.The resistance range andsensitivityof
a photoresistor can substantially differ among dissimilar devices. Moreover, unique photo resistors
may react substantially differently to photons within certain wavelength bands.
TASK-1:
Implementa project inlabviewwhichturns offthe lightsinthe hoursof daytime andturns them on
in the night time.
FRONT PANEL:
The front panel of the project contains:
 Led’s:The LED’s inthe projectare the representationof streetlights.Theyare turnedonand
off aftercalculatedperiodof time.
 Loop Control: The loopcontrol controlsthe loopexecutionmanually.The loopcanbe
stoppedanytime usingthe loopcontrol button.
The front panel of the projectisas follows:
BLOCK DIAGRAM:
The blockdiagram of the projectcontains:
 LED’s: The LED’s representstreetlightswhichare tobe controlledautomatically.
 Local Variables:They provide control forLED’s.Theycan be usedin“write mode” i.e.
commandscan be givento them.Orcan be usedin “read mode” i.e.commandscan be
takenfromthem.
 Delay: It isa type of clockor timerthatcausesdelayinsome task.If a task isto be
performedfora specifictime,thenthistool isusedtocause a delayand performitfor
requiredtime.
 Flat Sequence:Thistool of labview performsatask insequentialorder.The tasksare
performedinasequence inwhichtheyare placedinflatsequence cases.
 While Loop:The while loopwill keeponperformingthe taskplacedinside itaslongas
required.
 Loop Control: itis a manual control for a loop.Loopcan be stoppedata desiredinstant
usingthistool.
The blockdiagram of the projectis as follows:
PROCEDURE:
The ideaof streetlightsisthattheyturn onautomaticallyinthe nighthoursandswitchoff
by themselvesinthe daytimes.There canbe twoproceduresforcontrollingthe lights.
i. By usingLDR’s anddark sensors.
ii. Usingsome timercircuitthat turns themonfor some calculatedhoursandturns them
off for the restof the time.
Implementingthe ideaof timersinlabviewrequiresthe followingprocedure.
Let;
2 1sechours 
The time from5am-7pm can be consideredtobe the dayhours.They counttotallyas 14
hours.So;
14 7sechours 
The rest of the hoursfrom7pm-5am can be consideredtobe the nighttime whichare 10
hoursin total.So,
10 5sechours 
 Step-1:
Create local variable witheachLED.Connectthe local variable withthe LED. Covert
the local variable to reading mode.
 Step-2:
Create twoblocksof the flatsequence tool andplace the local variablesinsidethe
flatsequence andsetthe local variablesto writingmode.
 Step-3:
Create constantswithlocal variables.Inthe firstblockof flatsequence setthe local
variable totrue case i.e.LEDs will turnon.Inthe secondblockof flatsequence,setthe local
variablestofalse case i.e LED’swill turnoff.
 Step-4:
Selectadelayfromtimersandplace one each ineach blockof flatsequence. Create
a constant witheachtimerandwrite the desiredunitsof time ineachconstant.
 Step-5:
Simulate the project.
The simulation results are as follows:
TASK-2:
Using the idea of delays, make a project in labview that controls the lightning system of a house.
FRONT PANEL:
The front panel of the project has the following tools:
 LED’s.
 Loop control.
The loop controls is a manual control for stopping the loop at the desired time. The three LED’s
representthe lightsof threedifferentareasinahouse.Theyrepresentthelightsof kitchen,TV lounge
and outer lights.
BLOCK DIAGRAM:
The block diagram of the project has the following tools;
 LED’s: The LED’s representthe lightsof a certainhouse whichare to be controlled
automatically.
 Local Variables:They provide control forLED’s.
 Delay: thisclocktimerprovidesdelayforturningthe LED’son andoff.
 Flat Sequence:Thistool helpstoturnon and turn off the lightsinsequential order.
 While Loop:The while loopwill keeponperformingthe taskplacedinside itaslongas
required.
 Loop Control: It isa manual control fora loop.Loopcan be stoppedat a desiredinstant
usingthistool.
The blockdiagram of the projectis as follows:
PROJECT EXPLANATION:
The requirement of the project is that the lights of the kitchen must turn ON by 7pm in the
night, the lights of the TV lounge must turn ON by 9pm and the lights of the outer region e.g lawn
must turn ON by 12pm in the night and all the lights must turn OFF altogether in the morning by
around7AM. The calculatedtime forthese hoursis 5 seconds,4 secondsand 3 seconds respectively.
Soeachof the sectioninflat sequence hasthedesireddelayinthe timerandthedesiredlocalvariables
are being commanded to turn on or off the respective led’s in the front panel for required time.
SIMULATION RESULTS:
The results of simulation are as follows:
LAB#06
“TRAFFICLIGHTSCONTROL INLABVIEW”
TASK:
Control the traffic signal lights using delays in labview.
PROJECT EXPLANATION:
The requirements of the project are that the traffic signal lights must switch from one to
anotheraftera calculated periodof time.All the lightsmuststay ON for a short spanof 3-4 minutes.
Scaling the time span to sample time;
Let,
1min 1sec
,
3min 3sec
then


So the lights will turn ON for 3 seconds each.
FRONT PANEL:
The front panel of the project contains the following tools;
1. LED’s
2. Rectangle shape.
The front panel view of the project is as given below.
BLOCK DIAGRAM:
The block diagram of the project contains the following tools;
1. LED’s.
2. Local variables.
3. Flat sequence.
4. While loop.
5. Loop control.
6. Timer.
PROCEDURE:
Inserta simple rectangularblockinthe blankVIfile.Thencollectthree LED’sand place them
inthe project’sfrontpanel.Openthe colorpalletfromthe optionsandchange the colorsof the LED’s
toturnthemredgreenandyellowtorepresentthetrafficsignallights.Arrange alltheLED’sinaproper
sequence andplace themabove the rectangularbox.Groupall the shapesandtoolstogethersothey
don’t move apart. Then open the block diagram and create the local variables associated with each
LED. Create fourcopiesofeachLEDandcontainthree copiesinthe three sequencesof aflatsequence.
Place a timerin each sequence of the flat sequence andsetthe timerto 3000ms. Containthe whole
diagram in the while loop. Create a control with the loop control for manual control of loop.
RESULTS:
The results of the simulation are as follows:
LAB#07
“WATER LEVELCONTROL”
TASK:
Construct a model in labviewthat controls the water level automaticallysuch that when it reaches
the value of about 80% of the total heightofthe tank, the water valve turns offand whenthe water
level reaches the minimum value of about 10%, the valve opens up.
FRONT PANEL:
The front panel of the project contains the following tools.
1. Water tank.
2. Horizontal slider bar.
3. Vertical slider bar.
4. Numeric display.
5. LED’s.
6. Loop control.
BLOCK DIAGRAM:
The block diagram of the project contain the following tools.
1. Horizontal slider control.
2. Vertical slider control.
3. Numeric constant.
4. Gain.
5. Feedback loop.
6. In-range.
7. Timer.
8. Loop control.
9. While loop.
PROCEDURE:
Collecta tankfrom the numericindicators.CollecttwoLED’sthat indicate the full andempty
level of the tank.Change the color of the LED indicatingfull leveltogreenand the one indicatingthe
empty level by red. Collect a horizontal and a vertical slide bars and place the along the tank. Name
the horizontal slide bar as inflow and the vertical slide bar as outflow. When the inflow slide bar is
full,the tank intakeswaterand fillsup.Whenthe outflow slide baris full,the tank dischargeswater
and becomes empty.
Openthe blockdiagram of the projectand subtract the value inthe outflow fromthe inflow.
Then create a feedback loop and connect the results from the subtraction with the feedback loop
througha tool named“in range”. Connecttwonumericconstantswitheach terminal of the in range
and set the range from 0-100. Connect the output to the tank. Connect two gains with each LED in
blockdiagram,one gaincomparesthe lessthanandequal valueandothercomparesgreaterthanand
equal value. Connect the output from each LED to the tank. Simulate the project.
RESULTS:
The results of the simulation are as follows:
LAB#08
“AUTOMATIC GEARSELECTOR”
SPEEDOMETER:
A speedometer or a speed meter is a gauge that measures and displays the instantaneous
speedof a vehicle.Nowuniversallyfittedtomotorvehicles,theystartedtobe available asoptionsin
the 1900s, and as standard equipment from about 1910 onwards. Speedometers for other vehicles
have specificnamesanduse othermeansof sensingspeed.Foraboat,thisisa pit log.Foran aircraft,
this is an airspeed indicator.
BRAKES:
A brake is a mechanical device whichinhibitsmotion,slowingorstoppinga movingobjector
preventing its motion.The rest of this article is dedicated to varioustypes of vehicular brakes.Most
commonlybrakesuse frictionbetweentwosurfacespressedtogethertoconvertthe kineticenergyof
the moving object into heat, though other methods of energy conversion may be employed. For
example regenerative brakingconvertsmuchof the energytoelectrical energy,whichmaybe stored
for later use. Other methods convert kinetic energy into potential energy in such stored forms as
pressurized air or pressurized oil. Eddy current brakes use magnetic fields to convert kinetic energy
into electric current in the brake disc, fin, or rail, which is converted into heat. Still other braking
methods even transform kinetic energy into different forms,for example by transferring the energy
to a rotating flywheel.
ACCELERATOR:
A valve that regulatesthe flowof a fluid,suchas the valve in an internal-combustionengine
that controlsthe amount of vaporizedfuel enteringthe cylinders.A leverorpedal controllingsucha
valve.
AUTOMATIC GEAR SYSTEM:
An automatic transmission (also called automatic gearbox) is a type of motor vehicle
transmissionthatcan automaticallychange gearratios as the vehicle moves,freeingthe driverfrom
having to shift gears manually. Like other transmission systems on vehicles, it allows an internal
combustionengine,bestsuitedtorunatarelativelyhighrotationalspeed,toprovidearange of speed
and torque outputs necessary for vehicular travel. Electronically controlled transmissions, which
appearon some newercars,still use hydraulicstoactuate the clutchesandbands,buteachhydraulic
circuitiscontrolledbyanelectricsolenoid.Thissimplifiestheplumbingonthe transmissionandallows
for more advanced control schemes.
TASK:
Implement an automatic gear selector for a car that indicates the following for speed change.
1. When speed is zero, neutral gear is on.
2. When speed is between 0 and 20, gear 1 is on.
3. When speed is between 20 and 40, gear 2 is on.
4. When speed is between 40 and 60, gear 3 is on.
5. When speed is between 60 and 80, gear 4 is on.
6. When speed is above 90 the system gives a message to reduce the speed of vehicle.
7. For negative speed, reverse gear is active.
IMPLEMENTATION:
Tools:
The implementation of the automatic gear selector requires the following tools:
 Horizontal slider.
 Meter.
 LED’s.
 Loop control.
 And operator.
 Less than operator.
 Greater than operator.
 Numeric constants.
 Equal to zero operator.
PROCEDURE:
Make a connectionbetweenahorizontal sliderandmeter.Thentake aninputformthe slider
and connect an equal to zero tool to it. From the output of the tool connect the wire to the neutral
gear. Thentake two wiresfromthe sliderandconnect themto greaterand lessthan tool and to the
otherterminalsof boththe tools,connectnumericconstantsthatdefine the range of the gears from
1-4. Then and the outputs from both the tools and connect themin the gears’ input. For the reduce
speed message, take an input from the slider and connect a greater than tool and then connect the
output to the respective LED.
FRONT PANEL:
The front panel of the project is as follows:
BLOCK DIAGRAM:
The block diagram of the project is as follows:
RESULTS:
LAB#09
“IMAGEPROCESSING”
IMAGE:
An image is an artifact that records visual perception. It is a 2D representation of a worldly
thing i.e. objects, human or nature. An image is a visual representation of something.
IMAGE PROCESSING:
The analysis and manipulation of a digital image in order to improve its quality. To perform
anyprocessonanimage inspecialdomainisreferredtoasimageprocessing.Itincludesmovingpixels,
filtering, black and white image, blur, highlight the image.
PIXELS:
A pixel is a basic picture element. It is a point in a graphic image. Any graphical picture or
displayiscomposedof thousandsandmillionsof smallblockscalledpixelswhichare arrangedinrows
andcolumns.Theyare place soclose togetherthattheyappearconnected.The physical size of apixel
depends on the resolution of display or image.
MONOCHROME IMAGE:
A mono-chrome image isanimage thatcontainsonlyone color againsta neutral background
such as a paintingora sketching. Oldgreenscreenmonitors are anexample of monochrome display.
All black and white images are monochrome images but not all monochrome images are black and
white.
The range of pixels for a monochrome image is form 0-255.
RGB IMAGE:
RGB stands for “Red Green Blue”. It represents three hues of light that can be mixed to
produce any othercolor.The mixingof highestintensityof all three colorsproduceswhitelightwhile
the dimmestintensityproducesblackcolor.Anrgbimage isacoloredimage.Itcontainsallthe original
colors.
TRANSFORMATION:
Transformationinimage processingcorrespondstoperforminganyoperationonanimage to
convert it from one representation to another.The operationmay be a simple arithmetic operation
or any complex operation. These operations include rotation, radon transform, fourier transform,
hough transform, image interpolation etc.
IMAGE PROCESSING IN LABVIEW:
Labview contains options to process an image. Therefore images can be processed using
labview. Image processing in labview is somewhat difficult as compared to image processing in
labview. Image processing in labview requires the following tools:
1. File path control.
2. Image data.
3. Read image.
4. New picture.
5. Draw flattened.
6. Unbundle.
7. Reverse 1D array.
 FILE PATH CONTROL: This tool provides the path to the image being processed.
 IMAGEDATA: Thistool revealsthe data containedinanimage suchas pixels,size,depthetc.
 READ IMAGE: This tool reads the image for processing.
 NEW PICTURE: This tool shows the image being read.
 REVERSE 1D ARRAY: This tool reverses the image.
TASK-1:
Process an image using LABView.
FRONT PANEL:
The front panel of the project is as follows:
BLOCK DIAGRAM:
The block diagram for image processing can be drawn as follows:
RESULTS:
IMAGE PROCESSING IN MATLAB:
Image processinginMATLAB ispreferredbecause of ease of itsuse.Ithas itsbuiltinlibraries
that make it easy to use. The commands are easy and self explaining.
The following commands are used to read and show image using MATLAB;
 Imread: This command reads the image. The format of wirting this command is as given
below:
Imread(‘image.jpg/tif/png/jpeg’);
Sometimes it is convenient to store the image in some variable for later processing. The
command is then written as;
X=Imread(‘image.jpg/tif/png/jpeg’);
Where x is some variable.
If the image is not in the workspace of MATLAB, thenthe image isaccessedby providingthe
full path to the image in the argument of the above command as follows;
x=imread('C:UsersdellPicturesCamera RollNew folderflynn.jpg');
 Imshow: Thiscommandshowsthe image.The formatfor writingthiscommandisas follows:
Imshow(‘image.jpg/jpeg/tif/png’);
The following commands are used to increment, decrement or multiply some scalar to the
pixels of an image thus changing its properties;
 Imadd: This command adds some scalar to the pixels of image being processed, thus
increasing the brightness. The format for writing this command is as follows:
Imadd(image.jpg,n);
Where n is the number to be added.
 Imsubtract: Thisnumbersubtractsascalarfromthe pixelsof animage beingprocessedhence
darkeningthe image or in otherwords decreasingthe brightness.The formatfor writingthis
command is as follows:
Imsubtract(image.jpg,n);
Where n is the number to be subtracted.
 Immultiply: This number multiplies some scalar to the pixels of image being processed.This
commandchangesthe intensityof coloursinthe image.The formatforwritingthiscommand
is as follows:
Immultiply(image.jpg,n);
Where n is the number to be multiplied.
TASK-2:
Process an image using MATLAB.
The MATLAB commands for increasing or decreasing the brightness or changing the color
intensitycanbe writtenasfollows.Allthe effectsare plottedinthe same figuretoobserve the effects
clearly.
MATLAB CODE:
The matlab code for processing image can be written as follows:
a=imread('cat.jpg');
c=immultiply(a,20);
d=imsubtract(a,100);
e=flipud(a);
figure(1)
subplot(2,2,1)
imshow(a)
subplot(2,2,2)
imshow(c)
subplot(2,2,3)
imshow(d)
subplot(2,2,4)
imshow(e)
RESULTS:
Executing the above commands generates the following results;
ANALYSIS:
Comparing the results of both the software, it can be observed that both the sofwares are
capable of performing same operations and producing the same results.
LAB#10:
“AUDIOSIGNAL PROCESSING”
AUDIO SIGNAL PROCESSING:
Audio signal processing, sometimes referred to as audio processing, is the intentional
alterationof auditory signals,orsound,oftenthroughan audioeffectoreffectsunit. Asaudiosignals
may be electronically represented in either digital or analog format, signal processing may occur in
either domain. Analog processors operate directly on the electrical signal, while digital processors
operate mathematically on the digital representation of that signal.
.WAV SOUND FILES:
.wav stands for waveform audio file format. It is a Microsoft and IBM audio file format
standard for storing an audio bit stream on PCs. It is an application of the Resource Interchange File
Format(RIFF) bitstreamformatmethodforstoringdatain"chunks",andthusisalsoclosetothe 8SVX
andthe AIFFformatusedon AmigaandMacintoshcomputers,respectively.Itisthe mainformatused
on Windows systemsforrawand typicallyuncompressedaudio.The usual bitstreamencodingisthe
linear pulse-code modulation (LPCM) format.
TASK:
Process a .wav extension sound file using LABVIEW.
TOOLS REQUIRED:
To process a sound signal, in labview, we need following tools:
1. File path control.
2. Sound file (read/write).
3. Index array.
4. Graph.
5. Play waveform.
6. Get waveform.
7. Build waveform.
8. Sound file info.
9. Reciprocal.
10. Numeric indicators.
11. Build array.
PROCEDURE:
Connect the file path control to the path terminal of the sound file read tool.Connect path
out terminal to the index array’s array terminal then take the output from the element terminal.
Connectthisoutputtothe dataterminalof the playwaveform,graphandgetwaveformcomponents.
Connectthe Youtputfromgetwaveformcomponentstothe reverse 1Darrayand dt outputtothe dt
tool. Also take the reciprocal of the dt tool input. Connect a numeric indicator with the reciprocal.
Connectbuildwaveformtothe outputof reverse 1D array. Connectthe playwaveformtoerror in of
anotherpalywaveformandconnectthedataterminalof playwaveform2tothe graphtool.Alsoinput
the outputs of build array and build waveforms to the graph tool.
EXPLANATION:
The file path control tool provides the path to the desired sound file. The sound file is then
readby the soundfile readtool.Thenanarrayisgeneratedcontainingthe elementsof the soundfile.
The soundwave is convertedto1D array data. The original soundwave can be playedusingthe play
waveformtool.Alsothe graphof the waveformcanbe seenusinggraphtool.Thenthe soundwave is
ready to be processed. The desired waveform is then addedinto a get waveform tool and reversed
using the reverse 1D array. The scattered data is then bundled together.
Front panel:
The front panel of the project is as follows:
BLOCK DIAGRAM:
The block diagram of the project is as follows:
RESULTS:
The results of the simulation are as follows:
LAB#11:
“ARITHMATIC OPERATIONS ONSIGNALS”
SIGNAL:
A gesture, action, or sound that is used to convey information or instructions, typically by
prearrangement between the parties concerned.
A detectable physical quantity or impulse (as a voltage, current, or magnetic field
strength) by which messages or information can be transmitted."
"A signal is a function of independent variables that carry some information."
"A signal is a source of information generally a physical quantity which varies with
respect to time, space, temperature like any independent variable"
"A signal is a physical quantity that varies with time, space or any other independent
variable.by which information can be conveyed."
RMS VALUE:
Inmathematics,the rootmeansquare (abbreviatedRMSorrms),alsoknownasthe quadratic
mean, is a statistical measure of the magnitude of a varying quantity. It is especially useful when
variantsare positive andnegative,e.g., sinusoids.Inthe fieldof electrical engineering,the RMSvalue
of a periodic current or voltage is equal to the DC current or voltage that delivers the same average
power to a resistor as the periodic current. The RMS value of a set of values (or a continuous-time
waveform) is the square root of the arithmetic mean of the squares of the original values (or the
square of the function that defines the continuous waveform).
PEAK-PEAK VALUE:
Peak-to-peak (pk-pk) is the difference between the maximum positive and the maximum
negative amplitudes of a waveform. If there is no direct current (DC ) component in an alternating
current (AC ) wave, then the pk-pk amplitude is twice the peak amplitude.For an AC sine wave with
no DC component,the peak-to-peakamplitude isequaltoapproximately 2.828 times the root-mean-
square amplitude. Peak-to-peak values can be expressed for voltage, current , or power
TASK:
Generate different signalsapplyarithmeticoperationsonthem, findtheir parameters or attributes
and indicate it on graph.
TOOLS REQUIRED:
 Simulate signal.
 Waveform graph.
 Amplitude and level measurement.
 Multiply.
 Add.
 Subtract.
TOOLS’ DESCRIPTION:
1. Simulate signal: This tool generates various signals such as sine, cosine, square wave, DC
signal, triangular wave and saw tooth wave. The frequency and amplitude of these waves
can also be controlled by this block. The phase and offset value can also be controlled.
2. Waveform graph: This tool displays the graph of the waveforms that are fed into it.
3. Amplitude and level measurement: This tool calculates different attributes related to the
waveforms. These attributes include RMS value, average value, mean or DC value, positive
peak value, negative peak value, peak-peak value, maximum value, minimum value.
4. Multiply: This tool multiplies the two input waveforms.
5. Subtract: This tool subtracts the input waveforms.
6. Add: This tool adds the two input waveforms.
PROCEDURE:
Collecttwosimulate signal blocksfromtheexpressoptionandconnectthemtothe waveform
graph. Thentake a multiply/add/subtracttool fromarithmeticoptionandinput the both waveforms
intoit.Displaythe outputon the graph and alsoconnectit to the amplitude andlevel measurements
tool.Go intothe parametersof amplitude andmeasurementsblockand checkall the attributesof a
wave and then connect graphs to each of the outputs.
FRONT PANEL:
The front panel of the project is as follows:
BLOCK DIAGRAM:
The block diagram of the project is as follows:
RESULTS:
The results for different mathematical operations on signals yielded the following results.
Multiply:
Multiplicationof triangularandsaw toothwave yieldsthe followingresults.The frequencyof
the triangular wave is 10hz whereas the frequency of the saw tooth wave is 20 hz.
Multiplicationof a triangular and square wave yields the following results. The frequency of
the triangular wave is 10hz whereas the frequency of the square wave is 20 hz.
Add:
The additionof asinusoidal waveandsquare wave yieldsthe followingresults.The frequency
of the sine wave is 10hz whereas the frequency of the square wave is 20 hz.
The addition of a sinusoidal wave and triangular wave yields the following results. The
frequency of the sine wave is 10hz whereas the frequency of the triangular wave is 20 hz.
Subtract:
The subtraction of square wave and saw tooth wave yields the following results. The
frequency of the square wave is 10hz whereas the frequency of the saw tooth wave is 20 hz.
The subtraction of the DC signal and the saw tooth wave gives the following results. The
frequency of saw tooth wave is 20hz.
LAB#12
“NOISE ANDFILTERING”
NOISE:
Noise meansanyunwanted sound.Noise isnot necessarilyrandom.Inelectronics, noise isa
randomfluctuationinanelectrical signal,acharacteristicof all electroniccircuits.Noisegeneratedby
electronicdevicesvariesgreatly,asitcan be producedbyseveral differenteffects.In communication
systems, noise is an error or undesired random disturbance of a useful information signal in a
communicationchannel.The noiseisasummationof unwantedordisturbingenergyfromnatural and
sometimes man-made sources.
TYPES OF NOISE:
There are various types of noise. Some of the types are as follows:
GUASSIAN NOISE:
Gaussiannoise is statistical noise havingaprobabilitydensityfunction (PDF) equal tothat of
the normal distribution,whichisalsoknown as the Gaussiandistribution.Inotherwords, the values
that the noise can take on are Gaussian-distributed.The probability densityfunction of a Gaussian
random variable is given by:
where represents the grey level, the mean value and the standard deviation.
In telecommunications and computer networking, communication channels can be affected
by wideband Gaussian noise coming from many natural sources, such as the thermal vibrations of
atoms in conductors (referred to as thermal noise or Johnson-Nyquist noise), shot noise, black body
radiation from the earth and other warm objects, and from celestial sources such as the Sun.
GUASSIAN WHITE NOISE:
A special case is white Gaussian noise,in whichthe valuesat any pair of timesare identically
distributed andstatisticallyindependent (andhenceuncorrelated).Incommunicationchanneltesting
and modelling, Gaussian noise is used as additive white noise to generate additive white Gaussian
noise.
UNIFORM NOISE:
"Uniform noise" generates a noise sequence having a uniform distribution function with
values ranging from a to b. Its parameters are:
 Length N (in samples)
 Minimum value a
 Maximum value b
The probability of an event occurring in the range from a to b is;
𝟏
𝒃 − 𝒂
POISSON NOISE:
Poisson noise is also called shot noise. Poisson noise is a type of electronic noise which
originates from the discrete nature of electric charge. The term also applies to photon counting in
optical devices, where shot noise is associated with the particle nature of light.
GAMMA NOISE:
The gammadistributionisatwo-parameterfamilyof continuous probabilitydistributions.The
common exponential distribution and chi-squared distribution are special cases of the gamma
distribution. There are three different parameterizations in common use:
1. With a shape parameter k and a scale parameter θ.
2. Witha shape parameterα=k andan inverse scaleparameterβ =1/θ, calledarate parameter.
3. With a shape parameter k and a mean parameter μ = k/β.
In each of these three forms, both parameters are positive real numbers
PERIODIC RANDOM NOISE:
PeriodicRandomNoise (PRN) isa summationof sinusoidal signalswiththe same amplitudes
butwithrandomphases.PRN consistsof all sine waveswithfrequencies thatcanbe representedwith
an integral number of cycles in the requested number of samples.Since PRN containsonly integral-
cycle sinusoids,youdonotneedtowindow PRN before youperformspectralanalysisbecause PRN is
self-windowing and, therefore, has no spectral leakage.
INVERSE F NOISE:
Inverse f noise, also known as flicker noise or 1/f noise, is defined as a signal whose power
spectrumisproportional tothe reciprocal of the frequency.Inverse f noise occursinmanyreal-world
scenarios such as electronics, biological and chemical systems, and oceanography.
BINOMIAL NOISE:
Binomial noise is defined by a binomial distribution. The binomial distribution is a discrete
probability distribution of the number of successes in a sequence of n independent yes or no
experiments;eachof the independentexperimentshasaprobabilityequalto p.Binomialdistribution,
like the Poisson distribution, is discrete.
FILTER:
In signal processing, especiallyelectronics, an algorithm or device for removing parts of a
signal. An electronic filter is an electronic circuit which processes signals, for example to remove
unwanted frequency components.
TYPES OF FILTERS:
There are various types of filters. The common type of filters are as follows:
HIGH PASS FILTERS:
A high-pass filter is an electronic filter that passes signals with a frequency higher than a
certaincutoff frequencyandattenuatessignalswithfrequencieslowerthanthe cutoff frequency.The
amount of attenuation for each frequency depends on the filter design.
LOW PASS FILTERS:
A low-pass filter is a filter that passes signals with a frequency lower than a certain cutoff
frequency and attenuates signals with frequencies higher than the cutoff frequency. The amount of
attenuationforeachfrequencydependsonthe filterdesign.The filterissometimescalleda high-cut
filter,or treble cut filter inaudioapplications. A low-pass filter is the opposite of a high-pass filter.
BAND PASS FILTERS:
A band-pass filter is a device that passes frequencies within a certain range and rejects
(attenuates) frequencies outside that range.
BAND STOP FILTERS:
Also called band-elimination, band-reject, or notch filters. In signal processing,a band-stop
filter or band-rejection filter is a filter that passes most frequencies unaltered, but attenuates those
in a specific range to very low levels. It is the opposite of a band-pass filter. A notch filter is a band-
stop filter with a narrow stop band (high Q factor).
Task:
Take a signal, add noise to it
TOOLS:
The following tools are required to filter noise from a signal.
 Simulate signal.
 Graph.
 Filter.
TOOLS DESCRIPTION:
 Simulate signal: This tool can generate different signals and also contains the option to
produce noise in the signals.
 Graph:Thistool showsthe graphical representationof waveforms,noisesandfilteredsignals.
 Filter: like real time filters, the filter tool in LABview is meant to remove unwanted signals
from the original signal.
FRONT PANEL:
The front panel view of the project is as follows:
BLOCK DIAGRAM:
The block diagram of the project can be developed as follows:
RESULTS:
The results of the simulation are as follows:
Periodic random noise:
Gamma noise:
Poisson noise:
Binomial noise:
Bernoulli noise:
MLS sequence:
Inverse F noise:
ANALYSIS:
In all of the above results, it can be observed that low pass filter, band stop filter and
smoothing filters are producing good results of filtering. The original shape of the signal is not being
regainedbutmuchof the noise isbeingreducedbythesefilters.Allotherfiltersare unable toremove
or filter much noise from the signal. The most appropriate results from the fore mentioned filters is
beingproducedbythe lowpass filter.The reasonis that the noise isa highfrequencysignal whichis
being added to a normal or low frequency signal. So only low pass has the ability to reject the high
frequenciesandpassall the lowfrequenciesefficiently.Sothe resultingwaveformissomewhatcloser
to the original one.

Weitere ähnliche Inhalte

Was ist angesagt?

Scilabisnotnaive
ScilabisnotnaiveScilabisnotnaive
Scilabisnotnaivezan
 
Conditional Control in MATLAB Scripts
Conditional Control in MATLAB ScriptsConditional Control in MATLAB Scripts
Conditional Control in MATLAB ScriptsShameer Ahmed Koya
 
Scilab for real dummies j.heikell - part3
Scilab for real dummies j.heikell - part3Scilab for real dummies j.heikell - part3
Scilab for real dummies j.heikell - part3Scilab
 
Scilab for real dummies j.heikell - part 2
Scilab for real dummies j.heikell - part 2Scilab for real dummies j.heikell - part 2
Scilab for real dummies j.heikell - part 2Scilab
 
Programming basics
Programming basicsProgramming basics
Programming basicsillidari
 
Java căn bản - Chapter6
Java căn bản - Chapter6Java căn bản - Chapter6
Java căn bản - Chapter6Vince Vo
 
C++ control structure
C++ control structureC++ control structure
C++ control structurebluejayjunior
 
Looping statements in Java
Looping statements in JavaLooping statements in Java
Looping statements in JavaJin Castor
 
What is to loop in c++
What is to loop in c++What is to loop in c++
What is to loop in c++03446940736
 
Visula C# Programming Lecture 3
Visula C# Programming Lecture 3Visula C# Programming Lecture 3
Visula C# Programming Lecture 3Abou Bakr Ashraf
 
Loop structures chpt_6
Loop structures chpt_6Loop structures chpt_6
Loop structures chpt_6cmontanez
 

Was ist angesagt? (20)

Scilabisnotnaive
ScilabisnotnaiveScilabisnotnaive
Scilabisnotnaive
 
Chapter 3
Chapter 3Chapter 3
Chapter 3
 
Conditional Control in MATLAB Scripts
Conditional Control in MATLAB ScriptsConditional Control in MATLAB Scripts
Conditional Control in MATLAB Scripts
 
Scilab for real dummies j.heikell - part3
Scilab for real dummies j.heikell - part3Scilab for real dummies j.heikell - part3
Scilab for real dummies j.heikell - part3
 
Scilab for real dummies j.heikell - part 2
Scilab for real dummies j.heikell - part 2Scilab for real dummies j.heikell - part 2
Scilab for real dummies j.heikell - part 2
 
Programming basics
Programming basicsProgramming basics
Programming basics
 
Java Programming: Loops
Java Programming: LoopsJava Programming: Loops
Java Programming: Loops
 
Java căn bản - Chapter6
Java căn bản - Chapter6Java căn bản - Chapter6
Java căn bản - Chapter6
 
Loops
LoopsLoops
Loops
 
C++ control structure
C++ control structureC++ control structure
C++ control structure
 
Looping statements in Java
Looping statements in JavaLooping statements in Java
Looping statements in Java
 
What is to loop in c++
What is to loop in c++What is to loop in c++
What is to loop in c++
 
Visula C# Programming Lecture 3
Visula C# Programming Lecture 3Visula C# Programming Lecture 3
Visula C# Programming Lecture 3
 
Loop control in c++
Loop control in c++Loop control in c++
Loop control in c++
 
Loop structures chpt_6
Loop structures chpt_6Loop structures chpt_6
Loop structures chpt_6
 
Simple Java Programs
Simple Java ProgramsSimple Java Programs
Simple Java Programs
 
Ch6
Ch6Ch6
Ch6
 
C++ control loops
C++ control loopsC++ control loops
C++ control loops
 
Looping in c++
Looping in c++Looping in c++
Looping in c++
 
Infix to postfix conversion
Infix to postfix conversionInfix to postfix conversion
Infix to postfix conversion
 

Ähnlich wie Instrumentation and measurements

Loop and while Loop
Loop and while LoopLoop and while Loop
Loop and while LoopJayBhavsar68
 
Iterative control structures, looping, types of loops, loop working
Iterative control structures, looping, types of loops, loop workingIterative control structures, looping, types of loops, loop working
Iterative control structures, looping, types of loops, loop workingNeeru Mittal
 
csharp repitition structures
csharp repitition structurescsharp repitition structures
csharp repitition structuresMicheal Ogundero
 
Control structures ii
Control structures ii Control structures ii
Control structures ii Ahmad Idrees
 
CMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docx
CMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docxCMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docx
CMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docxmonicafrancis71118
 
PVS-Studio team is about to produce a technical breakthrough, but for now let...
PVS-Studio team is about to produce a technical breakthrough, but for now let...PVS-Studio team is about to produce a technical breakthrough, but for now let...
PVS-Studio team is about to produce a technical breakthrough, but for now let...PVS-Studio
 
A Programmable Calculator Design and implement a programmable calc.pdf
A Programmable Calculator Design and implement a programmable calc.pdfA Programmable Calculator Design and implement a programmable calc.pdf
A Programmable Calculator Design and implement a programmable calc.pdfAlexelectronic1
 
BOTTLE LINE SIMULLATION IN LOGIXPRO
BOTTLE LINE SIMULLATION IN LOGIXPROBOTTLE LINE SIMULLATION IN LOGIXPRO
BOTTLE LINE SIMULLATION IN LOGIXPROMohan Tangudu
 
Repetition, Basic loop structures, Loop programming techniques
Repetition, Basic loop structures, Loop programming techniquesRepetition, Basic loop structures, Loop programming techniques
Repetition, Basic loop structures, Loop programming techniquesJason J Pulikkottil
 
9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docx
9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docx9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docx
9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docxransayo
 

Ähnlich wie Instrumentation and measurements (20)

Loops
LoopsLoops
Loops
 
Loop and while Loop
Loop and while LoopLoop and while Loop
Loop and while Loop
 
Iterative control structures, looping, types of loops, loop working
Iterative control structures, looping, types of loops, loop workingIterative control structures, looping, types of loops, loop working
Iterative control structures, looping, types of loops, loop working
 
Loops c++
Loops c++Loops c++
Loops c++
 
csharp repitition structures
csharp repitition structurescsharp repitition structures
csharp repitition structures
 
Control structures ii
Control structures ii Control structures ii
Control structures ii
 
CMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docx
CMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docxCMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docx
CMIS 102 Hands-On Lab Week 4OverviewThis hands-on lab all.docx
 
PVS-Studio team is about to produce a technical breakthrough, but for now let...
PVS-Studio team is about to produce a technical breakthrough, but for now let...PVS-Studio team is about to produce a technical breakthrough, but for now let...
PVS-Studio team is about to produce a technical breakthrough, but for now let...
 
Lect 3-4 Zaheer Abbas
Lect 3-4 Zaheer AbbasLect 3-4 Zaheer Abbas
Lect 3-4 Zaheer Abbas
 
ES-CH5.ppt
ES-CH5.pptES-CH5.ppt
ES-CH5.ppt
 
Programming in Arduino (Part 2)
Programming in Arduino  (Part 2)Programming in Arduino  (Part 2)
Programming in Arduino (Part 2)
 
Simulink 1.pdf
Simulink 1.pdfSimulink 1.pdf
Simulink 1.pdf
 
A Programmable Calculator Design and implement a programmable calc.pdf
A Programmable Calculator Design and implement a programmable calc.pdfA Programmable Calculator Design and implement a programmable calc.pdf
A Programmable Calculator Design and implement a programmable calc.pdf
 
Using matlab simulink
Using matlab simulinkUsing matlab simulink
Using matlab simulink
 
Using matlab simulink
Using matlab simulinkUsing matlab simulink
Using matlab simulink
 
BOTTLE LINE SIMULLATION IN LOGIXPRO
BOTTLE LINE SIMULLATION IN LOGIXPROBOTTLE LINE SIMULLATION IN LOGIXPRO
BOTTLE LINE SIMULLATION IN LOGIXPRO
 
Plc ppt
Plc pptPlc ppt
Plc ppt
 
Repetition, Basic loop structures, Loop programming techniques
Repetition, Basic loop structures, Loop programming techniquesRepetition, Basic loop structures, Loop programming techniques
Repetition, Basic loop structures, Loop programming techniques
 
9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docx
9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docx9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docx
9 11 25 14 44 6 41 15 57 9 39 16 41 2 58 8 43 12 4.docx
 
Fundamentals of Programming Chapter 7
Fundamentals of Programming Chapter 7Fundamentals of Programming Chapter 7
Fundamentals of Programming Chapter 7
 

Kürzlich hochgeladen

Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxOrlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxMuhammadAsimMuhammad6
 
Employee leave management system project.
Employee leave management system project.Employee leave management system project.
Employee leave management system project.Kamal Acharya
 
Online food ordering system project report.pdf
Online food ordering system project report.pdfOnline food ordering system project report.pdf
Online food ordering system project report.pdfKamal Acharya
 
Tamil Call Girls Bhayandar WhatsApp +91-9930687706, Best Service
Tamil Call Girls Bhayandar WhatsApp +91-9930687706, Best ServiceTamil Call Girls Bhayandar WhatsApp +91-9930687706, Best Service
Tamil Call Girls Bhayandar WhatsApp +91-9930687706, Best Servicemeghakumariji156
 
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 Kuwaitjaanualu31
 
Moment Distribution Method For Btech Civil
Moment Distribution Method For Btech CivilMoment Distribution Method For Btech Civil
Moment Distribution Method For Btech CivilVinayVitekari
 
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 ptxJIT KUMAR GUPTA
 
"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
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiessarkmank1
 
AIRCANVAS[1].pdf mini project for btech students
AIRCANVAS[1].pdf mini project for btech studentsAIRCANVAS[1].pdf mini project for btech students
AIRCANVAS[1].pdf mini project for btech studentsvanyagupta248
 
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 leapRishantSharmaFr
 
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.pptxSCMS School of Architecture
 
Wadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptxWadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptxNadaHaitham1
 
kiln thermal load.pptx kiln tgermal load
kiln thermal load.pptx kiln tgermal loadkiln thermal load.pptx kiln tgermal load
kiln thermal load.pptx kiln tgermal loadhamedmustafa094
 
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...Call Girls Mumbai
 
Computer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to ComputersComputer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to ComputersMairaAshraf6
 
Verification of thevenin's theorem for BEEE Lab (1).pptx
Verification of thevenin's theorem for BEEE Lab (1).pptxVerification of thevenin's theorem for BEEE Lab (1).pptx
Verification of thevenin's theorem for BEEE Lab (1).pptxchumtiyababu
 

Kürzlich hochgeladen (20)

Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptxOrlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
Orlando’s Arnold Palmer Hospital Layout Strategy-1.pptx
 
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
 
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak HamilCara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
Cara Menggugurkan Sperma Yang Masuk Rahim Biyar Tidak Hamil
 
Employee leave management system project.
Employee leave management system project.Employee leave management system project.
Employee leave management system project.
 
Online food ordering system project report.pdf
Online food ordering system project report.pdfOnline food ordering system project report.pdf
Online food ordering system project report.pdf
 
Tamil Call Girls Bhayandar WhatsApp +91-9930687706, Best Service
Tamil Call Girls Bhayandar WhatsApp +91-9930687706, Best ServiceTamil Call Girls Bhayandar WhatsApp +91-9930687706, Best Service
Tamil Call Girls Bhayandar WhatsApp +91-9930687706, Best Service
 
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
 
Moment Distribution Method For Btech Civil
Moment Distribution Method For Btech CivilMoment Distribution Method For Btech Civil
Moment Distribution Method For Btech Civil
 
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
 
"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"
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and properties
 
AIRCANVAS[1].pdf mini project for btech students
AIRCANVAS[1].pdf mini project for btech studentsAIRCANVAS[1].pdf mini project for btech students
AIRCANVAS[1].pdf mini project for btech students
 
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
 
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced LoadsFEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
 
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
 
Wadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptxWadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptx
 
kiln thermal load.pptx kiln tgermal load
kiln thermal load.pptx kiln tgermal loadkiln thermal load.pptx kiln tgermal load
kiln thermal load.pptx kiln tgermal load
 
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
 
Computer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to ComputersComputer Lecture 01.pptxIntroduction to Computers
Computer Lecture 01.pptxIntroduction to Computers
 
Verification of thevenin's theorem for BEEE Lab (1).pptx
Verification of thevenin's theorem for BEEE Lab (1).pptxVerification of thevenin's theorem for BEEE Lab (1).pptx
Verification of thevenin's theorem for BEEE Lab (1).pptx
 

Instrumentation and measurements

  • 1.
  • 2. “LIST OF LABS” 1. Implementing simple calculator in labview. 2. Computing formulas in labview. 3. Loops and if statements. 4. Implementing tables in labview. 5. Automatic lights switching in labview. 6. Traffic lights control in labview. 7. Water level control. 8. Automatic gear selector. 9. Image processing. 10.Audio signal processing. 11.Arithmetic operations on signals. 12.Noise and filtering.
  • 3. LAB#01 “IMPLEMENTINGSIMPLECALCULATORINLABVIEW” TASK: Make a simple calculatorusinglabview. TOOLS:  Numericcontrols.  Numericindicator.  Case structure.  Enum.  Addoperator.  Subtract operator.  Multiplyoperator.  Divide operator.  Square operator.  Square root operator. FRONT PANEL: The front panel of the projectincludesthe: 1. Numeric controls: This tool is used to input numbers to perform different operations on them. 2. Enum: This tool contains list of operations. The user can switch between different options to select operation. 3. Numeric indicator: This tool is used to display results.
  • 4. BLOCK DIAGRAM: The block diagram showsthe developmentstepsof project.The blockdiagramwindow has the: 1. Numericindicators. 2. Case structure. The case structure decidesthe true case ineach operation.The case structure containsthe gain blockfor eachoperation.Thenthe numericindicatorisconnectedatthe otherendtodisplaythe results.The enumselectsthe operationof the user’schoice.
  • 6. LAB#02 “COMPUTINGFORMULAS INLABVIEW” TASK 1: Find the power factor of the following power triangle diagram using labview. The formula for power factor is given as: . P P f A  cos . VI P f VI   . cosP f  TOOLS:  Numeric controls.  Numeric indicators.  Multiply.  Divide.  Cos.  Formula. PROJECT DEVELOPMENT: The project development steps are as follows:
  • 7.
  • 8. FRONT PANEL: The front panel only contains: 1. Numeric Controls: To input the value for V and I to be used in the formula of power factor. 2. Numeric Indicators: To display the results of power factor in each case. The front panel is as follows: BLOCK DIAGRAM: The block diagram contains: 1. Numeric indicators: They show the result of the calculation. 2. Numericcontrols:Theyare usedtoinputthe valuesforvoltage andcurrent.Theyare actually used from the front panel. 3. Gain: There are two types of gain used. One is multiply and other is divide since the calculations require multiplication and division of certain terms. 4. Formula: It is used to build or input some formula that will automaticallybe calculatedand will generate the results. 5. Cos: This element is used to find the cos of some value being input to it.
  • 9. TASK 2: Prove the Pythagoras theorem using labview. Pythagoras theorem states that: “In a right angled trianglethe square of the hypotenuse is equal to the sum of the squares of the other two sides.” 2 2 2 hypotenuse perpendicular base  2 2 hypotenuse perpendicular base  So let us assume a triangle with the following lengths: Base = 3cm Hypotenuse = 5cm Perpendicular = 4cm Then,the labview implementationwillhave the followingarrangement.Square the inputsfor base and perpendicular and add them together and take the square root at the end. The result will give the length of hypotenuse of the given triangle. FRONT PANEL: The projectissimple withtwoinputsandone output.Forinputnumericcontrolsare usedand for out a numeric indicator is used.
  • 10. BLOCK DIAGRAM: The block diagram has the square gain to square the values of base and perpendicular of triangle.Thenthe addgainadds upthe squaredvaluesandfinallythe square rootgaintakesthe root of the end result and sends to the numeric indicator to display. TASK 3: Implement the following temperature conversion formulas in labview. 1. Centigrade to Fahrenheit. 2. Fahrenheit to centigrade. 3. Centigrade to kelvin. The conversion formulas for temperature are as follows: Centigrade to Fahrenheit: 9 32 5 F C  Fahrenheit to Centigrade: 5 ( 32) 9 C F  Centigrade to Kelvin: 273K C 
  • 11. FRONT PANEL: BLOCK DIAGRAM: The block diagram contains the numeric controls for inputting the temperature. The temperature value isbeingfedtoformulablockwhichcontainsthe conversionformulaforeachtype of conversion. Then the result is being displayed on numeric indicator. The conversion for the giveninput of 20 for each type generates the following results when calculated manually using a calculator. 200 C=2930 K 200 F=-6.666660 F 200 C=680 F Comparing the results with labview model, it can be seen that the results are correct.
  • 12. LAB#03 “LOOPSANDIFSTATEMENTSINLABVIEW” LOOPS: Loops are a set of statements whichare to be executedseveral times or are to be repeated again and again with different values. In C++ programming, there are three types of loops, namely; 1. While loop. 2. For loop. 3. Do while loop. WHILE LOOP: The syntax of while loop is; ( ) { ; } while condition code The while loopisusedwhenitisnotsure that whenthe loopisto be stopped.Soa condition is placed in the while condition. The loop continues till the condition in the code is true. When the conditionbecomesfalse,the loopstopsexecution.The codinginsidewhileloopwillneverbe executed if the condition comes to be true. FOR LOOP: The for loop has the following syntax; ( 0; ; ) { ; } for i i x i code     Where i is the loop counter and x is the number of times the loop will be executed. The for loop is used when the number of terms a loop is executed is known. DO WHILE LOOP: The syntax for do while loop is;
  • 13. { ; } ( ); do code while condition The do while loopresemblesthe while loop.The onlydifference isthatthe statementsinside the do while loopwillbe executedatleastonce even if the condition for while is found to be false. LOOPS IN LAB VIEW: The loops used in C++ programming can be implemented in labview via block diagrams. The procedure for implementation is as follows: WHILE LOOP: The block diagram representation of while loop in labview is as given below: This symbol in the diagram of while loop is named to be “loop iteration”.It tells us the number of times a loop has been executed. Thissymbol inthe diagramisthe representationof “loopcondition”.Itdecideswhen the loopis to be stopped.We can create a control withthisconditionsymbol tomanuallycontrol the execution of certain loop. The option of while loop can be found in labview by the following steps; Go tofunctionpaletteandselectthe programmingoption.Thengotostructuresandselectwhileloop.
  • 14. FOR LOOP: The for loop is represented by the following symbol in lab view; Thissymbol isnamedtobe “loopiteration”andfunctionsthe same asincase of while loop. This symbol is named to be “loopcount”. The number of times we want the loop to be executed is fed to this terminal of the loop. The loop executes up to that value. The for loop is found in the labview as follows:
  • 15. IF-ELSE STATEMENT: It is the conditional statement inwhichwe use differentconditionsinsidesame block.The if statement decides which block of statements to enter for execution. The compiler executes the statementsorset of statementswhen ifconditionis foundtrue.If the conditionisfoundto be false, then the else block is executed. The syntax for if statement is as given below: ( ) { ; } { ; } if condition code else code IF-ELSE STATEMENT IN LABVIEW: The if statement in labview is listed as “case structure”. The diagram for case structure is as follows: Bydefault,there are onlytwoconditionseithertrue orfalse.If the requiredconditionisfound true,the true blockis executed.If the conditionisfoundtobe false,the blockinthe falseconditionis executed. This block is named to be “case label”. It is the block in which the conditional cases are added. There is at least one default case for each condition. For each condition, there is a separate block diagram. The input and output is common for each condition. This block is called as “case selector”. This block selects the case to be executed.
  • 16. TASK-1: Usingwhileloopimplementa model inlabviewwhichinputsa randomnumber andthen multiplyit with some nominal temperature and display it on a thermometer scale. FRONT PANEL: The front panel of the model contains a  Thermometer:The thermometershowsthe changesoccurring in temperature on the scale.  Loop Control: The loop control is a manual control which allows to stop the loop whenever wanted. The front panel appears to be as follows: BLOCK DIAGRAM: The block diagram of the model contains:  Random Number: the random number is set of numbers ranging from 0-1. It is found in the following block of elements.
  • 17.  NumericConstant: It isa constantnumber.Itisbeingusedas a multiplicationfactorwiththe random number to range it from 1-10. It is also being used to add the random number with some nominal temperature value.  Gain: Two types of gain are being used. One is multiplication and other is addition.  While Loop: The while loop block executes the function of the block diagram continuously until being interrupted by the control switch which is connected to the loop condition. The block diagram of the model is as follows: RESULTS: The resultsof the abovemodelgenerateaconstantlychangingtemperature rangingfrom 250 -350 .The results are as follows:
  • 18. TASK-2: Multiply two numbers using while loop and determine the number of times the loop has been executed. FRONT PANEL: The front panel of the model has the following blocks:  Loop Control: The loopcontrol isa stopbuttonto stopthe loopexecutionwheneverdesired.  NumericDisplay:One numericdisplaydisplaysthe resultsof the multiplicationof the entered numbers. The other display outputs the results of the number of times the loop has been executed. BLOCK DIAGRAM: The block diagram contains the following:
  • 19.  Numerical Constants: The numerical constants are two numbers being multiplied.  Gain: The gain block is the multiplication of the numbers.  While Loop:The whileloopexecutesthe multiplicationof numbersagainandagain.The block i is connected to the body of while loop and then to the numeric display. RESULTS: The results of the execution are as follows: The numeric 2 is displaying the no of times the loop has executed. TASK-3: Implement the table of 2 and 5 using fro loop in the labview model. FRONT PANEL: The front panel of the model contains:  NumericControl: It controlsthe max value of loopcounter.The loopexecutesthe number of timesthe numberenteredinthisblock.  Array Values: The array values displays the numbers in the for loop.
  • 20. BLOCK DIAGRAM: The block diagram contains the following blocks:  NumericConstant: The numberforwhichthe table isto be displayediswritteninthisblock.  Increment: It increments the value of loop counter.  Gain: It multiplies the number for which the table is to be generated by the number in the loop counter.  Array: It generates an array of numbers.  For Loop: It is usedto execute the same commandagain and againusingdifferentvaluesfor each execution. RESULTS: Table of 2:
  • 21. Table of 5: Task-4: Using case structure implement temperature conversion formulas. FRONT PANEL: The front panel contains:  Enum: Enumprovideslistof optionstobe writtenintoit.Itisusedwhennoof commandsare to be added to the same loop.  Numeric Control: The temperature which is to be converted to other form is written in this block.  Thermometer: It displays the resultant temperature on the scale.
  • 22. BLOCK DIAGRAM: The block diagram contains:  Enum: it allows to add different controls to case structure.  Case Structure: It is the if else statement of labview. In this block the controls for each command are added.  Numeric Control: The temperature to be converted is added in this block.  Formula Block: The formula block contains conversion formula.  Thermometer: The result of conversion are shown on thermometer scale. RESULTS: The results of conversion are as follows:
  • 23.
  • 24. LAB#04 “IMPLEMENTINGTABLESINLABVIEW” TASK-1: Make a calculator using case structure in lab view. FRONT PANEL: The front panel of the project includes the:  Numeric controls: It is used to input numbers for any kind of operation.  Enum: it is used to select operation to be performed on numbers.  Numeric indicator: It is used to display results. BLOCK DIAGRAM: The block diagram shows the development steps of project. The block diagram window has the:  Numeric Control: to input numbers for the operation.  Numeric Indicator: To display the results of operation.  Enum: To select the desired operation.  Case Structure: To decide the true case in each operation.  Case Structure: The case structure decides the true case in each operation. The case structure contains the gain block for each operation. Then the numeric indicator is connectedat the otherendto displaythe results.The enumselectsthe operationof the user’s choice.
  • 26. TASK 2: Implement the tables from 2-5 in labview using case structures and loops. FRONT PANEL: The front panel of the project contains:  NumericControl: It controlsthe max value of loopcounter.The loopexecutesthe numberof times the number entered in this block.  Array Values: The array values displays the numbers in the “for loop”. BLOCK DIAGRAM: The block diagram contains the following blocks:  Numeric Control: Three numeric controls are there: Numeric control 3 contains the numbers of which table is being displayed. Numeric control 4 contains the case value. Numeric control 5 is displaying the value of loop counts.  Increment: It increments the value of loop counter.  Gain: It multiplies the number for which the table is to be generated by the number in the loop counter.  Array: It generates an array of numbers.  For Loop: It is usedto execute the same commandagain and againusingdifferentvalues for each execution.  Case Structure: It is used to decide the correct case for the input number.
  • 27. RESULTS: The result-s of the simulation are as follows: Table of 2: Table of 3: Table of 4:
  • 29. LAB#05 “AUTOMATICLIGHTSSWITCHINGINLABVIEW” LIGHT DETECTING RESISTORS: The lightdetectingresistorsare calledas LDR’s. These are variable resistorswhose resistance decreases with increasing light intensity. This phenomenon is called as photoconductivity. Theyare constructed with high resistance semiconductor material that is why the resistance of LDR’s is very high. The resistance lies in the range of mega-ohms. They are used in light sensing applications. If incident light on a photoresistor exceeds a certain frequency, photons absorbed by the semiconductorgive bound electrons enoughenergytojumpintothe conductionband.The resulting free electronsconductelectricity,therebylowering resistance.The resistance range andsensitivityof a photoresistor can substantially differ among dissimilar devices. Moreover, unique photo resistors may react substantially differently to photons within certain wavelength bands. TASK-1: Implementa project inlabviewwhichturns offthe lightsinthe hoursof daytime andturns them on in the night time. FRONT PANEL: The front panel of the project contains:  Led’s:The LED’s inthe projectare the representationof streetlights.Theyare turnedonand off aftercalculatedperiodof time.  Loop Control: The loopcontrol controlsthe loopexecutionmanually.The loopcanbe stoppedanytime usingthe loopcontrol button. The front panel of the projectisas follows:
  • 30. BLOCK DIAGRAM: The blockdiagram of the projectcontains:  LED’s: The LED’s representstreetlightswhichare tobe controlledautomatically.  Local Variables:They provide control forLED’s.Theycan be usedin“write mode” i.e. commandscan be givento them.Orcan be usedin “read mode” i.e.commandscan be takenfromthem.  Delay: It isa type of clockor timerthatcausesdelayinsome task.If a task isto be performedfora specifictime,thenthistool isusedtocause a delayand performitfor requiredtime.  Flat Sequence:Thistool of labview performsatask insequentialorder.The tasksare performedinasequence inwhichtheyare placedinflatsequence cases.  While Loop:The while loopwill keeponperformingthe taskplacedinside itaslongas required.  Loop Control: itis a manual control for a loop.Loopcan be stoppedata desiredinstant usingthistool. The blockdiagram of the projectis as follows: PROCEDURE: The ideaof streetlightsisthattheyturn onautomaticallyinthe nighthoursandswitchoff by themselvesinthe daytimes.There canbe twoproceduresforcontrollingthe lights. i. By usingLDR’s anddark sensors. ii. Usingsome timercircuitthat turns themonfor some calculatedhoursandturns them off for the restof the time.
  • 31. Implementingthe ideaof timersinlabviewrequiresthe followingprocedure. Let; 2 1sechours  The time from5am-7pm can be consideredtobe the dayhours.They counttotallyas 14 hours.So; 14 7sechours  The rest of the hoursfrom7pm-5am can be consideredtobe the nighttime whichare 10 hoursin total.So, 10 5sechours   Step-1: Create local variable witheachLED.Connectthe local variable withthe LED. Covert the local variable to reading mode.  Step-2: Create twoblocksof the flatsequence tool andplace the local variablesinsidethe flatsequence andsetthe local variablesto writingmode.  Step-3: Create constantswithlocal variables.Inthe firstblockof flatsequence setthe local variable totrue case i.e.LEDs will turnon.Inthe secondblockof flatsequence,setthe local variablestofalse case i.e LED’swill turnoff.  Step-4: Selectadelayfromtimersandplace one each ineach blockof flatsequence. Create a constant witheachtimerandwrite the desiredunitsof time ineachconstant.  Step-5: Simulate the project. The simulation results are as follows:
  • 32. TASK-2: Using the idea of delays, make a project in labview that controls the lightning system of a house. FRONT PANEL: The front panel of the project has the following tools:  LED’s.  Loop control. The loop controls is a manual control for stopping the loop at the desired time. The three LED’s representthe lightsof threedifferentareasinahouse.Theyrepresentthelightsof kitchen,TV lounge and outer lights. BLOCK DIAGRAM: The block diagram of the project has the following tools;  LED’s: The LED’s representthe lightsof a certainhouse whichare to be controlled automatically.  Local Variables:They provide control forLED’s.  Delay: thisclocktimerprovidesdelayforturningthe LED’son andoff.  Flat Sequence:Thistool helpstoturnon and turn off the lightsinsequential order.  While Loop:The while loopwill keeponperformingthe taskplacedinside itaslongas required.  Loop Control: It isa manual control fora loop.Loopcan be stoppedat a desiredinstant usingthistool. The blockdiagram of the projectis as follows:
  • 33. PROJECT EXPLANATION: The requirement of the project is that the lights of the kitchen must turn ON by 7pm in the night, the lights of the TV lounge must turn ON by 9pm and the lights of the outer region e.g lawn must turn ON by 12pm in the night and all the lights must turn OFF altogether in the morning by around7AM. The calculatedtime forthese hoursis 5 seconds,4 secondsand 3 seconds respectively. Soeachof the sectioninflat sequence hasthedesireddelayinthe timerandthedesiredlocalvariables are being commanded to turn on or off the respective led’s in the front panel for required time. SIMULATION RESULTS: The results of simulation are as follows:
  • 34.
  • 35. LAB#06 “TRAFFICLIGHTSCONTROL INLABVIEW” TASK: Control the traffic signal lights using delays in labview. PROJECT EXPLANATION: The requirements of the project are that the traffic signal lights must switch from one to anotheraftera calculated periodof time.All the lightsmuststay ON for a short spanof 3-4 minutes. Scaling the time span to sample time; Let, 1min 1sec , 3min 3sec then   So the lights will turn ON for 3 seconds each. FRONT PANEL: The front panel of the project contains the following tools; 1. LED’s 2. Rectangle shape. The front panel view of the project is as given below.
  • 36. BLOCK DIAGRAM: The block diagram of the project contains the following tools; 1. LED’s. 2. Local variables. 3. Flat sequence. 4. While loop. 5. Loop control. 6. Timer.
  • 37. PROCEDURE: Inserta simple rectangularblockinthe blankVIfile.Thencollectthree LED’sand place them inthe project’sfrontpanel.Openthe colorpalletfromthe optionsandchange the colorsof the LED’s toturnthemredgreenandyellowtorepresentthetrafficsignallights.Arrange alltheLED’sinaproper sequence andplace themabove the rectangularbox.Groupall the shapesandtoolstogethersothey don’t move apart. Then open the block diagram and create the local variables associated with each LED. Create fourcopiesofeachLEDandcontainthree copiesinthe three sequencesof aflatsequence. Place a timerin each sequence of the flat sequence andsetthe timerto 3000ms. Containthe whole diagram in the while loop. Create a control with the loop control for manual control of loop. RESULTS: The results of the simulation are as follows:
  • 38. LAB#07 “WATER LEVELCONTROL” TASK: Construct a model in labviewthat controls the water level automaticallysuch that when it reaches the value of about 80% of the total heightofthe tank, the water valve turns offand whenthe water level reaches the minimum value of about 10%, the valve opens up. FRONT PANEL: The front panel of the project contains the following tools. 1. Water tank. 2. Horizontal slider bar. 3. Vertical slider bar. 4. Numeric display. 5. LED’s. 6. Loop control. BLOCK DIAGRAM: The block diagram of the project contain the following tools. 1. Horizontal slider control. 2. Vertical slider control.
  • 39. 3. Numeric constant. 4. Gain. 5. Feedback loop. 6. In-range. 7. Timer. 8. Loop control. 9. While loop. PROCEDURE: Collecta tankfrom the numericindicators.CollecttwoLED’sthat indicate the full andempty level of the tank.Change the color of the LED indicatingfull leveltogreenand the one indicatingthe empty level by red. Collect a horizontal and a vertical slide bars and place the along the tank. Name the horizontal slide bar as inflow and the vertical slide bar as outflow. When the inflow slide bar is full,the tank intakeswaterand fillsup.Whenthe outflow slide baris full,the tank dischargeswater and becomes empty. Openthe blockdiagram of the projectand subtract the value inthe outflow fromthe inflow. Then create a feedback loop and connect the results from the subtraction with the feedback loop througha tool named“in range”. Connecttwonumericconstantswitheach terminal of the in range and set the range from 0-100. Connect the output to the tank. Connect two gains with each LED in blockdiagram,one gaincomparesthe lessthanandequal valueandothercomparesgreaterthanand equal value. Connect the output from each LED to the tank. Simulate the project. RESULTS: The results of the simulation are as follows:
  • 40.
  • 41. LAB#08 “AUTOMATIC GEARSELECTOR” SPEEDOMETER: A speedometer or a speed meter is a gauge that measures and displays the instantaneous speedof a vehicle.Nowuniversallyfittedtomotorvehicles,theystartedtobe available asoptionsin the 1900s, and as standard equipment from about 1910 onwards. Speedometers for other vehicles have specificnamesanduse othermeansof sensingspeed.Foraboat,thisisa pit log.Foran aircraft, this is an airspeed indicator. BRAKES: A brake is a mechanical device whichinhibitsmotion,slowingorstoppinga movingobjector preventing its motion.The rest of this article is dedicated to varioustypes of vehicular brakes.Most commonlybrakesuse frictionbetweentwosurfacespressedtogethertoconvertthe kineticenergyof the moving object into heat, though other methods of energy conversion may be employed. For example regenerative brakingconvertsmuchof the energytoelectrical energy,whichmaybe stored
  • 42. for later use. Other methods convert kinetic energy into potential energy in such stored forms as pressurized air or pressurized oil. Eddy current brakes use magnetic fields to convert kinetic energy into electric current in the brake disc, fin, or rail, which is converted into heat. Still other braking methods even transform kinetic energy into different forms,for example by transferring the energy to a rotating flywheel. ACCELERATOR: A valve that regulatesthe flowof a fluid,suchas the valve in an internal-combustionengine that controlsthe amount of vaporizedfuel enteringthe cylinders.A leverorpedal controllingsucha valve. AUTOMATIC GEAR SYSTEM: An automatic transmission (also called automatic gearbox) is a type of motor vehicle transmissionthatcan automaticallychange gearratios as the vehicle moves,freeingthe driverfrom having to shift gears manually. Like other transmission systems on vehicles, it allows an internal combustionengine,bestsuitedtorunatarelativelyhighrotationalspeed,toprovidearange of speed and torque outputs necessary for vehicular travel. Electronically controlled transmissions, which appearon some newercars,still use hydraulicstoactuate the clutchesandbands,buteachhydraulic circuitiscontrolledbyanelectricsolenoid.Thissimplifiestheplumbingonthe transmissionandallows for more advanced control schemes.
  • 43. TASK: Implement an automatic gear selector for a car that indicates the following for speed change. 1. When speed is zero, neutral gear is on. 2. When speed is between 0 and 20, gear 1 is on. 3. When speed is between 20 and 40, gear 2 is on. 4. When speed is between 40 and 60, gear 3 is on. 5. When speed is between 60 and 80, gear 4 is on. 6. When speed is above 90 the system gives a message to reduce the speed of vehicle. 7. For negative speed, reverse gear is active. IMPLEMENTATION: Tools: The implementation of the automatic gear selector requires the following tools:  Horizontal slider.  Meter.  LED’s.  Loop control.
  • 44.  And operator.  Less than operator.  Greater than operator.  Numeric constants.  Equal to zero operator. PROCEDURE: Make a connectionbetweenahorizontal sliderandmeter.Thentake aninputformthe slider and connect an equal to zero tool to it. From the output of the tool connect the wire to the neutral gear. Thentake two wiresfromthe sliderandconnect themto greaterand lessthan tool and to the otherterminalsof boththe tools,connectnumericconstantsthatdefine the range of the gears from 1-4. Then and the outputs from both the tools and connect themin the gears’ input. For the reduce speed message, take an input from the slider and connect a greater than tool and then connect the output to the respective LED. FRONT PANEL: The front panel of the project is as follows: BLOCK DIAGRAM: The block diagram of the project is as follows:
  • 46. LAB#09 “IMAGEPROCESSING” IMAGE: An image is an artifact that records visual perception. It is a 2D representation of a worldly thing i.e. objects, human or nature. An image is a visual representation of something. IMAGE PROCESSING: The analysis and manipulation of a digital image in order to improve its quality. To perform anyprocessonanimage inspecialdomainisreferredtoasimageprocessing.Itincludesmovingpixels, filtering, black and white image, blur, highlight the image. PIXELS: A pixel is a basic picture element. It is a point in a graphic image. Any graphical picture or displayiscomposedof thousandsandmillionsof smallblockscalledpixelswhichare arrangedinrows
  • 47. andcolumns.Theyare place soclose togetherthattheyappearconnected.The physical size of apixel depends on the resolution of display or image. MONOCHROME IMAGE: A mono-chrome image isanimage thatcontainsonlyone color againsta neutral background such as a paintingora sketching. Oldgreenscreenmonitors are anexample of monochrome display. All black and white images are monochrome images but not all monochrome images are black and white. The range of pixels for a monochrome image is form 0-255. RGB IMAGE: RGB stands for “Red Green Blue”. It represents three hues of light that can be mixed to produce any othercolor.The mixingof highestintensityof all three colorsproduceswhitelightwhile the dimmestintensityproducesblackcolor.Anrgbimage isacoloredimage.Itcontainsallthe original colors. TRANSFORMATION: Transformationinimage processingcorrespondstoperforminganyoperationonanimage to convert it from one representation to another.The operationmay be a simple arithmetic operation or any complex operation. These operations include rotation, radon transform, fourier transform, hough transform, image interpolation etc.
  • 48. IMAGE PROCESSING IN LABVIEW: Labview contains options to process an image. Therefore images can be processed using labview. Image processing in labview is somewhat difficult as compared to image processing in labview. Image processing in labview requires the following tools: 1. File path control. 2. Image data. 3. Read image. 4. New picture. 5. Draw flattened. 6. Unbundle. 7. Reverse 1D array.  FILE PATH CONTROL: This tool provides the path to the image being processed.  IMAGEDATA: Thistool revealsthe data containedinanimage suchas pixels,size,depthetc.  READ IMAGE: This tool reads the image for processing.  NEW PICTURE: This tool shows the image being read.  REVERSE 1D ARRAY: This tool reverses the image. TASK-1: Process an image using LABView. FRONT PANEL: The front panel of the project is as follows:
  • 49. BLOCK DIAGRAM: The block diagram for image processing can be drawn as follows: RESULTS:
  • 50. IMAGE PROCESSING IN MATLAB: Image processinginMATLAB ispreferredbecause of ease of itsuse.Ithas itsbuiltinlibraries that make it easy to use. The commands are easy and self explaining. The following commands are used to read and show image using MATLAB;  Imread: This command reads the image. The format of wirting this command is as given below: Imread(‘image.jpg/tif/png/jpeg’); Sometimes it is convenient to store the image in some variable for later processing. The command is then written as; X=Imread(‘image.jpg/tif/png/jpeg’); Where x is some variable. If the image is not in the workspace of MATLAB, thenthe image isaccessedby providingthe full path to the image in the argument of the above command as follows; x=imread('C:UsersdellPicturesCamera RollNew folderflynn.jpg');  Imshow: Thiscommandshowsthe image.The formatfor writingthiscommandisas follows: Imshow(‘image.jpg/jpeg/tif/png’); The following commands are used to increment, decrement or multiply some scalar to the pixels of an image thus changing its properties;  Imadd: This command adds some scalar to the pixels of image being processed, thus increasing the brightness. The format for writing this command is as follows:
  • 51. Imadd(image.jpg,n); Where n is the number to be added.  Imsubtract: Thisnumbersubtractsascalarfromthe pixelsof animage beingprocessedhence darkeningthe image or in otherwords decreasingthe brightness.The formatfor writingthis command is as follows: Imsubtract(image.jpg,n); Where n is the number to be subtracted.  Immultiply: This number multiplies some scalar to the pixels of image being processed.This commandchangesthe intensityof coloursinthe image.The formatforwritingthiscommand is as follows: Immultiply(image.jpg,n); Where n is the number to be multiplied. TASK-2: Process an image using MATLAB. The MATLAB commands for increasing or decreasing the brightness or changing the color intensitycanbe writtenasfollows.Allthe effectsare plottedinthe same figuretoobserve the effects clearly. MATLAB CODE: The matlab code for processing image can be written as follows: a=imread('cat.jpg'); c=immultiply(a,20); d=imsubtract(a,100); e=flipud(a); figure(1) subplot(2,2,1) imshow(a) subplot(2,2,2)
  • 52. imshow(c) subplot(2,2,3) imshow(d) subplot(2,2,4) imshow(e) RESULTS: Executing the above commands generates the following results; ANALYSIS: Comparing the results of both the software, it can be observed that both the sofwares are capable of performing same operations and producing the same results.
  • 53. LAB#10: “AUDIOSIGNAL PROCESSING” AUDIO SIGNAL PROCESSING: Audio signal processing, sometimes referred to as audio processing, is the intentional alterationof auditory signals,orsound,oftenthroughan audioeffectoreffectsunit. Asaudiosignals may be electronically represented in either digital or analog format, signal processing may occur in either domain. Analog processors operate directly on the electrical signal, while digital processors operate mathematically on the digital representation of that signal. .WAV SOUND FILES: .wav stands for waveform audio file format. It is a Microsoft and IBM audio file format standard for storing an audio bit stream on PCs. It is an application of the Resource Interchange File Format(RIFF) bitstreamformatmethodforstoringdatain"chunks",andthusisalsoclosetothe 8SVX andthe AIFFformatusedon AmigaandMacintoshcomputers,respectively.Itisthe mainformatused on Windows systemsforrawand typicallyuncompressedaudio.The usual bitstreamencodingisthe linear pulse-code modulation (LPCM) format. TASK: Process a .wav extension sound file using LABVIEW. TOOLS REQUIRED: To process a sound signal, in labview, we need following tools: 1. File path control. 2. Sound file (read/write). 3. Index array. 4. Graph. 5. Play waveform. 6. Get waveform. 7. Build waveform. 8. Sound file info. 9. Reciprocal. 10. Numeric indicators. 11. Build array.
  • 54. PROCEDURE: Connect the file path control to the path terminal of the sound file read tool.Connect path out terminal to the index array’s array terminal then take the output from the element terminal. Connectthisoutputtothe dataterminalof the playwaveform,graphandgetwaveformcomponents. Connectthe Youtputfromgetwaveformcomponentstothe reverse 1Darrayand dt outputtothe dt tool. Also take the reciprocal of the dt tool input. Connect a numeric indicator with the reciprocal. Connectbuildwaveformtothe outputof reverse 1D array. Connectthe playwaveformtoerror in of anotherpalywaveformandconnectthedataterminalof playwaveform2tothe graphtool.Alsoinput the outputs of build array and build waveforms to the graph tool. EXPLANATION: The file path control tool provides the path to the desired sound file. The sound file is then readby the soundfile readtool.Thenanarrayisgeneratedcontainingthe elementsof the soundfile. The soundwave is convertedto1D array data. The original soundwave can be playedusingthe play waveformtool.Alsothe graphof the waveformcanbe seenusinggraphtool.Thenthe soundwave is ready to be processed. The desired waveform is then addedinto a get waveform tool and reversed using the reverse 1D array. The scattered data is then bundled together. Front panel: The front panel of the project is as follows:
  • 55. BLOCK DIAGRAM: The block diagram of the project is as follows: RESULTS: The results of the simulation are as follows:
  • 56. LAB#11: “ARITHMATIC OPERATIONS ONSIGNALS” SIGNAL: A gesture, action, or sound that is used to convey information or instructions, typically by prearrangement between the parties concerned. A detectable physical quantity or impulse (as a voltage, current, or magnetic field strength) by which messages or information can be transmitted." "A signal is a function of independent variables that carry some information." "A signal is a source of information generally a physical quantity which varies with respect to time, space, temperature like any independent variable" "A signal is a physical quantity that varies with time, space or any other independent variable.by which information can be conveyed." RMS VALUE: Inmathematics,the rootmeansquare (abbreviatedRMSorrms),alsoknownasthe quadratic mean, is a statistical measure of the magnitude of a varying quantity. It is especially useful when variantsare positive andnegative,e.g., sinusoids.Inthe fieldof electrical engineering,the RMSvalue of a periodic current or voltage is equal to the DC current or voltage that delivers the same average power to a resistor as the periodic current. The RMS value of a set of values (or a continuous-time waveform) is the square root of the arithmetic mean of the squares of the original values (or the square of the function that defines the continuous waveform). PEAK-PEAK VALUE: Peak-to-peak (pk-pk) is the difference between the maximum positive and the maximum negative amplitudes of a waveform. If there is no direct current (DC ) component in an alternating
  • 57. current (AC ) wave, then the pk-pk amplitude is twice the peak amplitude.For an AC sine wave with no DC component,the peak-to-peakamplitude isequaltoapproximately 2.828 times the root-mean- square amplitude. Peak-to-peak values can be expressed for voltage, current , or power TASK: Generate different signalsapplyarithmeticoperationsonthem, findtheir parameters or attributes and indicate it on graph. TOOLS REQUIRED:  Simulate signal.  Waveform graph.  Amplitude and level measurement.  Multiply.  Add.  Subtract. TOOLS’ DESCRIPTION: 1. Simulate signal: This tool generates various signals such as sine, cosine, square wave, DC signal, triangular wave and saw tooth wave. The frequency and amplitude of these waves can also be controlled by this block. The phase and offset value can also be controlled. 2. Waveform graph: This tool displays the graph of the waveforms that are fed into it. 3. Amplitude and level measurement: This tool calculates different attributes related to the waveforms. These attributes include RMS value, average value, mean or DC value, positive peak value, negative peak value, peak-peak value, maximum value, minimum value. 4. Multiply: This tool multiplies the two input waveforms. 5. Subtract: This tool subtracts the input waveforms. 6. Add: This tool adds the two input waveforms.
  • 58. PROCEDURE: Collecttwosimulate signal blocksfromtheexpressoptionandconnectthemtothe waveform graph. Thentake a multiply/add/subtracttool fromarithmeticoptionandinput the both waveforms intoit.Displaythe outputon the graph and alsoconnectit to the amplitude andlevel measurements tool.Go intothe parametersof amplitude andmeasurementsblockand checkall the attributesof a wave and then connect graphs to each of the outputs. FRONT PANEL: The front panel of the project is as follows: BLOCK DIAGRAM: The block diagram of the project is as follows:
  • 59. RESULTS: The results for different mathematical operations on signals yielded the following results. Multiply: Multiplicationof triangularandsaw toothwave yieldsthe followingresults.The frequencyof the triangular wave is 10hz whereas the frequency of the saw tooth wave is 20 hz.
  • 60. Multiplicationof a triangular and square wave yields the following results. The frequency of the triangular wave is 10hz whereas the frequency of the square wave is 20 hz. Add: The additionof asinusoidal waveandsquare wave yieldsthe followingresults.The frequency of the sine wave is 10hz whereas the frequency of the square wave is 20 hz. The addition of a sinusoidal wave and triangular wave yields the following results. The frequency of the sine wave is 10hz whereas the frequency of the triangular wave is 20 hz.
  • 61. Subtract: The subtraction of square wave and saw tooth wave yields the following results. The frequency of the square wave is 10hz whereas the frequency of the saw tooth wave is 20 hz. The subtraction of the DC signal and the saw tooth wave gives the following results. The frequency of saw tooth wave is 20hz.
  • 62.
  • 63. LAB#12 “NOISE ANDFILTERING” NOISE: Noise meansanyunwanted sound.Noise isnot necessarilyrandom.Inelectronics, noise isa randomfluctuationinanelectrical signal,acharacteristicof all electroniccircuits.Noisegeneratedby electronicdevicesvariesgreatly,asitcan be producedbyseveral differenteffects.In communication systems, noise is an error or undesired random disturbance of a useful information signal in a communicationchannel.The noiseisasummationof unwantedordisturbingenergyfromnatural and sometimes man-made sources. TYPES OF NOISE: There are various types of noise. Some of the types are as follows: GUASSIAN NOISE: Gaussiannoise is statistical noise havingaprobabilitydensityfunction (PDF) equal tothat of the normal distribution,whichisalsoknown as the Gaussiandistribution.Inotherwords, the values that the noise can take on are Gaussian-distributed.The probability densityfunction of a Gaussian random variable is given by: where represents the grey level, the mean value and the standard deviation. In telecommunications and computer networking, communication channels can be affected by wideband Gaussian noise coming from many natural sources, such as the thermal vibrations of atoms in conductors (referred to as thermal noise or Johnson-Nyquist noise), shot noise, black body radiation from the earth and other warm objects, and from celestial sources such as the Sun.
  • 64. GUASSIAN WHITE NOISE: A special case is white Gaussian noise,in whichthe valuesat any pair of timesare identically distributed andstatisticallyindependent (andhenceuncorrelated).Incommunicationchanneltesting and modelling, Gaussian noise is used as additive white noise to generate additive white Gaussian noise. UNIFORM NOISE: "Uniform noise" generates a noise sequence having a uniform distribution function with values ranging from a to b. Its parameters are:  Length N (in samples)  Minimum value a  Maximum value b The probability of an event occurring in the range from a to b is; 𝟏 𝒃 − 𝒂
  • 65. POISSON NOISE: Poisson noise is also called shot noise. Poisson noise is a type of electronic noise which originates from the discrete nature of electric charge. The term also applies to photon counting in optical devices, where shot noise is associated with the particle nature of light. GAMMA NOISE: The gammadistributionisatwo-parameterfamilyof continuous probabilitydistributions.The common exponential distribution and chi-squared distribution are special cases of the gamma distribution. There are three different parameterizations in common use: 1. With a shape parameter k and a scale parameter θ. 2. Witha shape parameterα=k andan inverse scaleparameterβ =1/θ, calledarate parameter. 3. With a shape parameter k and a mean parameter μ = k/β. In each of these three forms, both parameters are positive real numbers PERIODIC RANDOM NOISE: PeriodicRandomNoise (PRN) isa summationof sinusoidal signalswiththe same amplitudes butwithrandomphases.PRN consistsof all sine waveswithfrequencies thatcanbe representedwith an integral number of cycles in the requested number of samples.Since PRN containsonly integral-
  • 66. cycle sinusoids,youdonotneedtowindow PRN before youperformspectralanalysisbecause PRN is self-windowing and, therefore, has no spectral leakage. INVERSE F NOISE: Inverse f noise, also known as flicker noise or 1/f noise, is defined as a signal whose power spectrumisproportional tothe reciprocal of the frequency.Inverse f noise occursinmanyreal-world scenarios such as electronics, biological and chemical systems, and oceanography. BINOMIAL NOISE: Binomial noise is defined by a binomial distribution. The binomial distribution is a discrete probability distribution of the number of successes in a sequence of n independent yes or no experiments;eachof the independentexperimentshasaprobabilityequalto p.Binomialdistribution, like the Poisson distribution, is discrete.
  • 67. FILTER: In signal processing, especiallyelectronics, an algorithm or device for removing parts of a signal. An electronic filter is an electronic circuit which processes signals, for example to remove unwanted frequency components. TYPES OF FILTERS: There are various types of filters. The common type of filters are as follows: HIGH PASS FILTERS: A high-pass filter is an electronic filter that passes signals with a frequency higher than a certaincutoff frequencyandattenuatessignalswithfrequencieslowerthanthe cutoff frequency.The amount of attenuation for each frequency depends on the filter design. LOW PASS FILTERS: A low-pass filter is a filter that passes signals with a frequency lower than a certain cutoff frequency and attenuates signals with frequencies higher than the cutoff frequency. The amount of attenuationforeachfrequencydependsonthe filterdesign.The filterissometimescalleda high-cut filter,or treble cut filter inaudioapplications. A low-pass filter is the opposite of a high-pass filter. BAND PASS FILTERS: A band-pass filter is a device that passes frequencies within a certain range and rejects (attenuates) frequencies outside that range. BAND STOP FILTERS: Also called band-elimination, band-reject, or notch filters. In signal processing,a band-stop filter or band-rejection filter is a filter that passes most frequencies unaltered, but attenuates those
  • 68. in a specific range to very low levels. It is the opposite of a band-pass filter. A notch filter is a band- stop filter with a narrow stop band (high Q factor). Task: Take a signal, add noise to it TOOLS: The following tools are required to filter noise from a signal.  Simulate signal.  Graph.  Filter. TOOLS DESCRIPTION:  Simulate signal: This tool can generate different signals and also contains the option to produce noise in the signals.  Graph:Thistool showsthe graphical representationof waveforms,noisesandfilteredsignals.  Filter: like real time filters, the filter tool in LABview is meant to remove unwanted signals from the original signal. FRONT PANEL: The front panel view of the project is as follows:
  • 69. BLOCK DIAGRAM: The block diagram of the project can be developed as follows: RESULTS: The results of the simulation are as follows:
  • 74. ANALYSIS: In all of the above results, it can be observed that low pass filter, band stop filter and smoothing filters are producing good results of filtering. The original shape of the signal is not being regainedbutmuchof the noise isbeingreducedbythesefilters.Allotherfiltersare unable toremove or filter much noise from the signal. The most appropriate results from the fore mentioned filters is beingproducedbythe lowpass filter.The reasonis that the noise isa highfrequencysignal whichis being added to a normal or low frequency signal. So only low pass has the ability to reject the high frequenciesandpassall the lowfrequenciesefficiently.Sothe resultingwaveformissomewhatcloser to the original one.