Define a filiter in Signal Processing Toolbox (SPT) and plot the frequency response
fc = 300;
fs = 1000;
[b,a] = butter(6,fc/(fs/2));
figure
freqz(b,a,[],fs)
Convert to Control System Toolbox (CST) and plot the freqency response. Same as above accounting for 360 deg phase shift.
H = tf(b,a,1/fs,'Variable','z^-1');
figure
opts = bodeoptions;
opts.Freqscale = 'linear';
opts.FreqUnits = 'Hz';
opts.XLim = [0,fs/2];
bodeplot(H,opts),grid
bnew = conv(0.1*[1,-1],b);
figure
freqz(bnew,a,[],fs);
Same thing in the CST. Couldn't force the magnitude plot to have the same lower limit as above. Possible bug?
z = tf('z',1/fs);
figure
opts.MagLowerLimMode = 'manual';
opts.MagLowerLim = -120; % doesn't work? %10^(-120/20) also doesn't work?
bodeplot((0.1 - 0.1/z)*H,opts),grid
Implementing H(z^2) is doable, but I think would involve direct manipulation of b and a for the SPT, or the num and den properties of the tf in the CST (or we could detour into the Symbolic Toolbox I suppose).




