Skip to content

Commit

Permalink
fix docs
Browse files Browse the repository at this point in the history
  • Loading branch information
yalinli2 committed Oct 16, 2024
1 parent ba224e1 commit 75e083b
Show file tree
Hide file tree
Showing 6 changed files with 88 additions and 68 deletions.
2 changes: 1 addition & 1 deletion docs/source/api/processes/ADM1p.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ Anaerobic Digestion Model No.1 with P extension (ADM1 P/Extension)
:members:

.. autoclass:: qsdsan.processes.ADM1p
:members:
:members:
52 changes: 27 additions & 25 deletions qsdsan/processes/_adm1_p_extension.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ def grad_dydt_Sh2_AD(S_h2, state_arr, h, params, f_stoichio, V_liq, S_h2_in):
@chemicals_user
class ADM1_p_extension(ADM1):
"""
Anaerobic Digestion Model No.1 with P extension. [1]_, [2]_, [3]_.
Anaerobic Digestion Model No.1 with P extension.
Compatible with the original `ASM2d`.
Parameters
Expand Down Expand Up @@ -357,17 +357,19 @@ class ADM1_p_extension(ADM1):
References
----------
.. [1] Batstone, D. J.; Keller, J.; Angelidaki, I.; Kalyuzhnyi, S. V;
Pavlostathis, S. G.; Rozzi, A.; Sanders, W. T. M.; Siegrist, H.;
Vavilin, V. A. The IWA Anaerobic Digestion Model No 1 (ADM1).
Water Sci. Technol. 2002, 45 (10), 65–73.
.. [2] Rosen, C.; Jeppsson, U. Aspects on ADM1 Implementation within
the BSM2 Framework; Lund, 2006.
.. [3] Flores-Alsina, X.; Solon, K.; Kazadi Mbamba, C.; Tait, S.;
Gernaey, K. V.; Jeppsson, U.; Batstone, D. J.
Modelling phosphorus (P), sulfur (S) and iron (FE) interactions for
dynamic simulations of anaerobic digestion processes. Water Research. 2016,
95, 370–382.
[1] Batstone, D. J.; Keller, J.; Angelidaki, I.; Kalyuzhnyi, S. V;
Pavlostathis, S. G.; Rozzi, A.; Sanders, W. T. M.; Siegrist, H.;
Vavilin, V. A. The IWA Anaerobic Digestion Model No 1 (ADM1).
Water Sci. Technol. 2002, 45 (10), 65–73.
[2] Rosen, C.; Jeppsson, U. Aspects on ADM1 Implementation within
the BSM2 Framework; Lund, 2006.
[3] Flores-Alsina, X.; Solon, K.; Kazadi Mbamba, C.; Tait, S.;
Gernaey, K. V.; Jeppsson, U.; Batstone, D. J.
Modelling phosphorus (P), sulfur (S) and iron (FE) interactions for
dynamic simulations of anaerobic digestion processes. Water Research. 2016,
95, 370–382.
"""

