SlideShare a Scribd company logo
1 of 6
Sargunan Ainal (JKE,PUO)

                                      POLYTECHNIC UNGKU OMAR
                                 ELECTRICAL ENGINEERING DEPARTMENT
Course            :        E5124 DATA COMMUNICATION (Lab work)
Experiment        :        Matlab 3 - Signals in Matlab

Introduction
This lab will describe how to use Matlab for some basic signal representation and manipulation:
         • Creating and importing signals
         • Sampling
         • Signal visualization
         • Modulation

Student must prepare before entering lab session and in your report below items must be included :
       i.      Title
       ii.     Objective
       iii.    Understanding of experiment
       iv.     Observation
       v.      Question & Answer
       vi.     Reflection


Activities
Students need to performe below programing in sequence to obtain result.

1.       Exponential Signal
         Write below source code for below equaltion;

                  Limit for given x is                     and step limit is 0.1
         Hints : source code for exponential is exp( )

1.1.   Write the source code and the output graph line must be in red color.
       Observation
                x = -2*pi:0.1:2*pi;
                y = exp(x);
                plot(x,y,'r')


1.2.   Sketch the result and label the y-axis, x-axis and provide title as given “Exponential 1”.
       Observation




                                                                                                     1
Sargunan Ainal (JKE,PUO)

1.3.   Now, writesource code to produce resultfor below equation.

                  Limit for given x is          and step limit is 0.1

         Observation
                x = 0:0.1:10;
                y = exp(x);
                plot(x,y,'r')




1.4.   Now plot both result in single Figure outcome (use subplot).
       Hints : use suubplot and label with title your output
       Observation




1.5.   Write the source code used and state your comparison.
       Observation




                                                                        2
Sargunan Ainal (JKE,PUO)


2. Pulse Amplitude Modulation (PAM)
    Procedure:
    a. Launch the Matlab program (click Matlab icon)
    b. Click tab, FILE NEW M-FILE . New window screen will pop out and it looks like notepad. Use it to write below
        source code.
                % Name : fill in your name
                % Reg No. : fill in your reg. no
                % Class : fill in class
                % Sampling frequency 24000 Hz
                % Symbol time interval [s].
                T = 1/8000;
                Fs = 24000;
                % Time vector (sampling intervals) , -5T<1/Fs>5T
                t = -5T:1/Fs:5T;
                % Otherwise, the denominator would be zero at t=0 (or manually set “p(t=0)=1”)
                t = t+1e-10;
                % Roll-off factor
                alfa = 0.5;
                p = (sin(pi*t/T)./(pi*t/T)).*(cos(alfa*pi*t/T)./(1-(2*alfa*t/T).^2));
                % Raised-Cosine FIR filter
                clf;
                plot(ts,p)
                hold on;
                stem(ts,p)
                hold off;

    c. Save the written source code using “PAM.m” name.
    d. At the same window, click tab DEBUG RUN.
       Now the source code will execute and produce result. Check the Matlab main window at Command Window
       prompt, there will be error occurance.
    e. What are the errors and how you solve it?
       Observation
                      t = -5T:1/Fs:5T;        t = -5*T:1/Fs:5*T;
                      plot(ts,p)              plot(t,p);
                      stem(ts,p)              stem(t,p);


    f.   Label x-axis with Time, y-axis with Amplitude and title as PAM Spectrum and state observation
         Observation




    g. Now, change the below parameter
         i.   T = 1/8000 with T=1/2000, record your observation


                                                                                                                  3
Sargunan Ainal (JKE,PUO)
                  Observation




           ii.    Reset the T value to original and change the sampling frequency to 240kHz, record your observation




    h. Why there is clf command in the program and explain it.

         clf deletes from the current figure all graphics objects whose handles are not hidden

    i.   Set back samapling frequency 240kHz to 24kHz. What will happen if the hold on is removed?
         Observation




                                                                                                                       4
