In need of a coder's help

 

Please can someone help me create a stochastic cross sound alert, which would make a sound immediately the green line ends above the red line between 45-0 levels and also makes a sound when green ends below the red line between 55-100 levels. With stochastic settings 14,9,9.

Thank you very much.