[math-fun] identifying real numbers
REIS-ISHNESS: I think the Ries approach is promising but think it could use more development. (1) I think it needs a better notion of "complexity" or "entropy" of a formula (2) user wants to have more control. Re 1: The correct notion of complexity of a formula is basically this. A formula is a tree (e.g. 4+7*8 has + at root, children 4 and *, grandchildren 7,8). Now one could generate random formulas using a probabilistic tree-generator. But I think you need to use the "correct" probability distribution, based on real-life statistics, where "real life" basically means formulas arising in math books and papers. For example, I think irrational (and especially nonalgebraic) exponents of algebraic numbers basically never happen, and trig(x) happens only for x=rational+rational*pi, and GAMMA(x) only happens for x=rational. [You should keep track as you go of whether current numbers are integer, rational, algebraic, or transcendental.] Now assuming that is accomplished, any given formula-tree has a probability p of getting generated. Say the "entropy" of a formula is log2(1/p) in bits. We want Ries to investigate formulas roughly in order of decreasing p, i.e. increasing entropy. A "remarkably good" formula is one that achieves performance=log2(1/|error|) >> entropy. (Normally I'd expect performance=entropy roughly even for totally meaningless random reals.) It should print out the difference performance-entropy for each output. Re 2: Users often know a lot about what sort of formula is reasonable for their application, and there needs to be some kind of language allowing them to specify their class of formulas, thus modifying the probability distribution on formulas. Special functions are not at all a bad thing, they are a good thing, if controlled. There could be a file of parameters governing the probability distribution, which user could modify. CHEAP TRICKS: Finally, there are some extremely cheap tricks you can do. Given X, compute its regular continued fraction. If terminates, then X is rational. If periodic, then X is a quadratic irrational. It is peanuts to find all the best rational and also all the resulting quadratic-irrat approximations to X that thus-arise. Ditto for a few transformations of X such as ln(X), X/pi. Print out the ones that perform significantly better than happens for random reals. The idea of using PSLQ is harder and usually requires extended precision arithmetic so I do not consider it to be a "cheap" trick. Ries is aimed at avoiding extended precision. I think that is a worthwhile goal since often users are unable to compute their real to high precision. I suspect Ries should dominate the Plouffe "huge library" approach. That is since to consider N formulas, Ries uses memory of order sqrt(N) and compute time of order N*logN. Plouffe uses memory of order N and time of order log(N) but precompute time of order N. I suspect this Ries tradeoff will usually outperform the Plouffe approach on single searches. However, if trying to identify any of a large set of input numbers (almost all unidentifiable), then Plouffe approach should pay off. If trying to identify any of M reals, then Plouffe time M*log(N), beating Ries time M*N*log(N). However, Ries could by intentionally unbalancing its "meet in middle" approach achieve much better performance on the multi-identify problem. -- Warren D. Smith
participants (1)
-
Warren Smith