more mass balances, solvent balances and volume balances #3
Labels
enhancement
New feature or request
help wanted
Extra attention is needed
pending clear need
a feature without a clear need, but useful
More mass balances, solvent balances
with MoistAir.jl i added a new Compounds type,
HumiditySpec
, and that spec contains an specification called "humid molar fraction". the thing with this spec is that be generalized. If we have a solution of n compounds, composed of a solvent(n[x]
) and solutes (n[not(x)]
), then new balances can be specified, for example:new material amounts:
where
XOfOne
represents the material amount of 1 compound in a list of many (water in air), andXRemaining
is the material amount of all compounds except one (for example, a list of solutes in water)a proper interface would be by passing a
Pair
( aTuple
is also reasonable, but thePair
, in my opinion, express intent: at this position there are x moles):also mol fractions, mass fractions, mol numbers and mass numbers can be specified with
MassOfOne
,MolesOfOne
,MolesRemaining
,MassRemaining
.To abreviate:
mass1,moles1 = a MaterialAmount with MolesOfOne or MassOfOne
massR,molesR = a MaterialAmount with MolesRemaining or MassRemaining
Same with MaterialCompounds
now we need to view the conjugations:
MaterialCompounds seems to not make sense if the number of compounds > 2xn1,xm1 -> nR,mR
so, this is aproximately 16 new balances that can be added.
volume balances
for volume balances, you can define:
volume fraction :
(MaterialCompounds{VOLUME,FRACTION}
(xvols)volume number :
(MaterialCompounds{VOLUME,FRACTION}
(vols)where volume fraction is the fraction of volumes that each compound have in a mix (dont confuse with volumes before mixing, as
mixing_volume != sum(volumes)
)the trickiest part is defining a correct balance here, to make a complete state specification:
xvols
requires a volume amount and any material compound-the only resolution for vols is to make the assumption of mixing volume = sum(volumes). as a state doesnt assume anything, this can't be done (in ThermoState). It can be added, but the balance machinery must another package that requires it.vols
requires any material compoundin summary, those balances can be added to ThermoState, but a clear need must be found and then, look for:
xvols
, find the apropiate balances. ((mass,moles) and total volume is trivial, but i dont know the rest)The text was updated successfully, but these errors were encountered: