Low Pass Butterworth Filter

by

 

Butterworth filter is a type of filter designed to have a flat frequency response.

butt.m
[M N] = size(img);

filter=zeros(M,N);

d0=10;				%Cutoff Frequency
n=1; 				%Order of butterworth filter

	for i=1:M
    	for j=1:N
        	dist=(i-M/2)^2 + (j-N/2)^2;
        	filter(i,j)= ( 1 + (dist/d0)^(2*n))^(-1);
        
    	end
    end

Contact us