Next generation wavefront controller for the MMT adaptive optics system: Algorithms and techniques for mitigating dynamic wavefront aberrations