Anaerobic Reactor

QSDsan: Quantitative Sustainable Design for sanitation and resource recovery systems

This module is developed by:

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.unit_operations.static._anaerobic_reactor.AnaerobicBaffledReactor(ID='', ins: Sequence[AbstractStream] | None = None, outs: Sequence[AbstractStream] | None = (), thermo=None, init_with='WasteStream', include_construction=True, degraded_components=('OtherSS',), if_capture_biogas=True, if_N2O_emission=False, **kwargs)

Anaerobic baffled reactor with the production of biogas based on Trimmer et al.

To enable life cycle assessment, the following impact items should be pre-constructed: Concrete, Gravel, Excavation.

Parameters:
  • ins (Iterable(stream)) – Waste for treatment.

  • outs (Iterable(stream)) – Treated waste, biogas, fugitive CH4, and fugitive N2O.

Examples

>>> from qsdsan.utils import create_example_sanitation_components
>>> cmps = create_example_sanitation_components()
>>> from qsdsan import System, WasteStream
>>> from qsdsan.unit_operations import AnaerobicBaffledReactor
>>> ws = WasteStream('ws', H2O=1000, OtherSS=100, NH3=5, units='kg/hr')
>>> ABR = AnaerobicBaffledReactor('ABR', ins=ws,
...                               outs=('treated', 'biogas', 'CH4', 'N2O'),
...                               decay_k_COD=3, decay_k_N=3, max_CH4_emission=0.25)
>>> sys = System('sys', path=(ABR,))
>>> sys.simulate()
>>> round(ABR.design_results['Single reactor volume'], 1)  # m3
212.5

See bwaise systems for use in a complete sanitation system.

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.

property COD_removal

[float] Fraction of COD removed during treatment.

property N_baffle

[int] Number of reactors, float will be converted to the smallest integer.

property N_reactor

[int] Number of reactors, float will be converted to the smallest integer.

property N_removal

[float] Fraction of N removed during treatment.

property add_concrete

[float] Additional concrete as a fraction of the reactor concrete usage to account for receiving basin and biogas tank.

property concrete_thickness

[float] Thickness of the concrete wall.

line: str = 'Anaerobic baffled reactor'

class-attribute Name denoting the type of Unit class. Defaults to the class name of the first child class

property reactor_H

[float] Reactor height, [m].

property reactor_L

[float] Reactor length, [m].

property reactor_W

[float] Reactor width, [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 tau

[float] Residence time, [d].

class qsdsan.unit_operations.static._anaerobic_reactor.AnaerobicDigestion(ID='', ins: Sequence[AbstractStream] | None = None, outs: Sequence[AbstractStream] | None = (), thermo=None, init_with='WasteStream', include_construction=True, flow_rate=None, degraded_components=('OtherSS',), if_capture_biogas=True, if_N2O_emission=False, **kwargs)

Anaerobic digestion of wastes with the production of biogas based on Trimmer et al.

To enable life cycle assessment, the following impact items should be pre-constructed: Concrete, Excavation.

Cost is calculated by the unit cost of the impact items and their quantities.

Parameters:
  • ins (Iterable) – Waste for treatment.

  • outs (Iterable) – Treated waste, captured biogas, fugitive CH4, and fugitive N2O.

  • flow_rate (float) – Total flow rate through the reactor (for sizing purpose), [m3/d]. If not provided, will use F_vol_in.

Examples

>>> from qsdsan.utils import create_example_sanitation_components
>>> cmps = create_example_sanitation_components()
>>> from qsdsan import System, WasteStream
>>> from qsdsan.unit_operations import AnaerobicDigestion
>>> ws = WasteStream('ws', H2O=1000, OtherSS=100, NH3=5, units='kg/hr')
>>> AD = AnaerobicDigestion('AD', ins=ws,
...                         outs=('treated', 'biogas', 'CH4', 'N2O'),
...                         decay_k_COD=3, decay_k_N=3, max_CH4_emission=0.25,
...                         flow_rate=1000)
>>> sys = System('sys', path=(AD,))
>>> sys.simulate()
>>> AD.design_results['Reactor number']
3.0

See bwaise systems for use in a complete sanitation system.

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.

property COD_removal

[float] Fraction of COD removed during treatment.

property N_reactor

[int] Number of reactors, float will be converted to the smallest integer.

property aspect_ratio

[float] Diameter-to-height ratio of the reactor.

property concrete_thickness

[float] Thickness of the concrete wall.

property flow_rate

[float] Total flow rate through the reactor (for sizing purpose), [m3/d]. If not provided, will calculate based on F_vol_in.

property headspace_frac

[float] Fraction of the reactor volume for headspace gas.

line: str = 'Anaerobic digestion'

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] Residence time, [d].

