in reply to numeric values acting funny
Your problem isn't in Perl, but in how numbers are represented.
There's an old rule in numerical analysis:
Never subtract very close values from each otherThe problem, in very basic terms, is that your variables are the value you want, plus or minus some small "epsilon". If you subtract two very close values, all you end up with is ε1 ± ε2; in other words, garbage.
Your best bet is to restructure the formulas so the subtraction isn't necessary.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: numeric values acting funny
by tachyon (Chancellor) on Dec 11, 2004 at 02:09 UTC |