Toilet¶
QSDsan: Quantitative Sustainable Design for sanitation and resource recovery systems
This module is developed by:
Yalin Li <mailto.yalin.li@gmail.com>
Lewis Rowles <stetsonsc@gmail.com>
Lane To <lane20@illinois.edu>
This module is under the University of Illinois/NCSA Open Source License. Please refer to https://github.com/QSD-Group/QSDsan/blob/main/LICENSE.txt for license details.
- class qsdsan.sanunits._toilet.MURT(ID='', ins: Sequence[AbstractStream] | None = None, outs: Sequence[AbstractStream] | None = (), thermo=None, init_with='WasteStream', degraded_components=('OtherSS',), N_user=1, N_tot_user=1, N_toilet=None, if_toilet_paper=True, if_flushing=True, if_cleansing=False, if_desiccant=True, if_air_emission=True, if_ideal_emptying=True, CAPEX=0, OPEX_over_CAPEX=0, lifetime=10, N_squatting_pan_per_toilet=1, N_urinal_per_toilet=1, if_include_front_end=True, **kwargs)¶
Multi-unit reinvented toilet.
The following components should be included in system thermo object for simulation: Tissue, WoodAsh, H2O, NH3, NonNH3, P, K, Mg, CH4, N2O.
The following impact items should be pre-constructed for life cycle assessment: Ceramic, Fan.
- Parameters:
ins (Iterable(stream)) – waste_in: mixed excreta.
Outs (Iterable(stream)) – waste_out: degraded mixed excreta. CH4: fugitive CH4. N2O: fugitive N2O.
N_squatting_pan_per_toilet (int) – The number of squatting pan per toilet.
N_urinal_per_toilet (int) – The number of urinals per toilet.
if_include_front_end (bool) – If False, will not consider the capital and operating costs of this unit.
See also
- property collection_period¶
[float] Time interval between storage tank collection, [d].
- line: str = 'MURT'¶
class-attribute Name denoting the type of Unit class. Defaults to the class name of the first child class
- run()¶
Run mass and energy balance. This method also runs specifications user defined specifications unless it is being run within a specification (to avoid infinite loops).
See also
_run
,specifications
,add_specification
,add_bounded_numerical_specification
- property tau¶
[float] Retention time of the unit, same as collection_period.
- class qsdsan.sanunits._toilet.PitLatrine(ID='', ins: Sequence[AbstractStream] | None = None, outs: Sequence[AbstractStream] | None = (), thermo=None, init_with='WasteStream', degraded_components=('OtherSS',), N_user=1, N_toilet=1, N_tot_user=None, if_toilet_paper=True, if_flushing=True, if_cleansing=False, if_desiccant=False, if_air_emission=True, if_ideal_emptying=True, CAPEX=449, OPEX_over_CAPEX=0.05, lifetime=8, if_leaching=True, if_shared=True, if_pit_above_water_table=True, **kwargs)¶
Single pit latrine based on Trimmer et al., a subclass of
qsdsan.sanunits.Toilet
.The following components should be included in system thermo object for simulation: Tissue, WoodAsh, H2O, NH3, NonNH3, P, K, CH4, N2O.
The following impact items should be pre-constructed for life cycle assessment: Cement, Sand, Gravel, Brick, Plastic, Steel, Wood, Excavation.
- Parameters:
ins (stream obj) – Excreta.
outs (Iterable(stream obj)) – Recyclable mixed excreta, stream leached to soil, fugitive CH4, and fugitive N2O.
lifetime (int) – Lifetime of this pit latrine, [yr].
if_leaching (bool) – If infiltration to soil occurs (i.e., if the pit walls and floors are permeable).
if_shared (bool) – If the toilet is shared.
if_pit_above_water_table (bool) – If the pit is above local water table.
Examples
References
[1] Trimmer et al., Navigating Multidimensional Social–Ecological System Trade-Offs across Sanitation Alternatives in an Urban Informal Settlement. Environ. Sci. Technol. 2020, 54 (19), 12641–12653. https://doi.org/10.1021/acs.est.0c03296.
See also
- property K_leaching¶
[float] Fraction of input K that leaches to the soil (if if_leaching is True).
- property MCF_decay¶
[float] Methane correction factor for COD degraded during storage.
- property N2O_EF_decay¶
[float] Fraction of N emitted as N2O during storage.
- property N_leaching¶
[float] Fraction of input N that leaches to the soil (if if_leaching is True).
- property P_leaching¶
[float] Fraction of input P that leaches to the soil (if if_leaching is True).
- property emptying_period¶
[float] Time interval between pit emptying, [yr].
- line: str = 'Pit latrine'¶
class-attribute Name denoting the type of Unit class. Defaults to the class name of the first child class
- property liq_leaching¶
[float] Fraction of input water that leaches to the soil (if if_leaching is True). If not set, then return the maximum of fraction of N, P, K leaching
- property pit_V¶
[float] Volume of the pit, [m3].
- property pit_area¶
[float] Area of the pit, [m2].
- property pit_depth¶
[float] Depth of the pit, [m].
- run()¶
Run mass and energy balance. This method also runs specifications user defined specifications unless it is being run within a specification (to avoid infinite loops).
See also
_run
,specifications
,add_specification
,add_bounded_numerical_specification
- property sludge_accum_rate¶
[float] Sludge accumulation rate, [L/cap/yr].
- property tau¶
[float] Retention time of the unit, same as emptying_period but in day.
- class qsdsan.sanunits._toilet.Toilet(ID='', ins: Sequence[AbstractStream] | None = None, outs: Sequence[AbstractStream] | None = (), thermo=None, init_with='WasteStream', degraded_components=('OtherSS',), N_user=1, N_toilet=1, N_tot_user=None, if_toilet_paper=True, if_flushing=True, if_cleansing=False, if_desiccant=False, if_air_emission=True, if_ideal_emptying=True, CAPEX=None, OPEX_over_CAPEX=None, price_ratio=1.0)¶
Abstract class containing common parameters and design algorithms for toilets based on Trimmer et al.
- Parameters:
degraded_components (tuple) – IDs of components that will degrade (simulated by first-order decay).
N_user (int, float) – Number of people per toilet. Note that this number can be a float when calculated from N_tot_user and N_toilet.
N_toilet (int) – Number of parallel toilets. In calculation, N_toilet will be calculated as ceil(N_tot_user/N_user).
N_tot_user (int) –
Total number of users.
Note
If N_tot_user is provided (i.e., not “None”), then updating N_user will recalculate N_toilet, and vice versa.
if_toilet_paper (bool) – If toilet paper is used.
if_flushing (bool) – If water is used for flushing.
if_cleansing (bool) – If water is used for cleansing.
if_desiccant (bool) – If desiccant is used for moisture and odor control.
if_air_emission (bool) – If emission to air occurs (i.e., if the pit is completely sealed off from the atmosphere).
if_ideal_emptying (bool) – If the toilet appropriately emptied to avoid contamination to the environmental.
CAPEX (float) – Capital cost of a single toilet.
OPEX_over_CAPEX (float) – Fraction of annual operating cost over total capital cost.
price_ratio (float) – Calculated capital cost will be multiplied by this number to consider the effect in cost difference from different locations.
References
[1] Trimmer et al., Navigating Multidimensional Social–Ecological System Trade-Offs across Sanitation Alternatives in an Urban Informal Settlement. Environ. Sci. Technol. 2020, 54 (19), 12641–12653. https://doi.org/10.1021/acs.est.0c03296.
See also
- property MCF_aq¶
[float] Methane correction factor for COD lost due to inappropriate emptying.
- property N2O_EF_aq¶
[float] Fraction of N emitted as N2O due to inappropriate emptying.
- property N_toilet¶
[int] Number of parallel toilets.
- property N_tot_user¶
[int] Number of total users.
- property N_user¶
[int, float] Number of people per toilet.
- property N_volatilization¶
[float] Fraction of input N that volatilizes to the air (if
if_air_emission
is True).
- property cleansing_water¶
[float] Amount of water used for cleansing (if
if_cleansing_water
is True), [kg/cap/hr].
- property desiccant¶
[float] Amount of desiccant used (if
if_desiccant
is True), [kg/cap/hr].Note
Value set by
desiccant_V
anddesiccant_rho
.
- property empty_ratio¶
[float] Fraction of excreta that is appropriately emptied.
Note
Will be 1 (i.e., 100%) if
if_ideal_emptying
is True.
- property flushing_water¶
[float] Amount of water used for flushing (if
if_flushing_water
is True), [kg/cap/hr].
- static get_emptying_emission(waste, CH4, N2O, empty_ratio, CH4_factor, N2O_factor)¶
Calculate emissions due to non-ideal emptying based on Trimmer et al.,
- Parameters:
stream (WasteStream) – Excreta stream that is not appropriately emptied (before emptying).
CH4 (WasteStream) – Fugitive CH4 gas (before emptying).
N2O (WasteStream) – Fugitive N2O gas (before emptying).
empty_ratio (float) – Fraction of excreta that is appropriately emptied..
CH4_factor (float) – Factor to convert COD removal to CH4 emission.
N2O_factor (float) – Factor to convert COD removal to N2O emission.
- Returns:
stream (WasteStream) – Excreta stream that is not appropriately emptied (after emptying).
CH4 (WasteStream) – Fugitive CH4 gas (after emptying).
N2O (WasteStream) – Fugitive N2O gas (after emptying).
- property if_N2O_emission¶
[bool] Whether to consider N degradation and fugitive N2O emission.
- line: str = 'Toilet'¶
class-attribute Name denoting the type of Unit class. Defaults to the class name of the first child class
- run()¶
Run mass and energy balance. This method also runs specifications user defined specifications unless it is being run within a specification (to avoid infinite loops).
See also
_run
,specifications
,add_specification
,add_bounded_numerical_specification
- property toilet_paper¶
[float] Amount of toilet paper used (if
if_toilet_paper
is True), [kg/cap/hr].
- class qsdsan.sanunits._toilet.UDDT(ID='', ins: Sequence[AbstractStream] | None = None, outs: Sequence[AbstractStream] | None = (), thermo=None, init_with='WasteStream', degraded_components=('OtherSS',), N_user=1, N_toilet=1, N_tot_user=None, if_toilet_paper=True, if_flushing=False, if_cleansing=False, if_desiccant=True, if_air_emission=True, if_ideal_emptying=True, CAPEX=553, OPEX_over_CAPEX=0.1, lifetime=8, T=298.15, safety_factor=1, if_prep_loss=True, if_treatment=False, **kwargs)¶
Urine-diverting dry toilet with liquid storage tank and dehydration vault for urine and feces storage, respectively, based on Trimmer et al., a subclass of
qsdsan.sanunits.Toilet
.The following components should be included in system thermo object for simulation: Tissue, WoodAsh, H2O, NH3, NonNH3, P, K, Mg, CH4, N2O.
The following impact items should be pre-constructed for life cycle assessment: Cement, Sand, Gravel, Brick, Plastic, Steel, StainlessSteelSheet, Wood.
- Parameters:
ins (stream obj) – Excreta stream.
outs (Iterable(stream obj)) – Recyclable liquid urine, recyclable solid feces, struvite scaling (irrecoverable), hydroxyapatite scaling (irrecoverable), fugitive CH4, and fugitive N2O.
lifetime (int) – Lifetime of this UDDT, [yr].
T (float) – Temperature, [K].
safety_factor (float) – Safety factor for pathogen removal during onsite treatment, must be larger than 1.
if_treatment (bool) – If has onsite treatment.
Examples
References
[1] Trimmer et al., Navigating Multidimensional Social–Ecological System Trade-Offs across Sanitation Alternatives in an Urban Informal Settlement. Environ. Sci. Technol. 2020, 54 (19), 12641–12653. https://doi.org/10.1021/acs.est.0c03296.
See also
- property collection_period¶
[float] Time interval between storage tank collection, [d].
- property fec_moi_min¶
[float] Minimum moisture content of feces.
- property fec_moi_red_rate¶
[float] Exponential reduction rate of feces moisture.
- line: str = 'UDDT'¶
class-attribute Name denoting the type of Unit class. Defaults to the class name of the first child class
- property log_removal¶
Desired level of pathogen inactivation.
- property prep_sludge¶
[float] Fraction of total precipitate appearing as sludge that can settle and be removed.
- run()¶
Run mass and energy balance. This method also runs specifications user defined specifications unless it is being run within a specification (to avoid infinite loops).
See also
_run
,specifications
,add_specification
,add_bounded_numerical_specification
- property struvite_pKsp¶
[float] Precipitation constant of struvite.
- property tank_V¶
[float] Volume of the urine storage tank, [m3].
- property tau¶
[float] Retention time of the unit, same as collection_period.
- property treatment_V¶
[float] Volume needed to achieve treatment target (if treating), [d].
- property treatment_tau¶
[float] Time for onsite treatment (if treating), [d].
- property ur_pH¶
Urine pH.
- property vault_V¶
[float] Volume of the feces dehydration vault, [m3].