Predictive Harmonic Cancellation Using Neural Networks