{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Program_2_2 - stem(n,real(x%Plot the real part xlabel'Time...

Info icon This preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
% Program 2_2 % Generation of complex exponential sequence % a = input('Type in real exponent = '); b = input('Type in imaginary exponent = '); c = a + b*i; K = input('Type in the gain constant = '); N = input ('Type in length of sequence = '); n = 1:N; x = K*exp(c*n);%Generate the sequence
Image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: stem(n,real(x));%Plot the real part xlabel('Time index n');ylabel('Amplitude'); title('Real part'); disp('PRESS RETURN for imaginary part'); pause stem(n,imag(x));%Plot the imaginary part xlabel('Time index n');ylabel('Amplitude'); title('Imaginary part');...
View Full Document

{[ snackBarMessage ]}