Input values I have (4 values) are:
0.00 0.25 0.50 0.75
and for each, respectively, I want this output:
0.50 0.54 0.58 0.62
what's the function for this? I don't know how to pull out the ratio:
a => a * ratio
Input values I have (4 values) are:
0.00 0.25 0.50 0.75
and for each, respectively, I want this output:
0.50 0.54 0.58 0.62
what's the function for this? I don't know how to pull out the ratio:
a => a * ratio
The function is $y=0.50+\frac{x}{0.25}\times 0.04=0.5+0.16x$.
You may use Maple to find the function:
[> with(CurveFitting):
[> PolynomialInterpolation([[0., .50], [.25, .54], [.50, .58], [.75, .62]], x);
0.16 x + 0.50
The linear function $f$ mapping $[a,b]$ onto $[c,d]$ (in that order) is $f(x)=c+(\frac{d-c}{b-a})(x-a)$. This assumes $b\neq a$. This maps the end points correctly, and you can check whether or not the interior points in question are also mapped correctly. If they are, this is your linear function. If they are not, there is no such function.