Translator Block

In complex process flowsheets, it may be necessary or desirable to used different property packages in different parts of the flowsheet. In these cases, there will need to be a Block to link the two parts of the flowsheet together, which will need to “translate” between the different property packages. The IDAES Translator block provides a framework to the user for creating this link.

The Translator block allows the user to specify the two property packages to be linked, and constructs a Block containing two Property Blocks and Ports, one for the incoming property package (inlet) and one for the outgoing property package (outlet). Users will then need to provide a set of Constraints linking the necessary states between the incoming and outgoing property packages.

Degrees of Freedom

Degrees of freedom in Translator blocks will depend on the property packages being used. Users will need to read the documentation on the associated property packages to decide on how to link the two.

Model Structure

The core Translator block consists of two Property Blocks (inlet_properties and outlet_properties) and two Port objects (inlet and outlet).

Construction Arguments

Translator blocks have the following construction arguments:

  • inlet_property_package - property package to use when constructing the Property Block for the incoming stream. This is provided as a Property Parameter Block by the Flowsheet when creating the model. If a value is not provided, the Translator Block will try to use the default property package if one is defined.
  • inlet_property_package_args - set of arguments to be passed to the inlet Property Block when it is created.
  • outlet_property_package - property package to use when constructing the Property Block for the outgoing stream. This is provided as a Property Parameter Block by the Flowsheet when creating the model. If a value is not provided, the Translator Block will try to use the default property package if one is defined.
  • outlet_property_package_args - set of arguments to be passed to the outlet Property Block when it is created.
  • has_equilibrium_reactions - argument to indicate whether the Property Blocks should enforce constraints for chemical equilibrium (default = False).
  • has_phase_equilibrium - argument to indicate whether the Property Blocks should enforce constraints for phase equilibrium (default = False).

Additional Constraints

Translator blocks write no additional Constraints. Users should provide the necessary Constraints to link states between the two Property Blocks.

Variables

Translator Blocks create no additional Variables.

TranslatorData Class

class idaes.models.translator.TranslatorData(component)[source]

This class constructs the basic framework for an IDAES block to “translate” between differnt property packages. This class constructs two property blocks using two different property packages - one for the incoming package and one for the outgoing package - along with the assoicated inlet and outlet Connector objects. Users will then need to provide a set of Constraints to connect the states in the incoming properties to those in the outgoing properties.

build()[source]

Begin building model (pre-DAE transformation).

Parameters:None
Returns:None
initialize(outlvl=0, solver='ipopt', optarg={'tol': 1e-06})[source]

This is a basic initialization routine for translator blocks. This method assumes both property blocks have good initial values and calls the initialization method of each block.

Users will liekly need to overload this method with a customised routine suited to their particular translation.

Keyword Arguments:
 
  • outlvl

    sets output level of initialisation routine

    • 0 = no output (default)
    • 1 = return solver state for each step in routine
    • 2 = return solver state for each step in subroutines
    • 3 = include solver output infomation (tee=True)
  • optarg – solver options dictionary object (default={‘tol’: 1e-6})
  • solver – str indicating whcih solver to use during initialization (default = ‘ipopt’)
Returns:

None

model_check()[source]

This is a general purpose model_check routine for translator blocks. This method tries to call the model_check method of the inlet and outlet property blocks. If an AttributeError is raised, the check is passed.

Parameters:None
Returns:None
post_transform_build()[source]

Continue model construction after DAE transformation.

Parameters:None
Returns:None