Multi-Component Aqueous Solution (MCAS) Property Package

This property package implements property relationships for an aqueous solution that may contain multiple neutral and/or ionic solutes.

This MCAS property package
  • sets H2O as the solvent;

  • supports multiple solute components including ions and neutral molecules;

  • supports only liquid phase;

  • uses molar flow rate (in mol/s), temperature and pressure as the initial state variables;

  • does not support dynamics.

Sets

Description

Symbol

Indices

Components

\(j\)

[‘H2O’, component_list 1]

Phases

\(p\)

[‘Liq’]

solute_set

\(j\)

[all components in component_list except H2O]

cation_set

\(j\)

[cationic components in component_list]

anion_set

\(j\)

[anionic components in component_list]

neutral_set

\(j\)

[neutral components in component_list]

ion_set

\(j\)

[cationic and anionic components in component_list]

Notes

1 component_list is provided by a necessary configuration to use this property package.

../../_images/mcas_set_hierarchy.png

Figure 1. Hierarchy of the pyomo sets constructed in the MCAS property package. Here types are declared for the species in component list, or sometimes auto assigned considering other input such as charge. e.g., the chloride anion would be contained in anion_set, ion_set, solute_set, and component_list.

State variables

Description

Symbol

Variable

Index

Units

Component molar flow rate

\(N\)

flow_mol_phase_comp

[p, j]

\(\text{mol s}^{-1}\)

Temperature

\(T\)

temperature

None

\(\text{K}\)

Pressure

\(P\)

pressure

None

\(\text{Pa}\)

Parameters

Description

Symbol

Parameter

Index

Units

Component molecular weight

\(m_N\)

mw_comp

[j]

\(\text{kg mol}^{-1}\)

Stokes radius of solute

\(r_h\)

radius_stokes_comp

[j]

\(\text{m}\)

Molar volume of solute

\(V\)

molar_volume_phase_comp

[p, j]

\(\text{m}^3 \text{ mol}^{-1}\)

Dynamic viscosity

\(\mu\)

visc_d_phase

[p]

\(\text{Pa s}\)

Bulk diffusivity of solute

\(D\)

diffus_phase_comp_param

[p, j]

\(\text{m}^2 \text{ s}^{-1}\)

Ion charge

\(z\)

charge_comp

[j]

\(\text{dimensionless}\)

Dielectric constant of water

\(\epsilon\)

dielectric_constant

None

\(\text{dimensionless}\)

Debye Huckel constant b

\(b\)

debye_huckel_b

None

\(\text{kg mol}^{-1}\)

Hayduk Laudie correlation constant

\(\chi_{1}\)

hl_diffus_cont

None

\(\text{dimensionless}\)

Hayduk Laudie viscosity coefficient

\(\chi_{2}\)

hl_visc_coeff

None

\(\text{dimensionless}\)

Hayduk Laudie molar volume coefficient

\(\chi_{3}\)

hl_molar_volume_coeff

None

\(\text{dimensionless}\)

Properties

Description

Symbol

Variable

Index

Units

Component mass flow rate

\(M\)

flow_mass_phase_comp

[p, j]

\(\text{kg s}^{-1}\)

Component charge-equivalent molar flow rate

\(\tilde{N}\)

flow_equiv_phase_comp

[p, j]

\(\text{mol s}^{-1}\)

Component charge-equivalent molar concentration

\(\tilde{n}\)

conc_equiv_phase_comp

[p, j]

\(\text{mol m}^{-3}\)

Component mass fraction

\(x\)

mass_frac_phase_comp

[p, j]

\(\text{dimensionless}\)

Mass density of aqueous phase

\(\rho\)

dens_mass_phase

[p]

\(\text{kg m}^{-3}\)

Mass density of solvent water

\(\rho_w\)

dens_mass_solvent

[p]

\(\text{kg m}^{-3}\)

Phase volumetric flowrate

\(Q\)

flow_vol_phase

[p]

\(\text{m}^3\text{ } \text{s}^{-1}\)

Total volumetric flowrate

\(Q_{tot}\)

flow_vol

None

\(\text{m}^3\text{ } \text{s}^{-1}\)

Component molar concentration

\(n\)

conc_mol_phase_comp

[p, j]

\(\text{mol m}^{-3}\)

Component mass concentration

\(m\)

conc_mass_phase_comp

[p, j]

