This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: pause clf % % perform time domain analysis % use the numerical convolution described in Example 3.10 % for accuracy, choose T <= RC/10 if RC >= .1, T = .01; kh = 0:400; % defines indices for h, % corresponds to t=0 to t=4 h = exp(-1/RC*kh*T)/RC; kx = -60:100; % defines indices for x, % corresponds to t=.6 to t=1 x = [zeros(1,10) ones(1,101) zeros(1,50)]; elseif RC >=0.01, T = 0.001; kh = 0:400; h = exp(-1/RC*kh*T)/RC; kx = -600:1000; x = [zeros(1:100) ones(1,1001) zeros(1,500)]; else, error('RC is too small for accurate results using the numerical convolution method') end y = conv(x,h*T); ky = kx(1)+kh(1):kx(length(kx))+kh(length(kh)); clf subplot(211), plot(ky*T,y) title(['Pulse Response, RC = ' num2str(RC)]) ylabel('y(t)') xlabel('Time (sec)') subplot(111)...
View Full Document
This note was uploaded on 03/24/2010 for the course CENG 4331 taught by Professor Maryrandolph-gips during the Fall '09 term at UH Clear Lake.
- Fall '09