27 lines
481 B
Mathematica
27 lines
481 B
Mathematica
|
close all
|
|||
|
clear
|
|||
|
clc
|
|||
|
disp('====E4_3_10.m====');
|
|||
|
|
|||
|
X=uint8([0 0 50
|
|||
|
50 50 50])
|
|||
|
Y=uint8([0 1 0
|
|||
|
2 3 4])
|
|||
|
Z=imdivide(X,Y)
|
|||
|
|
|||
|
I1=imread('A.bmp');
|
|||
|
I2=imread('B.bmp');
|
|||
|
|
|||
|
I3=rgb2gray(I1);
|
|||
|
I4=rgb2gray(I2);
|
|||
|
I5=imdivide(I3,I4);
|
|||
|
|
|||
|
I6=im2bw(I1);
|
|||
|
I7=im2bw(I2);
|
|||
|
I8=imdivide(I6,I7);
|
|||
|
|
|||
|
subplot(1,4,1),imshow(I3),xlabel('(a)ͼA');
|
|||
|
subplot(1,4,2),imshow(I4),xlabel('(b)ͼB');
|
|||
|
subplot(1,4,3),imshow(I5),xlabel('(c)<EFBFBD>Ҷ<EFBFBD>ͼ<EFBFBD><EFBFBD>A/B');
|
|||
|
subplot(1,4,4),imshow(I8),xlabel('(d)<EFBFBD><EFBFBD>ֵͼ<EFBFBD><EFBFBD>A/B');
|