I'm trying to come up with the correct algorithm for a setting on a meter in my app.
Basically, I have a value (lets call it 'x') returned from a source which can be in the range of 0 to 30.
As x goes from 30 to 0, I need y (the output of the algorithm) to go from 0 to 1.0. Basically, as x gets smaller, y needs to get larger but the rates of each are not proportional.