Sargunan Ainal (JKE,PUO)
3. Analogue to Digital
3.1.   Wite this source code in M-File.

         n=[0:1/44100:1];
         sine1=sin(2*pi*10.*n)
         sine2=0.5*sin(2*pi*30.*n)
         sine3=0.25*sin(2*pi*50.*n)
         sine4=0.125*sin(2*pi*70.*n)
         sine5=0.0625*sin(2*pi*90.*n)
         figure(1)
         subplot(5,1,1);
         plot(n,sine1);
         subplot(5,1,1);
         plot(n,sine1+sine2);
         plot(n,sine1+sine2+sine3)
         subplot(5,1,4);
         plot(n,sine1+sine2+sine3+sine4);
         subplot(5,1,4)
         plot(n,sine1+sine2+sine3+sine4+sine5)

3.2.   Save the written source code using “ADC” name.
3.3.   Execute RUN command.
3.4.   Now the source code will execute and produce result. Check the Matlab main window at Command Window
       prompt.
3.5.   What are the errors and state your solutions.
       Observation




3.6.   Label x-axis with Number of sample, y-axis with Amplitude and title as Analogue to Digital for each graphical output.
       Observation




3.7.   Now, change the below parameter
       a) sine5=0.0625*sin(2*pi*90.*n) to sine5=0.0625*sin(2*pi*190.*n), record your observation
          Observation




       b) Reset the sine5 value to original and add another one more graph output in your display. Record your
          observation and there will be minor changes between graph sine5 and the new graph.
          Observation




                                                                                                                           5
Sargunan Ainal (JKE,PUO)
3.8.   Remain the 3.7. result.
3.9.   What is the meaning of subplot (5,1,4)?

       ____________________________________________________________________________________

       ____________________________________________________________________________________


3.10. Convert your 6x1 matrices to other form of matrices which more convinent to application.
      Observation




                                                                                                 6

More Related Content

What's hot

Sns pre sem
Sns pre semSns pre sem
Sns pre semprabhatviet
 
Classificationand different algorithm
Classificationand different algorithmClassificationand different algorithm
Classificationand different algorithmSuyashSingh70
 
Finding root of equation (numarical method)
Finding root of equation (numarical method)Finding root of equation (numarical method)
Finding root of equation (numarical method)Rajan Thakkar
 
Lab 9 sem ii_12_13
Lab 9 sem ii_12_13Lab 9 sem ii_12_13
Lab 9 sem ii_12_13alish sha
 
08-09 Chapter numerical integration
08-09  Chapter numerical integration 08-09  Chapter numerical integration
08-09 Chapter numerical integration Dr. Mohammed Danish
 
Lab 3 Multi-Function Gate
Lab 3   Multi-Function GateLab 3   Multi-Function Gate
Lab 3 Multi-Function GateKatrina Little
 
Lab 10 sem ii_12_13
Lab 10 sem ii_12_13Lab 10 sem ii_12_13
Lab 10 sem ii_12_13alish sha
 
Introduction to NumPy for Machine Learning Programmers
Introduction to NumPy for Machine Learning ProgrammersIntroduction to NumPy for Machine Learning Programmers
Introduction to NumPy for Machine Learning ProgrammersKimikazu Kato
 
Derivatives in graphing-dfs
Derivatives in graphing-dfsDerivatives in graphing-dfs
Derivatives in graphing-dfsFarhana Shaheen
 
Ch10 Recursion
Ch10 RecursionCh10 Recursion
Ch10 Recursionleminhvuong
 

What's hot (20)

Sns pre sem
Sns pre semSns pre sem
Sns pre sem
 
Ch9c
Ch9cCh9c
Ch9c
 
Classificationand different algorithm
Classificationand different algorithmClassificationand different algorithm
Classificationand different algorithm
 
K map
K mapK map
K map
 
Ansi c
Ansi cAnsi c
Ansi c
 
Finding root of equation (numarical method)
Finding root of equation (numarical method)Finding root of equation (numarical method)
Finding root of equation (numarical method)
 
Control System Homework Help
Control System Homework HelpControl System Homework Help
Control System Homework Help
 
Lab 9 sem ii_12_13
Lab 9 sem ii_12_13Lab 9 sem ii_12_13
Lab 9 sem ii_12_13
 
Lab 6
Lab 6Lab 6
Lab 6
 
08-09 Chapter numerical integration
08-09  Chapter numerical integration 08-09  Chapter numerical integration
08-09 Chapter numerical integration
 
Dynamic allocation
Dynamic allocationDynamic allocation
Dynamic allocation
 
Lab 3 Multi-Function Gate
Lab 3   Multi-Function GateLab 3   Multi-Function Gate
Lab 3 Multi-Function Gate
 
