Optimisation Methods for Model-Driven Engineering