diff --git a/costs/total_operational_incomes.py b/costs/total_operational_incomes.py index 474d26b..f1cab2c 100644 --- a/costs/total_operational_incomes.py +++ b/costs/total_operational_incomes.py @@ -28,15 +28,16 @@ class TotalOperationalIncomes(CostBase): :return: pd.DataFrame """ building = self._building + archetype = self._archetype if cte.YEAR not in building.onsite_electrical_production: onsite_electricity_production = 0 else: - onsite_electricity_production = building.onsite_electrical_production[cte.YEAR][0] / 1000 + onsite_electricity_production = building.onsite_electrical_production[cte.YEAR][0] for year in range(1, self._configuration.number_of_years + 1): price_increase_electricity = math.pow(1 + self._configuration.electricity_price_index, year) # todo: check the adequate assignation of price. Pilar - price_export = 0.075 # archetype.income.electricity_export + price_export = archetype.income.electricity_export * cte.WATTS_HOUR_TO_JULES*1000 # to account for unit change self._yearly_operational_incomes.loc[year, 'Incomes electricity'] = ( onsite_electricity_production * price_export * price_increase_electricity )