summaryrefslogtreecommitdiff
path: root/692/CH7/EX7.1/P7_1.sce
blob: 1b08daf96e591570e2d79a5bac14250103980945 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
//EXAMPLE 7.1
//PROGRAM REQUIRES MAXIMA SCILAB TOOLBOX

clc;
clear;
syms K a z w;

hzden = (1-a*(z^-1)); //0<|a|<1;
Hz = K/hzden;
disp('|H(e^(jw))|^2 = K^2/((1+a)^2 - 2*cos(w)') ; 
// considering a>0
disp('(at w = %pi),K^2/(1+a)^2 < |H|^2  < K^2/(1-a)^2,(at w = 0)');
//considering a<0
disp(' (at w = 0),K^2/(1+a)^2 < |H|^2  < K^2/(1-a)^2,(at w = %pi)');
disp('if K = +/-(1-a), observe....');
disp('|H(e^(jw))|  <= 1     Hence a Bounded real function.');
//w=0:%pi;
//[a,b]=freq(hznum,hzden,w);
disp(abs(Hz))