Smart Grid schemes in which multiple network elements and participants are managed for the benefit of the distribution network (e.g., energy loss reduction, restoration, etc.) require sophisticated algorithms to control them in the most suitable manner while catering for network constraints. Such a complex decision making process can be solved by tailoring the AC Optimal Power Flow (OPF) problem to the corresponding Smart Grid scheme. Non-linear programming AC OPF formulations, however, can suffer from scalability and robustness issues which in turn might limit their adoption. Here, a novel quadratic programming formulation is proposed and compared against the non-linear, quadratically constrained and linearized approaches. Two cases are carried out to assess their performance: (1) management of distributed generation units to maximize renewable energy harvesting (continuous control variables); and, (2) control of capacitors to minimize energy losses (discrete control variables). The results demonstrate that the proposed quadratic approach significantly outperforms the more conventional formulations in both computational efficiency and robustness. This makes it a suitable alternative to be at the heart of the decision making of complex, real-time schemes to be adopted by future Smart distribution networks.