SlideShare a Scribd company logo
clc
clear all
%% LAB REPORT 2
title(' Discrete Time')
x=[2,1,-1,0,1,4,3,5];
n=[-3,-2,-1,0,1,2,3,4];
subplot(3,3,1)
stem(n,x)
%% Unit Sample Sequence
title('UNIT SAMPLE SEQUENCE')
n1=-10:20;
u=[zeros(1,10) 1 zeros(1,20)];
subplot(3,3,2)
stem(n1,u)
%% unit step function
n2=-10:20;
u1=[zeros(1,10) ones(1,21)];
subplot(3,3,3)
stem(n2,u1)
%%Exponential
n3=0:20;
a1=1.2;
x1=a1.^n3;
subplot(3,2,3)
stem(n3,x1)
%%x(n)= e.^(-0.5+(pi/6j))n for 0 = n = 40
n4=0:40;
c4=-(1/2) + (pi/6)*i;
x4=exp(c4*n4);
subplot(3,3,7);
stem(n4,real(x4))
subplot(3,3,8);
stem(n4,imag(x4))

More Related Content

DOCX
Analytic 100
DOC
Prg
DOCX
Stat 101 formulae sheet
DOCX
Segundo Punto
TXT
Newton's method for MATLAB Code
PDF
MATHS SYMBOLS - INVERSE OPERATIONS
PPTX
Inflexion point
Analytic 100
Prg
Stat 101 formulae sheet
Segundo Punto
Newton's method for MATLAB Code
MATHS SYMBOLS - INVERSE OPERATIONS
Inflexion point

Recently uploaded (20)

PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PPTX
Internet of Things (IOT) - A guide to understanding
PPTX
Sustainable Sites - Green Building Construction
PDF
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
PDF
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
PPTX
Geodesy 1.pptx...............................................
PDF
Artificial Superintelligence (ASI) Alliance Vision Paper.pdf
PPTX
UNIT 4 Total Quality Management .pptx
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PDF
Level 2 – IBM Data and AI Fundamentals (1)_v1.1.PDF
PDF
Unit I ESSENTIAL OF DIGITAL MARKETING.pdf
PDF
Categorization of Factors Affecting Classification Algorithms Selection
PPTX
Current and future trends in Computer Vision.pptx
PDF
Well-logging-methods_new................
PPTX
Safety Seminar civil to be ensured for safe working.
PPTX
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PDF
A SYSTEMATIC REVIEW OF APPLICATIONS IN FRAUD DETECTION
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PDF
Embodied AI: Ushering in the Next Era of Intelligent Systems
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
Internet of Things (IOT) - A guide to understanding
Sustainable Sites - Green Building Construction
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
Geodesy 1.pptx...............................................
Artificial Superintelligence (ASI) Alliance Vision Paper.pdf
UNIT 4 Total Quality Management .pptx
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
Level 2 – IBM Data and AI Fundamentals (1)_v1.1.PDF
Unit I ESSENTIAL OF DIGITAL MARKETING.pdf
Categorization of Factors Affecting Classification Algorithms Selection
Current and future trends in Computer Vision.pptx
Well-logging-methods_new................
Safety Seminar civil to be ensured for safe working.
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
A SYSTEMATIC REVIEW OF APPLICATIONS IN FRAUD DETECTION
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
Embodied AI: Ushering in the Next Era of Intelligent Systems
Ad
Ad

Matlab lab 2

  • 1. clc clear all %% LAB REPORT 2 title(' Discrete Time') x=[2,1,-1,0,1,4,3,5]; n=[-3,-2,-1,0,1,2,3,4]; subplot(3,3,1) stem(n,x) %% Unit Sample Sequence title('UNIT SAMPLE SEQUENCE') n1=-10:20; u=[zeros(1,10) 1 zeros(1,20)]; subplot(3,3,2) stem(n1,u) %% unit step function n2=-10:20; u1=[zeros(1,10) ones(1,21)]; subplot(3,3,3) stem(n2,u1) %%Exponential n3=0:20; a1=1.2; x1=a1.^n3; subplot(3,2,3) stem(n3,x1) %%x(n)= e.^(-0.5+(pi/6j))n for 0 = n = 40 n4=0:40; c4=-(1/2) + (pi/6)*i; x4=exp(c4*n4); subplot(3,3,7); stem(n4,real(x4)) subplot(3,3,8); stem(n4,imag(x4))