watertap.unit_models.translators package

Submodules

watertap.unit_models.translators.translator_adm1_asm1 module

Translator block representing the ADM1/ASM1 interface.

Assumptions:
  • Steady-state only

Model formulated from:

Copp J. and Jeppsson, U., Rosen, C., 2006. Towards an ASM1 - ADM1 State Variable Interface for Plant-Wide Wastewater Treatment Modeling.  Proceedings of the Water Environment Federation, 2003, pp 498-510.

class watertap.unit_models.translators.translator_adm1_asm1.TranslatorDataADM1ASM1(component)[source]

Bases: TranslatorData

Translator block representing the ADM1/ASM1 interface

build()[source]

Begin building model. :param None:

Returns:

None

initialize_build(state_args_in=None, state_args_out=None, outlvl=0, solver=None, optarg=None)[source]

This method calls the initialization method of the state blocks.

Keyword Arguments:
  • state_args_in – a dict of arguments to be passed to the inlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • state_args_out – a dict of arguments to be passed to the outlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • outlvl – sets output level of initialization routine

  • optarg – solver options dictionary object (default=None, use default solver options)

  • solver – str indicating which solver to use during initialization (default = None, use default solver)

Returns:

None

class watertap.unit_models.translators.translator_adm1_asm1.Translator_ADM1_ASM1(*args, **kwds)

Bases: ProcessBlock

Parameters:
  • rule (function) – A rule function or None. Default rule calls build().

  • concrete (bool) – If True, make this a toplevel model. Default - False.

  • ctype (class) –

    Pyomo ctype of the block. Default - pyomo.environ.Block

    Config args

    dynamic

    Translator blocks are always steady-state.

    has_holdup

    Translator blocks do not contain holdup.

    outlet_state_defined

    Indicates whether unit model will fully define outlet state. If False, the outlet property package will enforce constraints such as sum of mole fractions and phase equilibrium. default - True. Valid values: { True - outlet state will be fully defined, False - outlet property package should enforce sumation and equilibrium constraints.}

    has_phase_equilibrium

    Indicates whether outlet property package should enforce phase equilibrium constraints. default - False. Valid values: { True - outlet property package should calculate phase equilibrium, False - outlet property package should notcalculate phase equilibrium.}

    inlet_property_package

    Property parameter object used to define property calculations for the incoming stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    inlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the incoming stream, default - None. Valid values: { see property package for documentation.}

    outlet_property_package

    Property parameter object used to define property calculations for the outgoing stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    outlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the outgoing stream, default - None. Valid values: { see property package for documentation.}

    reaction_package

    Reaction parameter object used to define reaction calculations, default - None. Valid values: { None - no reaction package, ReactionParameterBlock - a ReactionParameterBlock object.}

    reaction_package_args

    A ConfigBlock with arguments to be passed to a reaction block(s) and used when constructing these, default - None. Valid values: { see reaction package for documentation.}

  • initialize (dict) – ProcessBlockData config for individual elements. Keys are BlockData indexes and values are dictionaries with config arguments as keys.

  • idx_map (function) – Function to take the index of a BlockData element and return the index in the initialize dict from which to read arguments. This can be provided to override the default behavior of matching the BlockData index exactly to the index in initialize.

Returns:

(Translator_ADM1_ASM1) New instance

watertap.unit_models.translators.translator_adm1_asm2d module

Translator block representing the ADM1/ASM2d interface. This is copied from the Generic template for a translator block.

Assumptions:
  • Steady-state only

Model formulated from:

Flores-Alsina, X., Solon, K., Mbamba, C.K., Tait, S., Gernaey, K.V., Jeppsson, U. and Batstone, D.J., 2016. Modelling phosphorus (P), sulfur (S) and iron (Fe) interactions for dynamic simulations of anaerobic digestion processes. Water Research, 95, pp.370-382.

class watertap.unit_models.translators.translator_adm1_asm2d.TranslatorDataADM1ASM2D(component)[source]

Bases: TranslatorData

Translator block representing the ADM1/ASM2D interface

build()[source]

Begin building model. :param None:

Returns:

None

initialize_build(state_args_in=None, state_args_out=None, outlvl=0, solver=None, optarg=None)[source]

This method calls the initialization method of the state blocks.

