modelPartialSpeciationWithSubunitsDefinition

Chemical speciation
Diagram of PartialSpeciationWithSubunitsDefinition

Extends from Chemical.Processes.Internal.PartialSpeciation (Chemical Speciation).

Information

s1·S1 + .. + snS·SnS <-> p1·P1 + .. + pnP·PnP

By redefinition of stoichometry as vi = -si, Ai = Si for i=1..nS vi = pi-nS, Ai = Pi-nS for i=nS+1..nS+nP

So the reaction can be written also as 0 = ∑ (vi · Ai)

Equilibrium equation

K = product(a(S).^s) / product( a(P).^s ) = product(a(A).^v) 

dissociation constant

ΔrG = ∑ (vi · ΔfGi) = ΔrH - T·ΔrS = -R·T·log(K)

molar Gibb's energy of the reaction

ΔrH = ∑ (vi · ΔfHi)

molar enthalpy of the reaction

ΔrS = ∑ (vi · ΔfSi) = k·log(Δrω)

molar entropy of the reaction

Notations

Ai

i-th substance

vi

stochiometric coefficients of i-th substance

K

dissociation constant (activity based)

a(Ai)=fi*xi

activity of the substance A

fi

activity coefficient of the substance A

xi

mole fraction of the substance A

ΔfHi

molar enthalpy of formation of i-th substance

ΔfGi

molar Gibbs energy of formation of i-th substance

ΔfSi

molar entropy of formation of i-th substance

Δrω

change of number of microstates of particles by reaction

Parameters

TypeNameDefaultDescription
Chemical.Interfaces.DefinitionfirstForeSubunitdropOfCommons.DefaultSubstanceFirst product definition
Chemical.Interfaces.Definition[:]nextForeSubunitsfill(dropOfCommons.DefaultSubstance, max(1, nP - 1))Definitions of next subunit_fore
Chemical.Interfaces.DefinitionprocessChemical.Interfaces.processData(1)Process changes of Gibbs energy, enthalpy, volume and heat capacity (subunit_fore - reactants)
Advanced
Modelica.Units.SI.MolarFlowRaten_flow_reg (from PartialSpeciation)dropOfCommons.n_flow_regRegularization threshold of mass flow rate
StateSelectn_flowStateSelect (from PartialSpeciation)StateSelect.defaultState select for n_flow
Modelica.Units.SI.TimeTC (from PartialSpeciation)0.1Time constant for electro-chemical potential adaption
Utilities.Units.InertanceL (from PartialSpeciation)dropOfCommons.LInertance of the flow
Initialization › Molar flow
InitializationMethodsinitN_flow (from PartialSpeciation)Chemical.Utilities.Types.InitializationMethods.noneInitialization method for n_flow
Modelica.Units.SI.MolarFlowRaten_flow_0 (from PartialSpeciation)0Initial value for n_flow
Utilities.Units.MolarFlowAccelerationn_acceleration_0 (from PartialSpeciation)0Initial value for der(n_flow)
General › Ports
IntegernS (from PartialSpeciation)0Number of subunits in rear macromolecule state
IntegernP (from PartialSpeciation)0Number of subunits in fore macromolecule state
Conditional inputs
FirstProductChoicefirstForeSubunitFromFirstProductChoice.ProcessFirst product definition comes from?

Connectors

TypeNameDefaultDescription
Chemical.Interfaces.Rear[nS]subunit_rear (from PartialSpeciation)Subunits in rear macromolecule state
Chemical.Interfaces.Fore[nP]subunit_fore (from PartialSpeciation)Subunits in fore macromolecule state
Interfaces.SolutionPortsolution_rear (from PartialSpeciation)To connect solution of subunits with rear state of macromolecule
Interfaces.SolutionPortsolution_fore (from PartialSpeciation)To connect solution of subunits with fore state of macromolecule
Chemical.Interfaces.SolutionPortsolution (from PartialSpeciation)To connect substance with solution, where is pressented

Components

TypeNameDefaultDescription
Modelica.Units.SI.MolarFlowRaterr (from PartialSpeciation)Molar flow rate of change macromolecule from rear state to fore state
Modelica.Units.SI.AmountOfSubstancenm_fore (from PartialSpeciation)Amount of the macromolecule in fore state
Modelica.Units.SI.AmountOfSubstancenm_rear (from PartialSpeciation)Amount of the macromolecule in rear state
Modelica.Units.SI.MoleFractionxm_fore (from PartialSpeciation)Mole fraction of the macromolecule in fore state
Modelica.Units.SI.MoleFractionxm_rear (from PartialSpeciation)Mole fraction of the macromolecule in rear state
Chemical.Interfaces.SolutionStatesolutionState (from PartialSpeciation)
Chemical.Interfaces.Definitionmacromolecule_rear (from PartialSpeciation)Specific rear state of macromolecule composed only with connected subunits
Chemical.Interfaces.Definitionmacromolecule_fore (from PartialSpeciation)Specific fore state of macromolecule composed only with connected subunits
Reali (from PartialSpeciation)
RealdH (from PartialSpeciation)
RealdV (from PartialSpeciation)
Realnj (from PartialSpeciation)
Realmj (from PartialSpeciation)
RealVj (from PartialSpeciation)
RealGj (from PartialSpeciation)
RealQj (from PartialSpeciation)
RealIj (from PartialSpeciation)
Real[nS]RTlnxm_rear (from PartialSpeciation)
Real[nP]RTlnxm_fore (from PartialSpeciation)

Revisions

2013-2020 by Marek Matejak, Charles University, Prague, Czech Republic