Lab 10 sem ii_12_13
Lab 10 sem ii_12_13Lab 10 sem ii_12_13
Lab 10 sem ii_12_13
 
Introduction to NumPy for Machine Learning Programmers
Introduction to NumPy for Machine Learning ProgrammersIntroduction to NumPy for Machine Learning Programmers
Introduction to NumPy for Machine Learning Programmers
 
Derivatives in graphing-dfs
Derivatives in graphing-dfsDerivatives in graphing-dfs
Derivatives in graphing-dfs
 
Ch9b
Ch9bCh9b
Ch9b
 
Polish
PolishPolish
Polish
 
Ch9a
Ch9aCh9a
Ch9a
 
Ch10 Recursion
Ch10 RecursionCh10 Recursion
Ch10 Recursion
 
Ch4
Ch4Ch4
Ch4
 

Viewers also liked

Matlab 1
Matlab 1Matlab 1
Matlab 1asguna
 
Matlab 2
Matlab 2Matlab 2
Matlab 2asguna
 
Chapter 3
Chapter 3Chapter 3
Chapter 3asguna
 
Chapter 4
Chapter 4Chapter 4
Chapter 4asguna
 
Part 1 presentation 1
Part 1 presentation 1Part 1 presentation 1
Part 1 presentation 1Gaye AktĂźrk
 
Lecture1 Intro To Signa
Lecture1 Intro To SignaLecture1 Intro To Signa
Lecture1 Intro To Signababak danyal
 
Sns slide 1 2011
Sns slide 1 2011Sns slide 1 2011
Sns slide 1 2011cheekeong1231
 
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...Bilal Amjad
 
Ishiriya Wireless Technologies-MATLAB Data Acquisition
Ishiriya Wireless Technologies-MATLAB Data AcquisitionIshiriya Wireless Technologies-MATLAB Data Acquisition
Ishiriya Wireless Technologies-MATLAB Data Acquisitionbhadrah
 
Data communication lab manual
Data communication lab manualData communication lab manual
Data communication lab manualNafe Singh Yadav
 
Matlab Introduction
Matlab IntroductionMatlab Introduction
Matlab IntroductionDaniel Moore
 
Line coding
Line codingLine coding
Line codingRina Ahire
 
Matlab Introduction
Matlab IntroductionMatlab Introduction
Matlab Introductionideas2ignite
 
Introduction to Digital Image Processing Using MATLAB
Introduction to Digital Image Processing Using MATLABIntroduction to Digital Image Processing Using MATLAB
Introduction to Digital Image Processing Using MATLABRay Phan
 
SlideShare 101
SlideShare 101SlideShare 101
SlideShare 101Amit Ranjan
 

Viewers also liked (16)

Matlab 1
Matlab 1Matlab 1
Matlab 1
 
Matlab 2
Matlab 2Matlab 2
Matlab 2
 
Chapter 3
Chapter 3Chapter 3
Chapter 3
 
Chapter 4
Chapter 4Chapter 4
Chapter 4
 
Dtf matlab 20150319
Dtf matlab 20150319Dtf matlab 20150319
Dtf matlab 20150319
 
Part 1 presentation 1
Part 1 presentation 1Part 1 presentation 1
Part 1 presentation 1
 
Lecture1 Intro To Signa
Lecture1 Intro To SignaLecture1 Intro To Signa
Lecture1 Intro To Signa
 
Sns slide 1 2011
Sns slide 1 2011Sns slide 1 2011
Sns slide 1 2011
 
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
 
Ishiriya Wireless Technologies-MATLAB Data Acquisition
Ishiriya Wireless Technologies-MATLAB Data AcquisitionIshiriya Wireless Technologies-MATLAB Data Acquisition
Ishiriya Wireless Technologies-MATLAB Data Acquisition
 
Data communication lab manual
Data communication lab manualData communication lab manual
Data communication lab manual
 
Matlab Introduction
Matlab IntroductionMatlab Introduction
Matlab Introduction
 
Line coding
Line codingLine coding
Line coding
 
Matlab Introduction
Matlab IntroductionMatlab Introduction
Matlab Introduction
 
Introduction to Digital Image Processing Using MATLAB
Introduction to Digital Image Processing Using MATLABIntroduction to Digital Image Processing Using MATLAB
Introduction to Digital Image Processing Using MATLAB
 
SlideShare 101
SlideShare 101SlideShare 101
SlideShare 101
 

Similar to Matlab 3

Task4output.txt 2 5 9 13 15 10 1 0 3 7 11 14 1.docx
Task4output.txt 2  5  9 13 15 10  1  0  3  7 11 14 1.docxTask4output.txt 2  5  9 13 15 10  1  0  3  7 11 14 1.docx
Task4output.txt 2 5 9 13 15 10 1 0 3 7 11 14 1.docxjosies1
 
Lab manual uoh_ee370
Lab manual uoh_ee370Lab manual uoh_ee370
Lab manual uoh_ee370slatano
 
Digital signal Processing all matlab code with Lab report
Digital signal Processing all matlab code with Lab report Digital signal Processing all matlab code with Lab report
Digital signal Processing all matlab code with Lab report Alamgir Hossain
 
Switch Control and Time Delay - Keypad
Switch Control and Time Delay - KeypadSwitch Control and Time Delay - Keypad
Switch Control and Time Delay - KeypadAriel Tonatiuh Espindola
 
BALLANDBEAM_GROUP7.pptx
BALLANDBEAM_GROUP7.pptxBALLANDBEAM_GROUP7.pptx
BALLANDBEAM_GROUP7.pptxOthmanBensaoud
 
DSP_Lab_MAnual_-_Final_Edition[1].docx
DSP_Lab_MAnual_-_Final_Edition[1].docxDSP_Lab_MAnual_-_Final_Edition[1].docx
DSP_Lab_MAnual_-_Final_Edition[1].docxParthDoshi66
 
BS LAB Manual (1).pdf
BS LAB Manual  (1).pdfBS LAB Manual  (1).pdf
BS LAB Manual (1).pdfssuser476810
 
DSP_Lab_MAnual_-_Final_Edition.pdf
DSP_Lab_MAnual_-_Final_Edition.pdfDSP_Lab_MAnual_-_Final_Edition.pdf
DSP_Lab_MAnual_-_Final_Edition.pdfParthDoshi66
 
More instructions for the lab write-up1) You are not obli.docx
More instructions for the lab write-up1) You are not obli.docxMore instructions for the lab write-up1) You are not obli.docx
More instructions for the lab write-up1) You are not obli.docxgilpinleeanna
 
Answers To Selected Exercises For Fortran 90 95 For Scientists And Engineers
Answers To Selected Exercises For Fortran 90 95 For Scientists And EngineersAnswers To Selected Exercises For Fortran 90 95 For Scientists And Engineers
Answers To Selected Exercises For Fortran 90 95 For Scientists And EngineersSheila Sinclair
 
Mmc manual
Mmc manualMmc manual
Mmc manualUrvi Surat
 
FPGA based BCH Decoder
FPGA based BCH DecoderFPGA based BCH Decoder
FPGA based BCH Decoderijsrd.com
 
Project 2: Baseband Data Communication
Project 2: Baseband Data CommunicationProject 2: Baseband Data Communication
Project 2: Baseband Data CommunicationDanish Bangash
 
DeepXplore: Automated Whitebox Testing of Deep Learning
DeepXplore: Automated Whitebox Testing of Deep LearningDeepXplore: Automated Whitebox Testing of Deep Learning
DeepXplore: Automated Whitebox Testing of Deep LearningMasahiro Sakai
 
Digital electronics k map comparators and their function
Digital electronics k map comparators and their functionDigital electronics k map comparators and their function
Digital electronics k map comparators and their functionkumarankit06875
 
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docxSAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docxanhlodge
 
PID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB ApproachPID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB ApproachWaleed El-Badry
 

Similar to Matlab 3 (20)

Task4output.txt 2 5 9 13 15 10 1 0 3 7 11 14 1.docx
Task4output.txt 2  5  9 13 15 10  1  0  3  7 11 14 1.docxTask4output.txt 2  5  9 13 15 10  1  0  3  7 11 14 1.docx
Task4output.txt 2 5 9 13 15 10 1 0 3 7 11 14 1.docx
 
Lab manual uoh_ee370
Lab manual uoh_ee370Lab manual uoh_ee370
Lab manual uoh_ee370
 
Digital signal Processing all matlab code with Lab report
Digital signal Processing all matlab code with Lab report Digital signal Processing all matlab code with Lab report
Digital signal Processing all matlab code with Lab report
 
Switch Control and Time Delay - Keypad
Switch Control and Time Delay - KeypadSwitch Control and Time Delay - Keypad
Switch Control and Time Delay - Keypad
 
BALLANDBEAM_GROUP7.pptx
BALLANDBEAM_GROUP7.pptxBALLANDBEAM_GROUP7.pptx
BALLANDBEAM_GROUP7.pptx
 
DSP_Lab_MAnual_-_Final_Edition[1].docx
DSP_Lab_MAnual_-_Final_Edition[1].docxDSP_Lab_MAnual_-_Final_Edition[1].docx
DSP_Lab_MAnual_-_Final_Edition[1].docx
 
BS LAB Manual (1).pdf
BS LAB Manual  (1).pdfBS LAB Manual  (1).pdf
BS LAB Manual (1).pdf
 
DSP_Lab_MAnual_-_Final_Edition.pdf
DSP_Lab_MAnual_-_Final_Edition.pdfDSP_Lab_MAnual_-_Final_Edition.pdf
DSP_Lab_MAnual_-_Final_Edition.pdf
 
More instructions for the lab write-up1) You are not obli.docx
More instructions for the lab write-up1) You are not obli.docxMore instructions for the lab write-up1) You are not obli.docx
More instructions for the lab write-up1) You are not obli.docx
 
Answers To Selected Exercises For Fortran 90 95 For Scientists And Engineers
Answers To Selected Exercises For Fortran 90 95 For Scientists And EngineersAnswers To Selected Exercises For Fortran 90 95 For Scientists And Engineers
Answers To Selected Exercises For Fortran 90 95 For Scientists And Engineers
 
Mmc manual
Mmc manualMmc manual
Mmc manual
 
Dsp file
Dsp fileDsp file
Dsp file
 
FPGA based BCH Decoder
FPGA based BCH DecoderFPGA based BCH Decoder
FPGA based BCH Decoder
 
Reconstruction
ReconstructionReconstruction
Reconstruction
 
Project 2: Baseband Data Communication
Project 2: Baseband Data CommunicationProject 2: Baseband Data Communication
Project 2: Baseband Data Communication
 
GE3171-PROBLEM SOLVING AND PYTHON PROGRAMMING LABORATORY
GE3171-PROBLEM SOLVING AND PYTHON PROGRAMMING LABORATORYGE3171-PROBLEM SOLVING AND PYTHON PROGRAMMING LABORATORY
GE3171-PROBLEM SOLVING AND PYTHON PROGRAMMING LABORATORY
 
DeepXplore: Automated Whitebox Testing of Deep Learning
DeepXplore: Automated Whitebox Testing of Deep LearningDeepXplore: Automated Whitebox Testing of Deep Learning
DeepXplore: Automated Whitebox Testing of Deep Learning
 
Digital electronics k map comparators and their function
Digital electronics k map comparators and their functionDigital electronics k map comparators and their function
Digital electronics k map comparators and their function
 
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docxSAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
SAMPLE QUESTIONExercise 1 Consider the functionf (x,C).docx
 
PID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB ApproachPID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB Approach
 

Recently uploaded

Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vĂĄzquez
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024The Digital Insurer
 

Recently uploaded (20)

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 

