Optimal control of investments for quality of supply improvement in electrical energy distribution networks