diff --git a/caimira/models.py b/caimira/models.py index f23298f8..4a96be97 100644 --- a/caimira/models.py +++ b/caimira/models.py @@ -527,7 +527,7 @@ class Mask: η_inhale: _VectorisedFloat #: Filtration efficiency of masks when exhaling. - η_exhale: _VectorisedFloat = 0. + η_exhale: typing.Union[None, _VectorisedFloat] = None #: Global factor applied to filtration efficiency of masks when exhaling. factor_exhale: float = 1. @@ -544,9 +544,8 @@ class Mask: the leakage through the sides. Diameter is in microns. """ - if self.η_exhale is not 0.: - # For cloth mask we simply return its exhale efficiency distribution value. - # Ref: https://doi.org/10.1080/02786826.2021.1890687 + if self.η_exhale is not None: + # When η_exhale is specified, return it directly return self.η_exhale d = np.array(diameter) @@ -579,8 +578,8 @@ Mask.types = { η_inhale=0.865, # (94% penetration efficiency + 8% max inward leakage -> EN 149) ), 'Cloth': Mask( # https://doi.org/10.1080/02786826.2021.1890687 - η_inhale=0.35, - η_exhale=0.225, + η_inhale=0.225, + η_exhale=0.35, ), } diff --git a/caimira/tests/test_monte_carlo_full_models.py b/caimira/tests/test_monte_carlo_full_models.py index a62cbb9a..9ce540e0 100644 --- a/caimira/tests/test_monte_carlo_full_models.py +++ b/caimira/tests/test_monte_carlo_full_models.py @@ -347,8 +347,8 @@ def test_report_models(mc_model, expected_pi, expected_new_cases, ["Type I", "Jul", 1.663, 0.938, 193.52], ["FFP2", "Jul", 0.523, 0.253, 193.52], ["Type I", "Feb", 0.659, 0.325, 193.52], - ["Cloth", "Feb", 2.665, 1.757, 809.46], - ["Cloth", "Jul", 5.322, 5.086, 798.47], + ["Cloth", "Feb", 2.653, 1.741, 673.10], + ["Cloth", "Jul", 5.322, 5.064, 673.10], ], ) def test_small_shared_office_Geneva(mask_type, month, expected_pi,