Keyword Arguments:
  • state_args_in – a dict of arguments to be passed to the inlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • state_args_out – a dict of arguments to be passed to the outlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • outlvl – sets output level of initialization routine

  • optarg – solver options dictionary object (default=None, use default solver options)

  • solver – str indicating which solver to use during initialization (default = None, use default solver)

Returns:

None

class watertap.unit_models.translators.translator_adm1_asm2d.Translator_ADM1_ASM2D(*args, **kwds)

Bases: ProcessBlock

Parameters:
  • rule (function) – A rule function or None. Default rule calls build().

  • concrete (bool) – If True, make this a toplevel model. Default - False.

  • ctype (class) –

    Pyomo ctype of the block. Default - pyomo.environ.Block

    Config args

    dynamic

    Translator blocks are always steady-state.

    has_holdup

    Translator blocks do not contain holdup.

    outlet_state_defined

    Indicates whether unit model will fully define outlet state. If False, the outlet property package will enforce constraints such as sum of mole fractions and phase equilibrium. default - True. Valid values: { True - outlet state will be fully defined, False - outlet property package should enforce sumation and equilibrium constraints.}

    has_phase_equilibrium

    Indicates whether outlet property package should enforce phase equilibrium constraints. default - False. Valid values: { True - outlet property package should calculate phase equilibrium, False - outlet property package should notcalculate phase equilibrium.}

    inlet_property_package

    Property parameter object used to define property calculations for the incoming stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    inlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the incoming stream, default - None. Valid values: { see property package for documentation.}

    outlet_property_package

    Property parameter object used to define property calculations for the outgoing stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    outlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the outgoing stream, default - None. Valid values: { see property package for documentation.}

    reaction_package

    Reaction parameter object used to define reaction calculations, default - None. Valid values: { None - no reaction package, ReactionParameterBlock - a ReactionParameterBlock object.}

    reaction_package_args

    A ConfigBlock with arguments to be passed to a reaction block(s) and used when constructing these, default - None. Valid values: { see reaction package for documentation.}

  • initialize (dict) – ProcessBlockData config for individual elements. Keys are BlockData indexes and values are dictionaries with config arguments as keys.

  • idx_map (function) – Function to take the index of a BlockData element and return the index in the initialize dict from which to read arguments. This can be provided to override the default behavior of matching the BlockData index exactly to the index in initialize.

Returns:

(Translator_ADM1_ASM2D) New instance

watertap.unit_models.translators.translator_adm1_simple_asm2d module

Translator block representing the ADM1/Simple ASM2d interface. This is copied from the Generic template for a translator block.

Assumptions:
  • Steady-state only

Model formulated from:

Flores-Alsina, X., Solon, K., Mbamba, C.K., Tait, S., Gernaey, K.V., Jeppsson, U. and Batstone, D.J., 2016. Modelling phosphorus (P), sulfur (S) and iron (Fe) interactions for dynamic simulations of anaerobic digestion processes. Water Research, 95, pp.370-382.

class watertap.unit_models.translators.translator_adm1_simple_asm2d.TranslatorDataADM1SimpleASM2D(component)[source]

Bases: TranslatorData

Translator block representing the ADM1/Simple ASM2D interface

build()[source]

Begin building model. :param None:

Returns:

None

initialize_build(state_args_in=None, state_args_out=None, outlvl=0, solver=None, optarg=None)[source]

This method calls the initialization method of the state blocks.

Keyword Arguments:
  • state_args_in – a dict of arguments to be passed to the inlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • state_args_out – a dict of arguments to be passed to the outlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • outlvl – sets output level of initialization routine

  • optarg – solver options dictionary object (default=None, use default solver options)

  • solver – str indicating which solver to use during initialization (default = None, use default solver)

Returns:

None

class watertap.unit_models.translators.translator_adm1_simple_asm2d.Translator_ADM1_Simple_ASM2D(*args, **kwds)

Bases: ProcessBlock

