Optimisation of electro discharge machining parameters