\(\text{kg m}^{-3}\)

Component molar fraction

\(y\)

mole_frac_phase_comp

[p, j]

\(\text{dimensionless}\)

Component molality

\(b\)

molality_phase_comp

[p, j]

\(\text{mol kg}^{-1}\)

Kinematic viscosity

\(\nu\)

visc_k_phase

[p]

\(\text{m}^2 \text{ s}^{-1}\)

Phase osmotic pressure

\(\Pi\)

pressure_osm_phase

[p]

\(\text{Pa}\)

Ion component electrical mobility

\(\mu_e\)

elec_mobility_phase_comp

[p,j]

\(\text{m}^2\text{ }\text{V}^{-1}\text{ }\text{s}^{-1}\)

Ion component transport number

\(t\)

trans_num_phase_comp

[p, j]

\(\text{dimensionless}\)

Phase equivalent conductivity

\(\Lambda\)

equiv_conductivity_phase

[p]

\(\text{m}^2 \text{ } \Omega^{-1} \text{ mol}^{-1}\)

Phase electrical conductivity

\(\lambda\)

elec_cond_phase

[p]

\(\Omega^{-1} \text{ m}^{-1}\)

Component activity coefficient

\(\gamma\)

act_coeff_phase_comp

[j]

\(\text{dimensionless}\)

Debye-Huckel constant A

\(A\)

deby_huckel_constant

none

\(\text{dimensionless}\)

Ionic Strength

\(I\)

ionic_strength_molal

none

\(\text{mol kg}^{-1}\)

Mass diffusivity of solute

\(D\)

diffus_phase_comp

[p, j]

\(\text{m}^2 \text{ s}^{-1}\)

Relationships

Description

Equation

Component charge-equivalent molar flow rate

\(\tilde{N}=N\left|z\right|\)

Component charge-equivalent molar concentration

\(\tilde{n}=n\left|z\right|\)

Component mass fraction

\(x_j=\frac{M_j}{\sum_j{M_j}}\)

Mass density of aqueous phase

\(\rho=1000 \text{ kg m}^{-3}\) or \(\rho=\rho_w + \textbf{f} \left(\sum_{j\in solute}{x_j}, T\right)\) 1

Mass density of solvent water

\(\rho_w=\textbf{f}\left(T\right)\) 1

Phase volumetric flowrate

\(Q=\frac{\sum_j{N_j m_{Nj}}}{\rho}\)

Total volumetric flowrate

\(Q_{tot}=\sum_p{Q_p}\)

Component molar fraction

\(y_j=\frac{N_j}{\sum_j{N_j}}\)

Component molality

\(b=\frac{N}{N_{H_2O} m_{N\text{H_2O}}}\)

Kinematic viscosity

\(\nu=\mu\rho^{-1}\)

Phase osmotic pressure

\(\Pi=RT\sum_{j\in solute}{n_j}\)

Ion component electrical mobility

\(\mu_e=\frac{D\left|z\right|F}{RT}\)

Ion component transport number

\(t_j=\frac{\left|z_j\right|\mu_{ej} n_j}{\sum_{j\in ion}{\left|z_j\right|\mu_{ej} n_j}}\)

Phase equivalent conductivity

\(\Lambda=\frac{\sum_{j\in ion}{F\left|z_j\right|\mu_{ej} n_j}}{\sum_{j\in cation}{\left|z_j\right|n_j}}\)

Phase electrical conductivity

\(\lambda=\Lambda\sum_{j\in cation}{\left|z_j\right|n_j}\)

Debye-Huckel constant

\(A=\frac{\left(2 \pi N_A\right)^{0.5}}{log(10)} \left(\frac{\textbf{e}^2}{4 \pi \epsilon \epsilon_0 kT}\right)^{\frac{3}{2}}\)

Ionic strength

\(I=0.5\sum_{j\in ion}{z_j^2b_j}\)

Component mass diffusivity

\(D\text{ specified in data argument}\) or \(D \text{ }[\text{m}^2 \text{ s}^{-1}]=\frac{\chi_{1}}{(\mu \text{ }[\text{cP}])^{\chi_{2}}(V \text{ }[\text{cm}^3 \text{ mol}^{-1}])^{\chi_{3}}}\) 2

