A controller for controlling communication services for a plurality N of applications on a physical network having a plurality M of network nodes providing certain network resources is provided. Each of the N applications is described by a set of requirements and is adapted to run on at least two of the M network nodes. The controller comprises a generator and a calculator. The generator is adapted to generate a network model of the physical network including a topology of the physical network and a node model for each of the M network nodes, wherein the node model describes node capabilities and node resources of the network node. The calculator is adapted to calculate N virtual networks for the N applications by mapping each of the set of requirements of the N applications to the provided network model, wherein each of the N calculated virtual networks includes at least two network nodes and a slice of the certain network resources. By calculating the virtual networks based on the provided network model, the planning of the physical network and its configuration are separated advantageously. Further, a method and a computer program product are provided.