Main Content

Image Arithmetic

Add, subtract, multiply, and divide images

Image arithmetic is the implementation of standard arithmetic operations, such as addition, subtraction, multiplication, and division, on images. Image arithmetic has many uses in image processing both as a preliminary step in more complex operations and by itself. For example, image subtraction can be used to detect differences between two or more images of the same scene or object.


imabsdiffAbsolute difference of two images
imaddAdd two images or add constant to image
imapplymatrixLinear combination of color channels
imcomplementComplement image
imdivideDivide one image into another or divide image by constant
imlincombLinear combination of images
immultiplyMultiply two images or multiply image by constant
imsubtractSubtract one image from another or subtract constant from image