A Stochastic Approach to Thermal Modeling Applied to Electro-Discharge Machining