Voltage Mapping

Not able to undstrand this solution.

Maybe the explanition wasn´t the best.

What I´m trying to achieve is the equivalent of the map() function this way:

map(x, 2, 10, 0, 10)
with the values expressed in voltages.