math requires something different than memory, it requires understanding and fluency in its variety of symbolic languages, which can only built with intellectually engaged work.
of course these are rarely static (after all one can learn proofs of theorems without being able to solve any problem), hence the need for the "muscle memory" of how to apply these techniques to the particular patterns.