Analysis of the energy and economic impact of cost-optimal buildings refurbishment on district heating systems