Info
この質問は閉じられています。 編集または回答するには再度開いてください。
I have two images taken by projecting laser light onto a agar plate. We have taken images at starting point and after an interval of 20 minutes, where we cultured bacteria on it. Then we applied imsubtract(a,b), (b,a) both giving different answers ?
1 回表示 (過去 30 日間)
古いコメントを表示
a=imread('im5.jpg');
b=imread('im7.jpg');
c=imsubtract(a,b):
imshow(c)
d=imsubtract(b,a);
imshow(d)
after that in the output side we got greenish and red color image. Here we used a red color laser light. My question is, is that greenish color represents bacterial colony or anything else. Why the output is changing after interchanging these a,b to b,a in 'imsubtract' function? Following are the images: mat1 - for imsubtract(a,b) and mat2 - for imsubtract(b,a).
0 件のコメント
回答 (1 件)
KALYAN ACHARJYA
2018 年 12 月 20 日
編集済み: KALYAN ACHARJYA
2018 年 12 月 20 日
Yes, how you expect that both gives the same results?
A-B !=B-A (!=>Not Equal)
Note: Subtraction and division functions are Not Commutative.
In your case
imsubtract(a,b)=a-b
and
imsubtract(b,a)=b-a
Both are not same.
この質問は閉じられています。
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!