Matlab 3

  • 1. Sargunan Ainal (JKE,PUO) POLYTECHNIC UNGKU OMAR ELECTRICAL ENGINEERING DEPARTMENT Course : E5124 DATA COMMUNICATION (Lab work) Experiment : Matlab 3 - Signals in Matlab Introduction This lab will describe how to use Matlab for some basic signal representation and manipulation: • Creating and importing signals • Sampling • Signal visualization • Modulation Student must prepare before entering lab session and in your report below items must be included : i. Title ii. Objective iii. Understanding of experiment iv. Observation v. Question & Answer vi. Reflection Activities Students need to performe below programing in sequence to obtain result. 1. Exponential Signal Write below source code for below equaltion; Limit for given x is and step limit is 0.1 Hints : source code for exponential is exp( ) 1.1. Write the source code and the output graph line must be in red color. Observation x = -2*pi:0.1:2*pi; y = exp(x); plot(x,y,'r') 1.2. Sketch the result and label the y-axis, x-axis and provide title as given “Exponential 1”. Observation 1
  • 2. Sargunan Ainal (JKE,PUO) 1.3. Now, writesource code to produce resultfor below equation. Limit for given x is and step limit is 0.1 Observation x = 0:0.1:10; y = exp(x); plot(x,y,'r') 1.4. Now plot both result in single Figure outcome (use subplot). Hints : use suubplot and label with title your output Observation 1.5. Write the source code used and state your comparison. Observation 2
  • 3. Sargunan Ainal (JKE,PUO) 2. Pulse Amplitude Modulation (PAM) Procedure: a. Launch the Matlab program (click Matlab icon) b. Click tab, FILE NEW M-FILE . New window screen will pop out and it looks like notepad. Use it to write below source code. % Name : fill in your name % Reg No. : fill in your reg. no % Class : fill in class % Sampling frequency 24000 Hz % Symbol time interval [s]. T = 1/8000; Fs = 24000; % Time vector (sampling intervals) , -5T<1/Fs>5T t = -5T:1/Fs:5T; % Otherwise, the denominator would be zero at t=0 (or manually set “p(t=0)=1”) t = t+1e-10; % Roll-off factor alfa = 0.5; p = (sin(pi*t/T)./(pi*t/T)).*(cos(alfa*pi*t/T)./(1-(2*alfa*t/T).^2)); % Raised-Cosine FIR filter clf; plot(ts,p) hold on; stem(ts,p) hold off; c. Save the written source code using “PAM.m” name. d. At the same window, click tab DEBUG RUN. Now the source code will execute and produce result. Check the Matlab main window at Command Window prompt, there will be error occurance. e. What are the errors and how you solve it? Observation t = -5T:1/Fs:5T; t = -5*T:1/Fs:5*T; plot(ts,p) plot(t,p); stem(ts,p) stem(t,p); f. Label x-axis with Time, y-axis with Amplitude and title as PAM Spectrum and state observation Observation g. Now, change the below parameter i. T = 1/8000 with T=1/2000, record your observation 3
  • 4. Sargunan Ainal (JKE,PUO) Observation ii. Reset the T value to original and change the sampling frequency to 240kHz, record your observation h. Why there is clf command in the program and explain it. clf deletes from the current figure all graphics objects whose handles are not hidden i. Set back samapling frequency 240kHz to 24kHz. What will happen if the hold on is removed? Observation 4
  • 5. Sargunan Ainal (JKE,PUO) 3. Analogue to Digital 3.1. Wite this source code in M-File. n=[0:1/44100:1]; sine1=sin(2*pi*10.*n) sine2=0.5*sin(2*pi*30.*n) sine3=0.25*sin(2*pi*50.*n) sine4=0.125*sin(2*pi*70.*n) sine5=0.0625*sin(2*pi*90.*n) figure(1) subplot(5,1,1); plot(n,sine1); subplot(5,1,1); plot(n,sine1+sine2); plot(n,sine1+sine2+sine3) subplot(5,1,4); plot(n,sine1+sine2+sine3+sine4); subplot(5,1,4) plot(n,sine1+sine2+sine3+sine4+sine5) 3.2. Save the written source code using “ADC” name. 3.3. Execute RUN command. 3.4. Now the source code will execute and produce result. Check the Matlab main window at Command Window prompt. 3.5. What are the errors and state your solutions. Observation 3.6. Label x-axis with Number of sample, y-axis with Amplitude and title as Analogue to Digital for each graphical output. Observation 3.7. Now, change the below parameter a) sine5=0.0625*sin(2*pi*90.*n) to sine5=0.0625*sin(2*pi*190.*n), record your observation Observation b) Reset the sine5 value to original and add another one more graph output in your display. Record your observation and there will be minor changes between graph sine5 and the new graph. Observation 5
  • 6. Sargunan Ainal (JKE,PUO) 3.8. Remain the 3.7. result. 3.9. What is the meaning of subplot (5,1,4)? ____________________________________________________________________________________ ____________________________________________________________________________________ 3.10. Convert your 6x1 matrices to other form of matrices which more convinent to application. Observation 6