用到的z变换的性质:
继续解题:
上代码:
b = [0,0,0, 0.25, -0.5, 0.0625]; a = [1, -1, 0.75, -0.25, 0.0625]; % polynomials coefficients [delta,n] = impseq(0, 0, 7); figure('NumberTitle', 'off', 'Name', 'Example4.6 Impulse Sequence') set(gcf,'Color','white'); %subplot(2,1,1); stem(n,delta); title('Impulse sequence '); xlabel('n'); ylabel('delta(n)'); grid on; x_check_sequence = filter(b, a, delta); % check sequence x_ori_seq = [(n-2) .* (1/2) .^ (n-2) .* cos(pi*(n-2)/3)] .* stepseq(2, 0, 7); % original sequence
运行结果: