diff --git a/hub/imports/usage/nrcan_usage_parameters.py b/hub/imports/usage/nrcan_usage_parameters.py index 5898f2a0..8073ca67 100644 --- a/hub/imports/usage/nrcan_usage_parameters.py +++ b/hub/imports/usage/nrcan_usage_parameters.py @@ -130,11 +130,16 @@ class NrcanUsageParameters: def _assign_comnet_extra_values(usage, archetype, occupancy_density): _occupancy = usage.occupancy archetype_density = archetype.occupancy.occupancy_density - _occupancy.sensible_radiative_internal_gain = archetype.occupancy.sensible_radiative_internal_gain \ - * occupancy_density / archetype_density - _occupancy.latent_internal_gain = archetype.occupancy.latent_internal_gain * occupancy_density / archetype_density - _occupancy.sensible_convective_internal_gain = archetype.occupancy.sensible_convective_internal_gain \ - * occupancy_density / archetype_density + if archetype_density == 0: + _occupancy.sensible_radiative_internal_gain = 0 + _occupancy.latent_internal_gain = 0 + _occupancy.sensible_convective_internal_gain = 0 + else: + _occupancy.sensible_radiative_internal_gain = archetype.occupancy.sensible_radiative_internal_gain \ + * occupancy_density / archetype_density + _occupancy.latent_internal_gain = archetype.occupancy.latent_internal_gain * occupancy_density / archetype_density + _occupancy.sensible_convective_internal_gain = archetype.occupancy.sensible_convective_internal_gain \ + * occupancy_density / archetype_density @staticmethod def _calculate_reduced_values_from_extended_library(usage, archetype):