Calculating Image Sizes
To calculate the size of an image:
File Size (bits) = Width x Height x Channels x Bits per channel
Example 1
For example for a normal 2000 by 3000 color RGB image:
- Width: 2000
- Height: 3000
- Channels: Red, Green, Blue
- Bits per channel: 8 ( 0 to 255)
2000 x 3000 x 3 x 8 = 144,000,000 bits
Convert to Bytes:
144,000,000 / 8 = 18 Megabytes
Calculating Image size example
Example 2
For example for a 2000 by 3000 color Grayscale image:
- Width: 2000
- Height: 3000
- Channels: Grey
- Bits per channel: 8 ( 0 to 255)
2000 x 3000 x 1 x 8 = 48,000,000 bits
Convert to Bytes:
48,000,000 / 8 = 6 Megabytes
Example 3
Example 3
For example for a custom 40 by 30 Black and White Image
- Width: 40
- Height: 30
- Channels: 1 (Black)
- Bits per channel: 1
40 x 30 x 1 x 1 = 120 Bits
Convert to Bytes:
120 / 8 = 15 Bytes
Example 4
For example for a custom 50 x 20 8 bit image
- Width: 40
- Height: 30
- Channels: 1
- Bits per channel: 8 bits per pixel.
50 x 20 x 8 = 8000 bits
8000 / 8 = 1000 bytes
1 Kilobyte
Review: Fill in the Blanks
To calculate the size of an image, the formula used is: = Width x Height x Channels x Bits per channel. For example, for a normal 2000 by 3000 color RGB image where the Width is , Height is , Channels are Red, Green, Blue, and Bits per channel are (ranging from 0 to 255), the calculation would be 2000 x 3000 x 3 x 8, resulting in bits. When converted to bytes, this gives us 144,000,000 divided by 8, which equals .
In another scenario, for a 2000 by 3000 color Grayscale image, where the Width is , Height is , Channels are Grey, and Bits per channel are , the calculation is 2000 x 3000 x 1 x 8, leading to bits. When converted to bytes, 48,000,000 divided by 8 gives us .
In a different example involving a custom 40 by 30 Black and White image, the Width is , Height is , Channels are 1 (Black), and Bits per channel are . The calculation results in 40 x 30 x 1 x 1, which equals . When we convert this to bytes, 120 divided by 8 gives us .
For yet another example with a custom 50 by 20 8-bit image, the Width is , Height is , Channels are , and Bits per channel is . The computing would be 50 x 20 x 8, which equals . When converted into bytes, 8000 divided by 8 results in , which is equivalent to .
In another scenario, for a 2000 by 3000 color Grayscale image, where the Width is , Height is , Channels are Grey, and Bits per channel are , the calculation is 2000 x 3000 x 1 x 8, leading to bits. When converted to bytes, 48,000,000 divided by 8 gives us .
In a different example involving a custom 40 by 30 Black and White image, the Width is , Height is , Channels are 1 (Black), and Bits per channel are . The calculation results in 40 x 30 x 1 x 1, which equals . When we convert this to bytes, 120 divided by 8 gives us .
For yet another example with a custom 50 by 20 8-bit image, the Width is , Height is , Channels are , and Bits per channel is . The computing would be 50 x 20 x 8, which equals . When converted into bytes, 8000 divided by 8 results in , which is equivalent to .
Click the keywords below to fill in the blanks:
3000
120 Bits
1000 Bytes
18 Megabytes
File Size (Bits)
15 Bytes
8
50
144,000,000
48,000,000
1
8
2000
20
8
2000
1 Kilobyte
8000 Bits
1
6 Megabytes
3000
30
40
✓ All blanks filled correctly! Great job!
Complete! Ready to test your knowledge?
Introduction to Calculating file sizes
- Calculating Image Sizes
- Calculating Image size example
- Example 3
- Example 4