Computer-implemented method (20, 200) for controlling an energy system having multiple components connected to one another by means of a multiplicity of buses (31, 32, 33) of the energy system for energy transmission purposes, the components comprising generators (52, 54, 55, 56, 58, 59) and consumers (51, 53, 57), wherein the components are labelled as either non-fixed or fixed, depending on whether their energy operating point is specified, wherein the method comprises: - performing an iteration process via all of the buses of the multiplicity of buses, an iteration for the respectively selected bus respectively comprising: -- attempting to balance a power budget of the selected bus by specifying the energy operating points of components connected to the respective bus that are labelled as non-fixed; -- if the balancing for the respective bus is successful (214, 216): labelling all of the components connected to the respective bus as fixed, and -- if the balancing for the respective bus is not successful (214, 216): converting the label of at least one component connected to the respective bus from fixed to non-fixed, and triggering a fresh iteration for the respective bus, - allocating bus priorities to the buses and performing an iteration process via all of the buses in an order in accordance with the bus priorities, - if the balancing for a selected bus is not successful (214, 216): only the label for those components that are connected to the selected bus only or to the selected bus and a bus having higher bus priority is converted from fixed to non-fixed, and triggering a fresh iteration via one or more buses that have a higher priority than the selected bus and that are connected to the selected bus via a component that is labelled as non-fixed. - performing an iteration process via all of the buses of the multiplicity of buses, an iteration for the respectively selected bus respectively comprising: -- attempting to balance a power budget of the selected bus by specifying the energy operating points of components connected to the respective bus that are labelled as non-fixed; -- if the balancing for the respective bus is successful (214, 216): labelling all of the components connected to the respective bus as fixed, and -- if the balancing for the respective bus is not successful (214, 216): converting the label of at least one component connected to the respective bus from fixed to non-fixed, and triggering a fresh iteration for the respective bus, -- attempting to balance a power budget of the selected bus by specifying the energy operating points of components connected to the respective bus that are labelled as non-fixed; -- if the balancing for the respective bus is successful (214, 216): labelling all of the components connected to the respective bus as fixed, and -- if the balancing for the respective bus is not successful (214, 216): converting the label of at least one component connected to the respective bus from fixed to non-fixed, and triggering a fresh iteration for the respective bus, - allocating bus priorities to the buses and performing an iteration process via all of the buses in an order in accordance with the bus priorities, - if the balancing for a selected bus is not successful (214, 216): only the label for those components that are connected to the selected bus only or to the selected bus and a bus having higher bus priority is converted from fixed to non-fixed, and triggering a fresh iteration via one or more buses that have a higher priority than the selected bus and that are connected to the selected bus via a component that is labelled as non-fixed.