Currently, for example, computing 3^(2^32) takes over 9 minutes just to get to
3^500000.
What can we do to fix this?
Split up exponents, for example:
$$
a^n = \prod_{k=1}^{t} a^t
$$
(note that here, $t$ is the biggest whole number such that $a/t$.)
Store known exponents in a table
i. If we have already computed the value of the exponent, we store the result in a table so we don't have to compute it again
ii. If the exponent is something basic like n^2 or n^3, we can store the value of n^2/n^3 in a table so we don't spend computing power.
Currently, for example, computing
3^(2^32)
takes over 9 minutes just to get to3^500000
.What can we do to fix this?
$$ a^n = \prod_{k=1}^{t} a^t $$
(note that here, $t$ is the biggest whole number such that $a/t$.)
n^2
orn^3
, we can store the value ofn^2
/n^3
in a table so we don't spend computing power.