"scale" numbers?
- From: "saneman" <asd@xxxxxx>
- Date: Sat, 24 May 2008 14:37:53 +0200
Assume that:
v = 1,...n
is a vector containing n real numbers.
Is there some procedure to "scale" all the numbers to lie in the range
[a;b]?
v = 1 2 3 4 5 6 7 8 9 10 11 12;
a = 1;
b = 8;
max_elm = max(v);
s = solve(max_elm/x = b);
frac = 1/s;
v_scaled = (v.*frac)+1
but the result is:
2 2 3 4 4 5
6 6 7 8 8 9
How is this done correctly and does it have a more formal name?
.
- Follow-Ups:
- Re: "scale" numbers?
- From: The Qurqirish Dragon
- Re: "scale" numbers?
- Prev by Date: Re: -- Limit of ratio of consecutive primes = 1 ?
- Next by Date: Re: yeah sure !!!
- Previous by thread: Very simple question/paradox about integrals.
- Next by thread: Re: "scale" numbers?
- Index(es):