function b=maxmat(a,f);
[r,c]= size(a);
b=a;
for i1=f+1:r-f
	b(i1,:)=max(a(i1-f:i1+f,:)
end
for i1=1,f
	b(i1,:)=b(f,:);
end
for i1=r-f:f
	b(i1,:)=b(r-f,:);
end