Parameters:
  • rule (function) – A rule function or None. Default rule calls build().

  • concrete (bool) – If True, make this a toplevel model. Default - False.

  • ctype (class) –

    Pyomo ctype of the block. Default - pyomo.environ.Block

    Config args

    dynamic

    Translator blocks are always steady-state.

    has_holdup

    Translator blocks do not contain holdup.

    outlet_state_defined

    Indicates whether unit model will fully define outlet state. If False, the outlet property package will enforce constraints such as sum of mole fractions and phase equilibrium. default - True. Valid values: { True - outlet state will be fully defined, False - outlet property package should enforce sumation and equilibrium constraints.}

    has_phase_equilibrium

    Indicates whether outlet property package should enforce phase equilibrium constraints. default - False. Valid values: { True - outlet property package should calculate phase equilibrium, False - outlet property package should notcalculate phase equilibrium.}

    inlet_property_package

    Property parameter object used to define property calculations for the incoming stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    inlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the incoming stream, default - None. Valid values: { see property package for documentation.}

    outlet_property_package

    Property parameter object used to define property calculations for the outgoing stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    outlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the outgoing stream, default - None. Valid values: { see property package for documentation.}

    reaction_package

    Reaction parameter object used to define reaction calculations, default - None. Valid values: { None - no reaction package, ReactionParameterBlock - a ReactionParameterBlock object.}

    reaction_package_args

    A ConfigBlock with arguments to be passed to a reaction block(s) and used when constructing these, default - None. Valid values: { see reaction package for documentation.}

  • initialize (dict) – ProcessBlockData config for individual elements. Keys are BlockData indexes and values are dictionaries with config arguments as keys.

  • idx_map (function) – Function to take the index of a BlockData element and return the index in the initialize dict from which to read arguments. This can be provided to override the default behavior of matching the BlockData index exactly to the index in initialize.

Returns:

(Translator_ADM1_Simple_ASM2D) New instance

watertap.unit_models.translators.translator_asm1_adm1 module

Translator block representing the ASM1/ADM1 interface.

Assumptions:
  • Steady-state only

Model formulated from:

Copp J. and Jeppsson, U., Rosen, C., 2006. Towards an ASM1 - ADM1 State Variable Interface for Plant-Wide Wastewater Treatment Modeling. Proceedings of the Water Environment Federation, 2003, pp 498-510.

class watertap.unit_models.translators.translator_asm1_adm1.TranslatorDataASM1ADM1(component)[source]

Bases: TranslatorData

Translator block representing the ASM1/ADM1 interface

build()[source]

Begin building model. :param None:

Returns:

None

initialize_build(state_args_in=None, state_args_out=None, outlvl=0, solver=None, optarg=None)[source]

This method calls the initialization method of the state blocks.

Keyword Arguments:
  • state_args_in – a dict of arguments to be passed to the inlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • state_args_out – a dict of arguments to be passed to the outlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • outlvl – sets output level of initialization routine

  • optarg – solver options dictionary object (default=None, use default solver options)

  • solver – str indicating which solver to use during initialization (default = None, use default solver)

Returns:

None

class watertap.unit_models.translators.translator_asm1_adm1.Translator_ASM1_ADM1(*args, **kwds)

Bases: ProcessBlock

Parameters:
  • rule (function) – A rule function or None. Default rule calls build().

  • concrete (bool) – If True, make this a toplevel model. Default - False.

  • ctype (class) –

    Pyomo ctype of the block. Default - pyomo.environ.Block

    Config args

    dynamic

    Translator blocks are always steady-state.

    has_holdup

    Translator blocks do not contain holdup.

    outlet_state_defined

    Indicates whether unit model will fully define outlet state. If False, the outlet property package will enforce constraints such as sum of mole fractions and phase equilibrium. default - True. Valid values: { True - outlet state will be fully defined, False - outlet property package should enforce sumation and equilibrium constraints.}

    has_phase_equilibrium

    Indicates whether outlet property package should enforce phase equilibrium constraints. default - False. Valid values: { True - outlet property package should calculate phase equilibrium, False - outlet property package should notcalculate phase equilibrium.}

    inlet_property_package

    Property parameter object used to define property calculations for the incoming stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    inlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the incoming stream, default - None. Valid values: { see property package for documentation.}

    outlet_property_package

    Property parameter object used to define property calculations for the outgoing stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    outlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the outgoing stream, default - None. Valid values: { see property package for documentation.}

    reaction_package

    Reaction parameter object used to define reaction calculations, default - None. Valid values: { None - no reaction package, ReactionParameterBlock - a ReactionParameterBlock object.}

    reaction_package_args

    A ConfigBlock with arguments to be passed to a reaction block(s) and used when constructing these, default - None. Valid values: { see reaction package for documentation.}

  • initialize (dict) – ProcessBlockData config for individual elements. Keys are BlockData indexes and values are dictionaries with config arguments as keys.

  • idx_map (function) – Function to take the index of a BlockData element and return the index in the initialize dict from which to read arguments. This can be provided to override the default behavior of matching the BlockData index exactly to the index in initialize.

