get_mix_vals#
- Mixture.get_mix_vals(propname, mode='linear', power=1)[source]#
Get the mole fraction weighted value of a given property for the mixture
- Parameters:
propname (str) – The property to fetch, such as
'pore.viscosity'
.mode (str) –
The type of weighting to use. Options are:
mode
’linear’
(default) Basic mole fraction weighting of the form: \(z = \Sigma (x_i \cdot \z_i)\)
’logarithmic’
Uses the natural logarithm of the property as: \(ln(z) = \Sigma (x_i \cdot ln(\z_i))\)
’power
Applies an exponent to the property as: \(\z^{power} = \Sigma (x_i \cdot \z_i^{power})\)
power (scalar) – If
mode='power'
this indicates the value of the exponent, otherwise this is ignored.
- Returns:
vals – An ndarray with the requested values obtained using the specified weigthing.
- Return type:
ndarray