Home > other >  Matlab butterworth filter in the reshape function problem
Matlab butterworth filter in the reshape function problem

Time:10-02

I=imread (' C: \ Users \ \ Desktop \ tutu 93725\123. JPG ");
J=imnoise (I, 'salt & amp; Pepper ', 0.01);
Figure (1), imshow (J)
Fn=16000;
Ap=0.1;
As=60;
Wp=2000;
Ws=5000;
% input filter conditionsWPP=wp/(fn/2); WSS=ws/(fn/2); % normalized;
[n, wn]=buttord (WPP, WSS, ap, as); % calculation order cut-off frequency
[b, a]=butter (n, wn); N % calculation molecular order butterworth digital filter system function, the denominator polynomial coefficient vector b, a,
% h=impz (b, a);
II=reshape (I, 1168 * 1058);
Ylt=filter (b, a, double (II));
Yy=reshape (ylt, 1680105 8);
Figure (2),
Imshow (yy)
%/hw, w=freqz (h, 1);
% figure (3), the plot (w/PI, (abs (hw))); The title (' frequency response hw)
Warning: image is too large to display on the screen; Will be displayed in a 67%
In images. Internal. InitSize (line 71)
In imshow (line 309)
Wrong use of reshape
To RESHAPE, please do not change the number of elements,
  • Related