Anda di halaman 1dari 12

VIRTUAL INSTRUMENTATION

TUTORIAL-2
By
ARPAN GAYEN
ENROLLMENT NO- 14115023

DEPARTMENT OF ELECRICAL ENGINEERING


INDIAN INSTITUTE OF TECHNOLOGY ROORKEE
ROORKEE – 247667 (INDIA)
− −
( ) (− )( ( )− )
= ;
Q1) Design a VI to realize the filter transfer function ( ) − ( )

+

where = using feedback node. Do the performance verification by supplying the suitable input.

Solution) Converting the above filter transfer function to discrete domain we get

[]=1+2 ( ) [ − 1] − [ − 2] + ( [ ] − [ − ]) ( ) − [ − 1] + [ − − 1]

The value of N is taken to be 128. Now with the help of feedback node the filter
transfer function is evaluated.

The corresponding front panel and the block diagram are shown below

Figure 1: Front Panel


− =( )
( ) − ( ) − −

Figure 2: Block Diagram

Q2) Design a moving average using shift register and feedback node.
Test the performance of the VI with suitable inputs.

Solution) Converting the above filter transfer function to discrete domain we get
[ ] = [ − 1] +
1 ( [ ] − [ − ])
The value of N is taken to be 128. Now with the help of feedback node the filter
transfer function is evaluated.

The corresponding front panel and the block diagram are shown below
Figure 3: Front Panel

Figure 4: Block Diagram

Q3) Create a VI to generate N number of random numbers. Set the threshold and
separate the numbers which are greater than the threshold.

Solution) The corresponding front panel and the block diagram are shown below
Figure 5: Front Panel

Figure 6: Block Diagram

Q4) Build a VI to find the roots of a quadratic equation, for all possible combination of
roots.

Solution) The corresponding front panel and the block diagram are shown below
Figure 7: Front Panel

Figure 8: Block Diagram

Q5) Build a VI to generate sine waveform with options to vary the amplitude, number of cycles per second, offset, , number of points in a waveform and ∆ .

Solution) The corresponding front panel and the block diagram are shown below

Figure 9: Front Panel


Figure 10: Block Diagram

Q6) Design a function generator VI to generate waveforms of sine wave, triangular wave,
saw tooth waveform, square waveform, amplitude modulated waveform, and
frequency modulated waveforms, AM and FM waveforms with parameter controls.

Solution) The corresponding front panel and the block diagram are shown below with
parameter controls.

Figure 11: Front Panel for Sine Wave Generation


Figure 12: Front Panel of triangular wave generation

Figure 13: Front Panel of square wave generation

Figure 14: Front Panel for saw tooth wave generation


Figure 15: Block Diagram for above waveform generation

Figure 16: Front Panel for Modulation Index=0.5, Carrier Frequency=4MHz,


Message Frequency=520 KHz
Figure 17: Front Panel for Modulation Index=0.5, Carrier Frequency=1MHz,
Message Frequency=920 KHz

Figure 18: Block Diagram for Amplitude Modulation


Figure 19: Front Panel for Frequency Modulation

Figure 20: Block Diagram for Frequency Modulation

Anda mungkin juga menyukai