Arithmetic Operations
Arithmetic Operations
Prepared by:
Team of Lecturers
Department of Electrical Engineering
Overview
There are such cases where we need to combine two different images altogether.
1
One thing should be taken into
consideration
During the arithmetic operation, ensure that the result does not go beyond the allowed range. If
the result goes beyond, the pixel value is set to the maximum allowed range.
If a particular level is set, the value of each element cannot exceed that level.
2
Image Addition
𝑔 𝑥, 𝑦 = 𝑓1 𝑥, 𝑦 + 𝑘
3
Image Addition
For instance,
10 12 5 7 15 19
+ =
9 14 9 3 18 17
+ 50 =
4
Image Addition
Another example,
+ =
5
Image Subtraction
𝑔 𝑥, 𝑦 = 𝑓1 𝑥, 𝑦 − 𝑘
6
Image Subtraction
For instance,
10 12 5 7 5 5
- =
9 14 9 3 0 11
- 50 =
7
Image Subtraction
Another example,
- =
8
Image Division
9
Image Division
÷ =
10
Image Multiplication
𝑔 𝑥, 𝑦 = 𝑓1 𝑥, 𝑦 𝑥 𝑘
11
Image Multiplication
x =
12
Example
Consider the following 2 x 2, 8 level images A and B. Find out A + B, A – B, A x B, and A/B.
10 12 5 7
A= B=
9 14 9 3
13
References
Sridhar, S. (2016). Digital Image Processing (2nd ed.). Oxford University Press.
Thank You
15