_stoichio_params = (*ADM1._stoichio_params[5:],
Expand Down Expand Up @@ -798,7 +800,7 @@ def _rhos_adm1p(state_arr, params, h=None):
@chemicals_user
class ADM1p(ADM1):
"""
Anaerobic Digestion Model No.1 with P extension. [1]_, [2]_.
Anaerobic Digestion Model No.1 with P extension. [1], [2].
Compatible with `mASM2d`.
Parameters
Expand Down Expand Up @@ -866,20 +868,20 @@ class ADM1p(ADM1):
>>> adm.show()
ADM1p([hydrolysis_carbs, hydrolysis_proteins, hydrolysis_lipids, uptake_sugars, uptake_amino_acids, uptake_LCFA, uptake_valerate, uptake_butyrate, uptake_propionate, uptake_acetate, uptake_h2, decay_Xsu, decay_Xaa, decay_Xfa, decay_Xc4, decay_Xpro, decay_Xac, decay_Xh2, storage_Sva_in_XPHA, storage_Sbu_in_XPHA, storage_Spro_in_XPHA, storage_Sac_in_XPHA, lysis_XPAO, lysis_XPP, lysis_XPHA, CaCO3_precipitation_dissolution, struvite_precipitation_dissolution, newberyite_precipitation_dissolution, ACP_precipitation_dissolution, MgCO3_precipitation_dissolution, AlPO4_precipitation_dissolution, FePO4_precipitation_dissolution, h2_transfer, ch4_transfer, IC_transfer])
References
----------
.. [1] Flores-Alsina, X., Solon, K., Kazadi Mbamba, C., Tait, S.,
Gernaey, K. V., Jeppsson, U., & Batstone, D. J. (2016).
Modelling phosphorus (P), sulfur (S) and iron (FE) interactions for
dynamic simulations of anaerobic digestion processes. Water Research,
95, 370–382.
.. [2] Solon, K., Flores-Alsina, X., Kazadi Mbamba, C., Ikumi, D., Volcke,
E. I. P., Vaneeckhaute, C., Ekama, G., Vanrolleghem, P. A., Batstone,
D. J., Gernaey, K. V., & Jeppsson, U. (2017). Plant-wide modelling
of phosphorus transformations in wastewater treatment systems:
Impacts of control and operational strategies. Water Research, 113,
97–110.
[1] Flores-Alsina, X., Solon, K., Kazadi Mbamba, C., Tait, S.,
Gernaey, K. V., Jeppsson, U., & Batstone, D. J. (2016).
Modelling phosphorus (P), sulfur (S) and iron (FE) interactions for
dynamic simulations of anaerobic digestion processes. Water Research,
95, 370–382.
[2] Solon, K., Flores-Alsina, X., Kazadi Mbamba, C., Ikumi, D., Volcke,
E. I. P., Vaneeckhaute, C., Ekama, G., Vanrolleghem, P. A., Batstone,
D. J., Gernaey, K. V., & Jeppsson, U. (2017). Plant-wide modelling
of phosphorus transformations in wastewater treatment systems:
Impacts of control and operational strategies. Water Research, 113,
97–110.
"""

_stoichio_params = (*ADM1._stoichio_params[5:],
Expand Down
45 changes: 23 additions & 22 deletions qsdsan/processes/_asm2d.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ def rhos_asm2d(state_arr, params):
@chemicals_user
class ASM2d(CompiledProcesses):
'''
Activated Sludge Model No. 2d in original notation. [1]_, [2]_
Activated Sludge Model No. 2d in original notation.
Parameters
----------
Expand Down Expand Up @@ -441,14 +441,15 @@ class ASM2d(CompiledProcesses):
References
----------
.. [1] Henze, M.; Gujer, W.; Mino, T.; Loosdrecht, M. van. Activated Sludge
Models: ASM1, ASM2, ASM2d and ASM3; IWA task group on mathematical modelling
for design and operation of biological wastewater treatment, Ed.; IWA
Publishing: London, 2000.
.. [2] Rieger, L.; Gillot, S.; Langergraber, G.; Ohtsuki, T.; Shaw, A.; Takács,
I.; Winkler, S. Guidelines for Using Activated Sludge Models; IWA Publishing:
London, New York, 2012; Vol. 11.
https://doi.org/10.2166/9781780401164.
[1] Henze, M.; Gujer, W.; Mino, T.; Loosdrecht, M. van. Activated Sludge
Models: ASM1, ASM2, ASM2d and ASM3; IWA task group on mathematical modelling
for design and operation of biological wastewater treatment, Ed.; IWA
Publishing: London, 2000.
[2] Rieger, L.; Gillot, S.; Langergraber, G.; Ohtsuki, T.; Shaw, A.; Takács,
I.; Winkler, S. Guidelines for Using Activated Sludge Models; IWA Publishing:
London, New York, 2012; Vol. 11.
https://doi.org/10.2166/9781780401164.
'''
_params = ('f_SI', 'Y_H', 'f_XI_H', 'Y_PAO', 'Y_PO4', 'Y_PHA', 'f_XI_PAO', 'Y_A', 'f_XI_AUT',
'K_h', 'eta_NO3', 'eta_fe', 'K_O2', 'K_NO3', 'K_X',
Expand Down Expand Up @@ -701,7 +702,7 @@ def _rhos_masm2d(state_arr, params, acceptor_dependent_decay=True, h=None):
@chemicals_user
class mASM2d(CompiledProcesses):
'''
Modified ASM2d. [1]_, [2]_ Compatible with `ADM1p` for plant-wide simulations.
Modified ASM2d. Compatible with `ADM1p` for plant-wide simulations.
Includes an algebraic pH solver and precipitation/dissolution of common minerals.
Parameters
Expand Down Expand Up @@ -768,18 +769,18 @@ class mASM2d(CompiledProcesses):
References
----------
.. [1] Henze, M., Gujer, W., Mino, T., & van Loosdrecht, M. (2000).
Activated Sludge Models: ASM1, ASM2, ASM2d and ASM3. In IWA task group
on mathematical modelling for design and operation of biological
wastewater treatment (Ed.), Scientific and Technical Report No. 9.
IWA Publishing.
.. [2] Solon, K., Flores-Alsina, X., Kazadi Mbamba, C., Ikumi, D., Volcke,
E. I. P., Vaneeckhaute, C., Ekama, G., Vanrolleghem, P. A., Batstone,
D. J., Gernaey, K. V., & Jeppsson, U. (2017). Plant-wide modelling
of phosphorus transformations in wastewater treatment systems:
Impacts of control and operational strategies. Water Research, 113,
97–110. https://doi.org/10.1016/j.watres.2017.02.007
[1] Henze, M., Gujer, W., Mino, T., & van Loosdrecht, M. (2000).
Activated Sludge Models: ASM1, ASM2, ASM2d and ASM3. In IWA task group
on mathematical modelling for design and operation of biological
wastewater treatment (Ed.), Scientific and Technical Report No. 9.
IWA Publishing.
[2] Solon, K., Flores-Alsina, X., Kazadi Mbamba, C., Ikumi, D., Volcke,
E. I. P., Vaneeckhaute, C., Ekama, G., Vanrolleghem, P. A., Batstone,
D. J., Gernaey, K. V., & Jeppsson, U. (2017). Plant-wide modelling
of phosphorus transformations in wastewater treatment systems:
Impacts of control and operational strategies. Water Research, 113,
97–110. https://doi.org/10.1016/j.watres.2017.02.007
'''
_stoichio_params = ('f_SI', 'Y_H', 'Y_PAO', 'Y_PO4', 'Y_PHA', 'Y_A',
'f_XI_H', 'f_XI_PAO', 'f_XI_AUT', 'COD_deN', 'K_XPP', 'Mg_XPP')
Expand Down
25 changes: 16 additions & 9 deletions qsdsan/sanunits/_clarifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def _settling_flux(X, v_max, v_max_practical, X_min, rh, rp, n0):
class FlatBottomCircularClarifier(SanUnit):
"""
A flat-bottom circular clarifier with a simple 1-dimensional
N-layer settling model. [1]_
N-layer settling model.
Parameters
----------
Expand Down Expand Up @@ -123,15 +123,19 @@ class FlatBottomCircularClarifier(SanUnit):
References
----------
.. [1] Takács, I.; Patry, G. G.; Nolasco, D. A Dynamic Model of the Clarification
-Thickening Process. Water Res. 1991, 25 (10), 1263–1271.
https://doi.org/10.1016/0043-1354(91)90066-Y.
.. [2] Chapter-12: Suspended-growth Treatment Processes. WEF Manual of Practice No. 8.
6th Edition. Virginia: McGraw-Hill, 2018.
.. [3] Metcalf, Leonard, Harrison P. Eddy, and Georg Tchobanoglous. Wastewater
[1] Takács, I.; Patry, G. G.; Nolasco, D. A Dynamic Model of the Clarification
-Thickening Process. Water Res. 1991, 25 (10), 1263–1271.
https://doi.org/10.1016/0043-1354(91)90066-Y.
[2] Chapter-12: Suspended-growth Treatment Processes. WEF Manual of Practice No. 8.
6th Edition. Virginia: McGraw-Hill, 2018.
[3] Metcalf, Leonard, Harrison P. Eddy, and Georg Tchobanoglous. Wastewater
engineering: treatment, disposal, and reuse. Vol. 4. New York: McGraw-Hill, 1991.
.. [4] Introduction to Wastewater Clarifier Design by Nikolay Voutchkov, PE, BCEE.
.. [5] RECOMMENDED STANDARDS for WASTEWATER FACILITIES. 10 state standards. 2014 edition.
[4] Introduction to Wastewater Clarifier Design by Nikolay Voutchkov, PE, BCEE.
[5] RECOMMENDED STANDARDS for WASTEWATER FACILITIES. 10 state standards. 2014 edition.
"""

_N_ins = 1
Expand Down Expand Up @@ -1092,6 +1096,7 @@ class PrimaryClarifierBSM2(SanUnit):
----------
[1] Otterpohl R. and Freund M. (1992). Dynamic Models for clarifiers of activated sludge
plants with dry and wet weather flows. Water Sci. Technol., 26(5-6), 1391-1400.
[2] Gernaey, Krist V., Ulf Jeppsson, Peter A. Vanrolleghem, and John B. Copp.
Benchmarking of control strategies for wastewater treatment plants. IWA publishing, 2014.
"""
Expand Down Expand Up @@ -1312,8 +1317,10 @@ class PrimaryClarifier(IdealClarifier):
----------
[1] Chapter-10: Primary Treatment. Design of water resource recovery facilities.
WEF Manual of Practice No. 8. 6th Edition. Virginia: McGraw-Hill, 2018.
[2] Metcalf, Leonard, Harrison P. Eddy, and Georg Tchobanoglous. Wastewater
engineering: treatment, disposal, and reuse. Vol. 4. New York: McGraw-Hill, 1991.
[3] Introduction to Wastewater Clarifier Design by Nikolay Voutchkov, PE, BCEE.
"""

Expand Down
5 changes: 2 additions & 3 deletions qsdsan/sanunits/_junction.py
Original file line number Diff line number Diff line change
Expand Up @@ -1643,7 +1643,6 @@ class mADM1toASM2d(mADMjunction):
[1] Nopens, I.; Batstone, D. J.; Copp, J. B.; Jeppsson, U.; Volcke, E.;
Alex, J.; Vanrolleghem, P. A. An ASM/ADM Model Interface for Dynamic
Plant-Wide Simulation. Water Res. 2009, 43, 1913–1923.
[2] Flores-Alsina, X., Solon, K., Kazadi Mbamba, C., Tait, S., Gernaey, K. V.,
Jeppsson, U., & Batstone, D. J. (2016). Modelling phosphorus (P), sulfur (S)
and iron (FE) interactions for dynamic simulations of anaerobic digestion processes.
Expand Down Expand Up @@ -2479,7 +2478,7 @@ def check_component_properties(self, cmps_asm, cmps_adm):
class ADM1ptomASM2d(A1junction):
'''
Interface unit to convert ADM1 state variables
to ASM2d components, following the A1 algorithm in [1]_.
to ASM2d components, following the A1 algorithm in [1].
Parameters
----------
Expand Down Expand Up @@ -2727,7 +2726,7 @@ def adm1p2masm2d(adm_vals):
class mASM2dtoADM1p(A1junction):
'''
Interface unit to convert ASM2d state variables
to ADM1 components, following the A1 scenario in [1]_.
to ADM1 components, following the A1 scenario in [1].
Parameters
----------
Expand Down
27 changes: 19 additions & 8 deletions qsdsan/sanunits/_sludge_treatment.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@ def calc_f_Qu_thin(TSS_removal_perc, thickener_factor):
class Thickener(SanUnit):

"""
Thickener based on BSM2 Layout. [1]
Thickener based on BSM2 Layout.
Parameters
----------
ID : str
ID for the Thickener. The default is ''.
Expand Down Expand Up @@ -160,12 +162,15 @@ class Thickener(SanUnit):
References
----------
.. [1] Gernaey, Krist V., Ulf Jeppsson, Peter A. Vanrolleghem, and John B. Copp.
[1] Gernaey, Krist V., Ulf Jeppsson, Peter A. Vanrolleghem, and John B. Copp.
Benchmarking of control strategies for wastewater treatment plants. IWA publishing, 2014.
.. [2] Chapter-21: Solids Thicknening (Table 21.3). WEF Manual of Practice No. 8.
[2] Chapter-21: Solids Thicknening (Table 21.3). WEF Manual of Practice No. 8.
6th Edition. Virginia: McGraw-Hill, 2018.
.. [3] Introduction to Wastewater Clarifier Design by Nikolay Voutchkov, PE, BCEE.
.. [4] Metcalf, Leonard, Harrison P. Eddy, and Georg Tchobanoglous. Wastewater
[3] Introduction to Wastewater Clarifier Design by Nikolay Voutchkov, PE, BCEE.
[4] Metcalf, Leonard, Harrison P. Eddy, and Georg Tchobanoglous. Wastewater
engineering: treatment, disposal, and reuse. Vol. 4. New York: McGraw-Hill, 1991.
"""

Expand Down Expand Up @@ -370,7 +375,7 @@ def yt(t, QC_ins, dQC_ins):
class Centrifuge(Thickener):

"""
Centrifuge based on BSM2 Layout. [1]
Centrifuge based on BSM2 Layout.
Parameters
----------
Expand Down Expand Up @@ -409,12 +414,17 @@ class Centrifuge(Thickener):
----------
[1] Gernaey, Krist V., Ulf Jeppsson, Peter A. Vanrolleghem, and John B. Copp.
Benchmarking of control strategies for wastewater treatment plants. IWA publishing, 2014.
[2] Metcalf, Leonard, Harrison P. Eddy, and Georg Tchobanoglous. Wastewater
engineering: treatment, disposal, and reuse. Vol. 4. New York: McGraw-Hill, 1991.
[3] Design of Municipal Wastewater Treatment Plants: WEF Manual of Practice
No. 8 ASCE Manuals and Reports on Engineering Practice No. 76, Fifth Edition.
[4] https://www.alibaba.com/product-detail/Multifunctional-Sludge-Dewatering-Decanter-Centrifuge_1600285055254.html?spm=a2700.galleryofferlist.normal_offer.d_title.1cd75229sPf1UW&s=p
[5] United States Environmental Protection Agency (EPA) 'Biosolids Technology Fact Sheet Centrifuge Thickening and Dewatering'
[6] San Diego (.gov) Chapter - 3 'Solids Treatment Facility'
(https://www.sandiego.gov/sites/default/files/legacy/mwwd/pdf/mbc/chapterthree.pdf)
"""
Expand Down Expand Up @@ -531,11 +541,12 @@ class Incinerator(SanUnit):
flow (g/hr): X_Ig_ISS 2.37e+05
WasteStream-specific properties: None for non-liquid waste streams
References:
References
----------
.. [1] Khuriati, A., P. Purwanto, H. S. Huboyo, Suryono Sumariyah, S. Suryono, and A. B. Putranto.
[1] Khuriati, A., P. Purwanto, H. S. Huboyo, Suryono Sumariyah, S. Suryono, and A. B. Putranto.
"Numerical calculation based on mass and energy balance of waste incineration in the fixed bed reactor."
In Journal of Physics: Conference Series, vol. 1524, no. 1, p. 012002. IOP Publishing, 2020.
[2] Omari, Arthur, Karoli N. Njau, Geoffrey R. John, Joseph H. Kihedu, and Peter L. Mtui.
"Mass And Energy Balance For Fixed Bed Incinerators A case of a locally designed incinerator in Tanzania."
"""
Expand Down

0 comments on commit 75e083b

Please sign in to comment.