Wow, compared to all these typical "MACD-zero-line cross" and MA-crossover" related threads, this is really something different... :D
Just out of curiosity - what's your background ? This is certainly not high school math on the Wolfram website...
Regards