Planning tool for buildings & districts

Optimization model for design calculation

On this page you find a brief documentation of the optimization model used for design and dimensioning in the energy hub module of the nPro tool.

What is the objective function of the optimization?

In every optimization calculation, there is an objective function which is maximized or minimized. In nPro, the total annualized costs, which also include annualized investments, are minimized:

$$\min TAC = C_\text{inv} + C_\text{o&m} + (C_\text{el} - R_\text{el}) + C_\text{ngas} + C_\text{biogas} + C_\text{biom}$$

$$+ (C_\text{dh} - R_\text{dh}) + (C_\text{dc} - R_\text{dc}) + (C_\text{H2} - R_\text{H2}) + C_\text{CO2} $$


  • \(C_\text{inv}\): Annualized investment costs of all technologies
  • \(C_\text{o&m}\): Annual maintenance and repair costs
  • \(C_\text{el}\): Cost of electricity purchased from the power grid
  • \(R_\text{el}\): Feed-in revenues for electricity fed into the power grid
  • \(C_\text{ngas}\): Cost of gas purchased from the gas grid
  • \(R_\text{biogas}\): Costs for biogas purchase
  • \(C_\text{biom}\): Costs for biomass purchase
  • \(C_\text{dh}\): Costs for heat procurement from an (external) heat network
  • \(R_\text{dh}\): Feed-in revenue for heat fed into an (external) heat network
  • \(C_\text{dc}\): Costs for cold procurement from an (external) cooling network
  • \(R_\text{dc}\): Feed-in revenue for cold fed into an (external) cooling network
  • \(C_\text{H2}\): Costs for hydrogen purchase
  • \(R_\text{H2}\): Feed-in revenues for hydrogen
  • \(C_\text{CO2}\): Costs for direct or indirect CO\(_2\) emissions

Boundary conditions and model constraints

A mathematical optimization model, as used in nPro, includes many thousands of equations that represent the physical relationships of the energy system. Some exemplary equations are:

  • Energy balances for all forms of energy: Electricity, heat, high-temperature heat, cold and hydrogen
  • Efficiency equations: (Time-varying) efficiencies define the ratio of incoming and outgoing energy flows for each technology.
  • Capacity constraints: The power output of a plant is limited by its capacity.
  • Storage constraints for batteries, heat and cold storages as well as hydrogen storages.
  • User-defined operating restrictions, which ensure that equipment is operated only during certain months.
The optimization model in the nPro tool makes it possible to select the optimal energy system from thousands of configurations within a few seconds and to calculate a mathematically optimal dimensioning of the systems.

This might also interest you

nPro software

Plan your energy system with nPro!


We inform you about new tool features and services.