Notes
1 \(\textbf{f}(\cdot)\) refers to empirical correlations of phase or solvent mass density to seawater salinity and temperature following the study of Sharqawy et al. (2010).
2 Diffusivity specified in diffus_phase_comp_param or calculated by the correlation defined in Hayduk, W., & Laudie, H. (1974).

Physical/chemical constants

Description

Symbol

Value

Unit

Idea gas constant

\(R\)

8.3145

\(\text{J mol}^{-1} \text{K}^{-1}\)

Faraday constant

\(F\)

96485.33

\(\text{C mol}^{-1}\)

Avogadro constant

\(N_A\)

6.022e23

\(\text{dimensionless}\)

Boltzmann constant

\(k\)

1.381e-23

\(\text{J K}^{-1}\)

Vacuum permittivity

\(\epsilon_0\)

8.854e-12

\(\text{F m}^{-1}\)

Elementary charge

\(\textbf{e}\)

1.602e-19

\(\text{C}\)

Scaling

A comprehensive scaling factor calculation method is coded in this property package. Among the state variables (\(N, T, \text{and } p\)), default scaling factors for \(T\) and \(p\) were set and do not need users’ input, while, for \(N\), usually require a user input via an interface. The coding interface to set defalut scaling factor for \(N\) and call the scaling calculation for other variables is the following.

m.fs.properties.set_default_scaling('flow_mol_phase_comp', 1e2, index=('Liq','{component name}'))
# m is the model name, and fs is the instanced flowsheet block of m.
calculate_scaling_factors(m)

Users also have the authority to set a scaling factor for non-state variables via the following codes:

import idaes.core.util.scaling as iscale #import the needed utility package
...
iscale.set_scaling_factor(m.fs.properties.{property_name}, 100)

Proper scaling of variables is, in many cases, crucial to solver’s performance in finding an optimal solution of a problem. While designing scaling can have a mathematical sophistication, a general rule is to scale all variables as close to 1 as possible, e.g., in the range of 1e-2 to 1e2.

Classes

class watertap.property_models.multicomp_aq_sol_prop_pack.MCASParameterBlock(*args, **kwds)
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
    default_arguments

    Default arguments to use with Property Package

    solute_list

    List of solute species names

    stokes_radius_data

    Dict of solute species names and Stokes radius data

    diffusivity_data

    Dict of solute species names and bulk ion diffusivity data

    molar_volume_data

    Dict of solute species names and molar volume of aqueous species

    mw_data

    Dict of component names and molecular weight data

    elec_mobility_data

    Ion electrical mobility

    trans_num_data

    transport number of ions in the liquid phase

    equiv_conductivity_phase_data

    Equivalent conductivity of ions in the liquid phase

    charge

    Ion charge

    activity_coefficient_model

    Options to account for activity coefficient model.

    default - ActivityCoefficientModel.ideal

    Configuration Options

    Description

    ActivityCoefficientModel.ideal

    Activity coefficients equal to 1 assuming ideal solution

    ActivityCoefficientModel.davies

    Activity coefficients estimated via Davies model

    density_calculation

    Options to account for solution density.

    default - DensityCalculation.constant

    Configuration Options

    Description

    DensityCalculation.constant

    Solution density assumed constant at 1000 kg/m3 by default in dens_mass_const parameter

    DensityCalculation.seawater

    Solution density based on correlation for seawater (TDS)

    diffus_calculation

    Options to account for ionic or molecular diffusivity.

    default - DiffusivityCalculation.none

    Configuration Options

    Description

    DiffusivityCalculation.none

    Users provide data via the diffusivity_data configuration

    DiffusivityCalculation.HaydukLaudie

    Allow the nonelectrolyte (neutral) species to get diffusivity from the Hayduk Laudie equation

    elec_mobility_calculation

    Options to account for ion electrical mobility.

    default - ElectricalMobilityCalculation.none

    Configuration Options

    Description

    ElectricalMobilityCalculation.none

    Users provide data via the elec_mobility_data configuration

    ElectricalMobilityCalculation.EinsteinRelation

    Calculate from the diffusivity_data by the Einstein Relation

    trans_num_calculation

    Options to account for ion transport number in the solution.

    default - TransportNumberCalculation.ElectricalMobility

    Configuration Options

    Description

    TransportNumberCalculation.none

    Users provide data via the trans_num_data configuration

    TransportNumberCalculation.ElectricalMobility

    Calculated from the elec_mobility_data

    equiv_conductivity_calculation

    Options to account for the total equivalent conductivity of the liquid phase (solution).

    default - EquivalentConductivityCalculation.none

    Configuration Options

    Description

    EquivalentConductivityCalculation.none

    Users provide data via the equiv_conductivity_data configuration

    EquivalentConductivityCalculation.ElectricalMobility

    Calculated from the electrical_mobility_data

  • 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:

