I'm reading opencv tutorials and I'm diving into histogram equalization. i have looked in wikipedia, there is a nice example that sums up exactly the problem:
original:

equalized:

but for getting this result i would take a different approach:
find the minimum and maximum in the original
normalize (remap) everything upon it.
no histogram, no cumulative distribution function. for sure a more stupid approach but i can't see the difference.. why use histogram equalization? can someone can help me in make the reason out?

