ow frequency+high frequency passes in the low pass filter & high pass filter in matlab need code & details
Show older comments
Answers (1)
Image Analyst
on 14 Jun 2013
Try this:
% Low pass 1D signal:
windowWidth = 11; % Or whatever.
kernel = ones(1, windowWidth)/WindowWidth;
lowPassFilteredSignal = conv(signal, kernel, 'same');
% High pass 2D image
kernel = -1 * ones(windowWidth);
middleIndex = int32(floor(windowWidth/2));
kernel(middleIndex , middleIndex) = windowWidth^2-1;
kernel = kernel/windowWidth^2; % Normalize.
highPassImage = conv2(double(grayImage), kernel, 'same');
imshow(highPassImage , []);
Categories
Find more on Fourier Analysis and Filtering in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!