(MCASParameterBlock) New instance

class watertap.property_models.multicomp_aq_sol_prop_pack.MCASParameterData(component)[source]
build()[source]

Callable method for Block construction.

classmethod define_metadata(obj)[source]

Define properties supported and units.

class watertap.property_models.multicomp_aq_sol_prop_pack._MCASStateBlock(*args, **kwds)[source]

This Class contains methods which should be applied to Property Blocks as a whole, rather than individual elements of indexed Property Blocks.

calculate_state(var_args=None, hold_state=False, outlvl=0, solver=None, optarg=None)[source]

Solves state blocks given a set of variables and their values. These variables can be state variables or properties. This method is typically used before initialization to solve for state variables because non-state variables (i.e. properties) cannot be fixed in initialization routines.

Keyword Arguments:
  • var_args – dictionary with variables and their values, they can be state variables or properties {(VAR_NAME, INDEX): VALUE}

  • hold_state – flag indicating whether all of the state variables should be fixed after calculate state. True - State variables will be fixed. False - State variables will remain unfixed, unless already fixed.

  • outlvl – idaes logger object that sets output level of solve call (default=idaeslog.NOTSET)

  • solver – solver name string if None is provided the default solver for IDAES will be used (default = None)

  • optarg – solver options dictionary object (default={})

Returns:

results object from state block solve

initialize(state_args=None, state_vars_fixed=False, hold_state=False, outlvl=0, solver=None, optarg=None)[source]

Initialization routine for property package.

Keyword Arguments:
  • state_args – Dictionary with initial guesses for the state vars chosen. Note that if this method is triggered through the control volume, and if initial guesses were not provided at the unit model level, the control volume passes the inlet values as initial guess. The keys for the state_args dictionary are: flow_mol_phase_comp : value to initialize phase component flows; pressure : value at which to initialize pressure; temperature : value at which to initialize temperature.

  • outlvl – sets output level of initialization routine (default=idaeslog.NOTSET)

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

  • state_vars_fixed – Flag to denote if state vars have already been fixed. - True - states have already been fixed by the control volume 1D. Control volume 0D does not fix the state vars, so will be False if this state block is used with 0D blocks. - False - states have not been fixed. The state block will deal with fixing/unfixing.

  • solver – Solver object to use during initialization. If None is provided, it will use the default solver for IDAES (default = None)

  • hold_state – flag indicating whether the initialization routine should unfix any state variables fixed during initialization (default=False). - True - state variables are not unfixed, and a dict of returned containing flags for which states were fixed during initialization. - False - state variables are unfixed after initialization by calling the release_state method.

Returns:

If hold_states is True, returns a dict containing flags for which states were fixed during initialization.

release_state(flags, outlvl=0)[source]

Method to release state variables fixed during initialisation.

Keyword Arguments:
  • flags – dict containing information of which state variables were fixed during initialization, and should now be unfixed. This dict is returned by initialize if hold_state=True.

  • outlvl – sets output level of logging

class watertap.property_models.multicomp_aq_sol_prop_pack.MCASStateBlockData(*args, **kwargs)[source]
build()[source]

Callable method for Block construction.

define_state_vars()[source]

Define state vars.

get_material_flow_basis()[source]

Method which returns an Enum indicating the basis of the material flow term.

get_material_flow_terms(p, j)[source]

Create material flow terms for control volume.

Reference

M.H. Sharqawy, J.H.L. V, S.M. Zubair, Thermophysical properties of seawater: a review of existing correlations and data, Desalination and Water Treatment. 16 (2010) 354–380. https://doi.org/10.5004/dwt.2010.1079. (2017 corrections provided at http://web.mit.edu/seawater )

Bard, A. J., Faulkner, L. R., & White, H. S. (2022). Electrochemical methods: fundamentals and applications. John Wiley & Sons.

Hayduk, W., & Laudie, H. (1974). Prediction of diffusion coefficients for nonelectrolytes in dilute aqueous solutions. AIChE Journal, 20(3), 611–615. https://doi.org/10.1002/aic.690200329