clearclcd1=120; d2=94;I =imread('C:\Users\SAMA CENTER\Desktop\girl.jpg');J = imresize(I,[200 250]);X = rgb2gray(I);Y=X';for k1=1:d1for k2=1:d2B(2*k1,k2)=X(k1, k2);B(2*k1-1,k2)=floor((X(k1,k2)+X(2*k1-1,k2))/2);endendimshow(B);
What's wrong with this code?? there is some wrong with the floor function what is it ???
Best Answer