Reverse Osmosis (0D)
from watertap.unit_models.reverse_osmosis_0D import ReverseOsmosis0D
- This reverse osmosis (RO) unit model
is 0-dimensional
supports a single liquid phase only
supports steady-state only
supports both solution-diffusion (SD) and Spiegler-Kedem-Katchalsky (SKK) models [1]
supports flat-sheet and spiral-wound module designs
assumes isothermal conditions
Degrees of Freedom
Aside from the inlet feed state variables (i.e. temperature, pressure, component flowrates), the RO model has at least 4 degrees of freedom that should be fixed for the unit to be fully specified.
- Typically, the following variables are fixed, in addition to state variables at the inlet:
membrane water permeability, A
membrane salt permeability, B
permeate pressure
membrane area
On the other hand, configuring the RO unit to calculate concentration polarization effects, mass transfer coefficient, and pressure drop would result in 3 additional degrees of freedom. In this case, in addition to the previously fixed variables, we typically fix the following variables to fully specify the unit:
feed-spacer porosity
feed-channel height
membrane length or membrane width or inlet Reynolds number
Model Structure
This RO model consists of 1 MembraneChannel0DBlock for the feed-side, a StateBlock indexed by time and space for the permeate-side (permeate_side[t, x]), and a StateBlock for the final permeate at the outlet (mixed_permeate).
The feed-side includes 2 StateBlocks (properties_in and properties_out) which are used for mass, energy, and momentum balances, and 2 additional StateBlocks for the conditions at the membrane interface (properties_interface_in and properties_interface_out).
The permeate-side includes 3 StateBlocks (properties_in, properties_out, and mixed_permeate). The inlet and outlet StateBlocks are used to only determine the permeate solute concentration for solvent and solute flux at the feed-side inlet and outlet, while the mixed StateBlock is used for mass balance based on the average flux.
Sets
Description |
Symbol |
Indices |
|---|---|---|
Time |
\(t\) |
[0] |
Inlet/outlet |
\(x\) |
[‘in’, ‘out’] |
Phases |
\(p\) |
[‘Liq’] |
Components |
\(j\) |
[‘H2O’, ‘NaCl’]* |
*Solute depends on the imported property model; example shown here is for the NaCl property model.
Variables
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Solvent permeability coefficient |
\(A\) |
A_comp |
[t, j] |
\(\text{m/Pa/s}\) |
Solute permeability coefficient |
\(B\) |
B_comp |
[t, j] |
\(\text{m/s}\) |
Mass density of solvent |
\(\rho_{solvent}\) |
dens_solvent |
[p] |
\(\text{kg/}\text{m}^3\) |
Mass flux across membrane |
\(J\) |
flux_mass_phase_comp |
[t, x, p, j] |
\(\text{kg/s}\text{/m}^2\) |
Membrane area |
\(A_m\) |
area |
None |
\(\text{m}^2\) |
Component recovery rate |
\(R_j\) |
recovery_mass_phase_comp |
[t, p, j] |
\(\text{dimensionless}\) |
Volumetric recovery rate |
\(R_{vol}\) |
recovery_vol_phase |
[t, p] |
\(\text{dimensionless}\) |
Observed solute rejection |
\(r_j\) |
rejection_phase_comp |
[t, p, j] |
\(\text{dimensionless}\) |
Over-pressure ratio |
\(P_{f,out}/Δ\pi_{out}\) |
over_pressure_ratio |
[t] |
\(\text{dimensionless}\) |
Mass transfer to permeate |
\(M_p\) |
mass_transfer_phase_comp |
[t, p, j] |
\(\text{kg/s}\) |
Feed-channel volume |
\(V_{f}\) |
feed_side.volume |
[t] |
\(\text{m}^3\) |
The following variables are only built when specific configuration key-value pairs are selected.
if has_pressure_change is set to True:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Pressure drop |
\(ΔP\) |
deltaP |
[t] |
\(\text{Pa}\) |
if concentration_polarization_type is set to ConcentrationPolarizationType.fixed:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Concentration polarization modulus |
\(CP_{mod}\) |
feed_side.cp_modulus |
[t, j] |
\(\text{dimensionless}\) |
if concentration_polarization_type is set to ConcentrationPolarizationType.calculated:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Mass transfer coefficient in feed channel |
\(k_f\) |
feed_side.K |
[t, x, j] |
\(\text{m/s}\) |
if mass_transfer_coefficient is set to MassTransferCoefficient.calculated
or pressure_change_type is set to PressureChangeType.calculated:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Feed-channel height |
\(h_{ch}\) |
feed_side.channel_height |
None |
\(\text{m}\) |
Hydraulic diameter |
\(d_h\) |
feed_side.dh |
None |
\(\text{m}\) |
Spacer porosity |
\(\epsilon_{sp}\) |
feed_side.spacer_porosity |
None |
\(\text{dimensionless}\) |
Reynolds number |
\(Re\) |
feed_side.N_Re |
[t, x] |
\(\text{dimensionless}\) |
if mass_transfer_coefficient is set to MassTransferCoefficient.calculated:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Schmidt number |
\(Sc\) |
feed_side.N_Sc_comp |
[t, x, j] |
\(\text{dimensionless}\) |
Sherwood number |
\(Sh\) |
feed_side.N_Sh_comp |
[t, x, j] |
\(\text{dimensionless}\) |
if mass_transfer_coefficient is set to MassTransferCoefficient.calculated
or pressure_change_type is NOT set to PressureChangeType.fixed_per_stage:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Membrane length |
\(L\) |
length |
None |
\(\text{m}\) |
Membrane width |
\(W\) |
width |
None |
\(\text{m}\) |
if pressure_change_type is set to PressureChangeType.fixed_per_unit_length:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Average pressure drop per unit length of feed channel |
\((\frac{ΔP}{Δx})_{avg}\) |
feed_side.dP_dx |
[t] |
\(\text{Pa/m}\) |
if pressure_change_type is set to PressureChangeType.calculated:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Feed-channel velocity |
\(v_f\) |
feed_side.velocity |
[t, x] |
\(\text{m/s}\) |
Friction factor |
\(f\) |
feed_side.friction_factor_darcy |
[t, x] |
\(\text{dimensionless}\) |
Pressure drop per unit length of feed channel at inlet/outlet |
\(ΔP/Δx\) |
feed_side.dP_dx |
[t, x] |
\(\text{Pa/m}\) |
if transport_model is set to TransportModel.SKK:
Description |
Symbol |
Variable Name |
Index |
Units |
|---|---|---|---|---|
Reflection coefficient |
\(\sigma\) |
reflect_coeff |
None |
\(\text{dimensionless}\) |
Alpha |
\(\alpha\) |
alpha |
None |
\(\text{s/m}\) |
Equations
Description |
Equation |
|---|---|
Solvent flux across membrane (solution-diffusion) |
\(J_{solvent} = \rho_{solvent} A(P_{f} - P_p - (\pi_{f}-\pi_{p}))\) |
Solvent flux across membrane (SKK) |
\(J_{solvent} = \rho_{solvent} A(P_{f} - P_p - \sigma(\pi_{f}-\pi_{p}))\) |
Solute flux across membrane (solution-diffusion) |
\(J_{solute} = B(C_{f} - C_{p})\) |
Solute flux across membrane (SKK) |
\(J_{solute} = B(C_{f} - C_{p}) + (1 - \sigma)\frac{J_{solvent}}{\rho_{solvent}}C_{f}\) |
Alpha (SKK) |
\(\alpha = \frac{1 - \sigma}{B}\) |
Average flux across membrane |
\(J_{avg, j} = \frac{1}{2}\sum_{x} J_{x, j}\) |
Permeate mass flow by component j |
\(M_{p, j} = A_m J_{avg,j}\) |
Permeate-side solute mass fraction |
\(X_{x, j} = \frac{J_{x, j}}{\sum_{x} J_{x, j}}\) |
Feed-side membrane-interface solute concentration |
\(C_{interface} = CP_{mod}C_{bulk}=C_{bulk}\exp(\frac{J_{solvent}}{k_f})-\frac{J_{solute}}{J_{solvent}}(\exp(\frac{J_{solvent}}{k_f})-1)\) |
Concentration polarization modulus |
\(CP_{mod} = C_{interface}/C_{bulk}\) |
Mass transfer coefficient |
\(k_f = \frac{D Sh}{d_h}\) |
Sherwood number |
\(Sh = 0.46 (Re Sc)^{0.36}\) |
Schmidt number |
\(Sc = \frac{\mu}{\rho D}\) |
Reynolds number |
\(Re = \frac{\rho v_f d_h}{\mu}\) |
Hydraulic diameter |
\(d_h = \frac{4\epsilon_{sp}}{2/h_{ch} + (1-\epsilon_{sp})8/h_{ch}}\) |
Cross-sectional area |
\(A_c = h_{ch}W\epsilon_{sp}\) |
Membrane area (flat-plate) |
\(A_m = LW\) |
Membrane area (spiral-wound) |
\(A_m = 2LW\) |
Pressure drop |
\(ΔP = (\frac{ΔP}{Δx})_{avg}L\) |
Feed-channel velocity |
\(v_f = Q_f/A_c\) |
Feed-channel volume |
\(V_{f} = LWh_{ch}\) |
Friction factor (flat-plate) |
\(f = 0.42+\frac{189.3}{Re}\) |
Friction factor (spiral-wound) |
\(f = \frac{6.23}{Re^{0.3}}\) |
Pressure drop per unit length |
\(\frac{ΔP}{Δx} = \frac{1}{2d_h}f\rho v_f^{2}\) |
Component recovery rate |
\(R_j = \frac{M_{p,j}}{M_{f,in,j}}\) |
Volumetric recovery rate |
\(R_{vol} = \frac{Q_{p}}{Q_{f,in}}\) |
Observed solute rejection |
\(r_j = 1 - \frac{C_{p,mix}}{C_{f,in}}\) |
Class Documentation
- class watertap.unit_models.reverse_osmosis_0D.ReverseOsmosis0D(*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
- dynamic
Indicates whether this model will be dynamic or not. default - False. Membrane units do not yet support dynamic behavior.
- has_holdup
Indicates whether holdup terms should be constructed or not. default - False. Membrane units do not have defined volume, thus this must be False.
- property_package
Property parameter object used to define property calculations, default - useDefault. Valid values: { useDefault - use default package from parent model or flowsheet, PhysicalParameterObject - a PhysicalParameterBlock object.}
- property_package_args
A ConfigDict with arguments to be passed to a property block(s) and used when constructing these. default - None. Valid values: { see property package for documentation.}
- material_balance_type
Indicates what type of mass balance should be constructed, default - useDefault. Valid values: { MaterialBalanceType.useDefault - refer to property package for default balance type MaterialBalanceType.none - exclude material balances, MaterialBalanceType.componentPhase - use phase component balances, MaterialBalanceType.componentTotal - use total component balances, MaterialBalanceType.elementTotal - use total element balances, MaterialBalanceType.total - use total material balance.}
- energy_balance_type
Indicates what type of energy balance should be constructed. default - useDefault. Valid values: { EnergyBalanceType.useDefault - refer to property package for default balance type EnergyBalanceType.none - exclude energy balances, EnergyBalanceType.enthalpyTotal - single enthalpy balance for material, EnergyBalanceType.enthalpyPhase - enthalpy balances for each phase, EnergyBalanceType.energyTotal - single energy balance for material, EnergyBalanceType.energyPhase - energy balances for each phase.}
- momentum_balance_type
Indicates what type of momentum balance should be constructed, default - MomentumBalanceType.pressureTotal. Valid values: { MomentumBalanceType.none - exclude momentum balances, MomentumBalanceType.pressureTotal - single pressure balance for material, MomentumBalanceType.pressurePhase - pressure balances for each phase, MomentumBalanceType.momentumTotal - single momentum balance for material, MomentumBalanceType.momentumPhase - momentum balances for each phase.}
- concentration_polarization_type
Options to account for concentration polarization.
default -
ConcentrationPolarizationType.calculated
Configuration Options
Description
ConcentrationPolarizationType.noneSimplifying assumption to ignore concentration polarization
ConcentrationPolarizationType.fixedSpecify an estimated value for the concentration polarization modulus
ConcentrationPolarizationType.calculatedAllow model to perform calculation of membrane-interface concentration
- mass_transfer_coefficient
Options to account for mass transfer coefficient.
default -
MassTransferCoefficient.calculated
Configuration Options
Description
MassTransferCoefficient.noneMass transfer coefficient not used in calculations
MassTransferCoefficient.fixedSpecify an estimated value for the mass transfer coefficient in the feed channel
MassTransferCoefficient.calculatedAllow model to perform calculation of mass transfer coefficient
- transport_model
Options to account for mass transfer model.
default -
TransportModel.SD”
TransportModel.SD”, “Solution-diffusion model for describing water and salt transport for most membrane types” “TransportModel.SKK”, “Speigler-Kedem-Katchalsky model for describing water and salt transport”- module_type
Options to account for geometry differences between flat sheet and spiral wound membranes.
default -
ModuleType.flat_sheet”
ModuleType.flat_sheet”, “Module type option for flat-sheet membrane modules” “ModuleType.spiral_wound”, “Module type option for spiral-wound membrane modules, this option accounts for how membranes in spiral-wound modules are folded which reduces the channel width by half”- has_pressure_change
Indicates whether terms for pressure change should be constructed, default - False. Valid values: { True - include pressure change terms, False - exclude pressure change terms.}
pressure_change_type Indicates what type of pressure change calculation will be made. To use any of the
pressure_change_typeoptions to account for pressure drop, the configuration keywordhas_pressure_changemust also be set toTrue. Also, if a value is specified for pressure change, it should be negative to represent pressure drop.default -
PressureChangeType.fixed_per_stageConfiguration Options
Description
PressureChangeType.fixed_per_stageSpecify an estimated value for pressure drop across the membrane feed channel
PressureChangeType.fixed_per_unit_lengthSpecify an estimated value for pressure drop per unit length across the membrane feed channel
PressureChangeType.calculatedAllow model to perform calculation of pressure drop across the membrane feed channel
- friction_factor
Options to account for friction factor correlations.
default -
FrictionFactor.default_by_module_type
Configuration Options
Description
FrictionFactor.default_by_module_typeFriction factor correlation that is specific to the supported membrane modules type
- has_full_reporting
Level of reporting results. default - False. Valid values: { False - include minimal reporting of results, True - report additional properties of interest that aren’t constructed by the unit model by default. Also, report averaged expression values
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:
(ReverseOsmosis0D) New instance
- class watertap.unit_models.reverse_osmosis_0D.ReverseOsmosisData(component)[source]
Standard RO Unit Model Class: - zero dimensional model - steady state only - single liquid phase only
References
Spiegler, K. S., & Kedem, O. (1966). Thermodynamics of hyperfiltration (reverse osmosis): criteria for efficient membranes. Desalination, 1(4), 311-326.