in reply to Re^2: Efficient enumeration of pandigital fractions
in thread Efficient enumeration of pandigital fractions

> doesn't mean that i < n/2, it's e

yeah I noticed. :)

> i can't be 1, base/2, base-2 and base-1

Why not base-2 ... could you elaborate?

8 * 12.. = 96.. base-10 ?

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery FootballPerl is like chess, only without the dice

Replies are listed 'Best First'.
Re^4: Efficient enumeration of pandigital fractions
by kikuchiyo (Hermit) on Jul 22, 2018 at 06:20 UTC

    Why not base-2 ... could you elaborate?

    8 * 1234 (the smallest possible denominator) = 9872, which is just 4 away from the largest possible numerator, 9876, so there isn't much wiggle room there. But 8 is already taken, and the next possible combination 9765, is not divisible with 8, and the quotient is less than 1234.

    In general, zyxw...(base/2-1) - (base-2) * 1234...(base/2-1) = base/2 - 1.