Say I run the following:
PowersRepresentations[4782969,4,2] and it takes about 2 minutes. If I call it again it takes only about 0.0005 seconds.
What determines this? If I was crazy how do I stop this and have it run much longer as in the first call?
Is there a list of functions that do this? Is there a criteria for a built-in function to run faster on subsequent calls?
FullSimplify. The purpose of this, unsurprisingly, is to trade memory usage for running time - that is getting repeated results faster while using a bit more memory in order to provide them quickly. $\endgroup$ClearSystemCache[]might be useful in checking. $\endgroup$