class qsdsan.unit_operations.static._anaerobic_reactor.SludgeDigester(ID='', ins: Sequence[AbstractStream] | None = None, outs: Sequence[AbstractStream] | None = (), thermo=None, init_with='WasteStream', include_construction=False, F_BM_default=1, HRT=20, SRT=20, T=308.15, Y=0.08, b=0.03, organics_conversion=0.7, COD_factor=1.42, methane_yield=0.4, methane_fraction=0.65, depth=10, heat_transfer_coeff={'ceiling': 0.95, 'floor': 1.7, 'wall': 0.7}, wall_concrete_unit_cost=24, slab_concrete_unit_cost=13, excavation_unit_cost=0.3, F_BM={'Pump': 1.1800826, 'Pump building': 1.1800826}, lifetime={'Pump': 15, 'Pump pipe stainless steel': 15, 'Pump stainless steel': 15}, **kwargs)

A conventional digester for anaerobic digestion of sludge as in Shoener et al..

Note that the CompiledComponents object set in system simulation must have defined active_biomass.

Parameters:
  • ins (Iterable(stream)) – Sludge for digestion.

  • outs (Iterable(stream)) – Digested sludge, generated biogas.

  • HRT (float) – Hydraulic retention time, [d].

  • SRT (float) – Solids retention time, [d].

  • T (float) – Temperature within the digester, [K].

  • Y (float) – Biomass yield, [mg VSS/mg BOD].

  • b (float) – Endogenous decay coefficient, [1/d].

  • organics_conversion (float) – Conversion of the organics (i.e., COD) of the sludge in fraction (i.e., 0.7 for 70%).

  • COD_factor (float) – Biomass-to-COD conversion factor, [g COD/g VSS].

  • methane_yield (float) – Methane yield from the digested organics, [m3/kg].

  • methane_fraction (float) – Fraction of methane in the biogas, the rest is assumed to be CO2.

  • depth (float) – Side depth of the digester, [m].

  • heat_transfer_coeff (dict) – Heat transfer coefficients for heat loss calculation, [W/m2/°C], keys should contain “wall”, “floor”, and “ceiling”.

  • wall_concrete_unit_cost (float) – Unit cost of the wall concrete, [UDS/ft3].

  • slab_concrete_unit_cost (float) – Unit cost of the slab concrete, [UDS/ft3].

  • excavation_unit_cost (float) – Unit cost of the excavation activity, [UDS/ft3].

References

[1] Shoener, B. D.; Zhong, C.; Greiner, A. D.; Khunjar, W. O.; Hong, P.-Y.; Guest, J. S.

Design of Anaerobic Membrane Bioreactors for the Valorization of Dilute Organic Carbon Waste Streams. Energy Environ. Sci. 2016, 9 (3), 1102–1112. https://doi.org/10.1039/C5EE03715H.

property D_PB

[float] Depth of the pump building, [ft].

property L_PB

[float] Length of the pump building, [ft].

property T_air

[float] Temperature of the air, [K].

property T_earth

[float] Temperature of the air, [K].

property W_PB

[float] Width of the pump building, [ft].

auxiliary_unit_names: tuple[str, ...] = ('heat_exchanger',)

Auxiliary unit operation names.

property constr_access

[float] Extra room for construction access, [ft].

property excav_slope

[float] Slope for excavation (horizontal/vertical).

property freeboard

[float] Freeboard added to the depth of the reactor tank, [ft].

line: str = 'Sludge digester'

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 t_slab

[float] Concrete slab thickness, [ft], default to be 2 in thicker than the wall thickness.

property t_wall

[float] Concrete wall thickness, [ft].