Returns:

(Translator_ASM1_ADM1) New instance

watertap.unit_models.translators.translator_asm2d_adm1 module

Translator block representing the ASM2d/ADM1 interface.

Assumptions:
  • Steady-state only

Model formulated from:

Flores-Alsina, X., Solon, K., Mbamba, C.K., Tait, S., Gernaey, K.V., Jeppsson, U. and Batstone, D.J., 2016. Modelling phosphorus (P), sulfur (S) and iron (Fe) interactions for dynamic simulations of anaerobic digestion processes. Water Research, 95, pp.370-382. https://github.com/wwtmodels/Plant-Wide-Models

class watertap.unit_models.translators.translator_asm2d_adm1.TranslatorDataASM2dADM1(component)[source]

Bases: TranslatorData

Translator block representing the ASM2d/ADM1 interface

build()[source]

Begin building model. :param None:

Returns:

None

initialize_build(state_args_in=None, state_args_out=None, outlvl=0, solver=None, optarg=None)[source]

This method calls the initialization method of the state blocks.

Keyword Arguments:
  • state_args_in – a dict of arguments to be passed to the inlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • state_args_out – a dict of arguments to be passed to the outlet property package (to provide an initial state for initialization (see documentation of the specific property package) (default = None).

  • outlvl – sets output level of initialization routine

  • optarg – solver options dictionary object (default=None, use default solver options)

  • solver – str indicating which solver to use during initialization (default = None, use default solver)

Returns:

None

class watertap.unit_models.translators.translator_asm2d_adm1.Translator_ASM2d_ADM1(*args, **kwds)

Bases: ProcessBlock

Parameters:
  • rule (function) – A rule function or None. Default rule calls build().

  • concrete (bool) – If True, make this a toplevel model. Default - False.

  • ctype (class) –

    Pyomo ctype of the block. Default - pyomo.environ.Block

    Config args

    dynamic

    Translator blocks are always steady-state.

    has_holdup

    Translator blocks do not contain holdup.

    outlet_state_defined

    Indicates whether unit model will fully define outlet state. If False, the outlet property package will enforce constraints such as sum of mole fractions and phase equilibrium. default - True. Valid values: { True - outlet state will be fully defined, False - outlet property package should enforce sumation and equilibrium constraints.}

    has_phase_equilibrium

    Indicates whether outlet property package should enforce phase equilibrium constraints. default - False. Valid values: { True - outlet property package should calculate phase equilibrium, False - outlet property package should notcalculate phase equilibrium.}

    inlet_property_package

    Property parameter object used to define property calculations for the incoming stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    inlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the incoming stream, default - None. Valid values: { see property package for documentation.}

    outlet_property_package

    Property parameter object used to define property calculations for the outgoing stream, default - None. Valid values: { PhysicalParameterObject - a PhysicalParameterBlock object.}

    outlet_property_package_args

    A ConfigBlock with arguments to be passed to the property block associated with the outgoing stream, default - None. Valid values: { see property package for documentation.}

    bio_P

    Switching function for handling the transformation of phosphorus biomass, default - True. Valid values: { False - the BioP variables are kinetically described within the ADM, True - the BioP variables are supposed to be transformed in the interface

    inlet_reaction_package

    Reaction parameter object used to define reaction calculations, default - None. Valid values: { None - no reaction package, ReactionParameterBlock - a ReactionParameterBlock object.}

    inlet_reaction_package_args

    A ConfigBlock with arguments to be passed to a reaction block(s) and used when constructing these, default - None. Valid values: { see reaction package for documentation.}

    outlet_reaction_package

    Reaction parameter object used to define reaction calculations, default - None. Valid values: { None - no reaction package, ReactionParameterBlock - a ReactionParameterBlock object.}

    outlet_reaction_package_args

    A ConfigBlock with arguments to be passed to a reaction block(s) and used when constructing these, default - None. Valid values: { see reaction package for documentation.}

  • initialize (dict) – ProcessBlockData config for individual elements. Keys are BlockData indexes and values are dictionaries with config arguments as keys.

  • idx_map (function) – Function to take the index of a BlockData element and return the index in the initialize dict from which to read arguments. This can be provided to override the default behavior of matching the BlockData index exactly to the index in initialize.

Returns:

(Translator_ASM2d_ADM1) New instance

Module contents