patternCritical
Why is the unit of image size not Pixel²?
Viewed 0 times
whytheimagesizenotpixel²unit
Problem
If you calculate the area of a rectangle, you just multiply the height and the width and get back the unit squared.
Example:
5cm * 10cm = 50cm²
In contrast, if you calculate the size of an image, you also multiply the height and the width, but you get back the unit - Pixel - just as it was the unit of the height and width before multiplying.
Example:
What you actually calculate is the following:
3840 Pixel * 2160 Pixel = 8294400 Pixel
What I would expect is:
3840 Pixel * 2160 Pixel = 8294400 Pixel²
Why is that the unit at multiplying Pixels is not being squared?
Example:
5cm * 10cm = 50cm²
In contrast, if you calculate the size of an image, you also multiply the height and the width, but you get back the unit - Pixel - just as it was the unit of the height and width before multiplying.
Example:
What you actually calculate is the following:
3840 Pixel * 2160 Pixel = 8294400 Pixel
What I would expect is:
3840 Pixel * 2160 Pixel = 8294400 Pixel²
Why is that the unit at multiplying Pixels is not being squared?
Solution
Because "pixel" isn't a unit of measurement: it's an object. So, just like a wall that's 30 bricks wide by 10 bricks tall contains 300 bricks (not bricks-squared), an image that's 30 pixels wide by 10 pixels tall contains 300 pixels (not pixels-squared).
Context
StackExchange Computer Science Q#88057, answer score: 239
Revisions (0)
No revisions yet.