OPF Techniques for Real-Time Active Management of Distribution Networks