Active network management for improved flexibility in distribution networks