Rejection of Negative Bases; Bug or Deliberate Design?

So your comment applies to every single x < 0 and y ∉ Z argument pair, not just the ones from the example, right?

My (very rusty, somewhat hesitant) reasoning was this: Every non‐integral, rational number that is exactly representable in base 2 will have a denominator that is a power of 2. Placed in the exponent position, such a number represents a power‐of‐2th root. Since powers of 2 are necessarily even, the degree of the root must be even, and thus it can never operate on a negative radicand without leaving leaving the territory of real numbers. That means no such argument pair exits for x < 0 and y ∉ Z where the arguments and return value are all exactly representable in base 2.

1 Like