ecnet.blends¶
Analytical blend-property predictors and error helpers. See Units and numeric conventions for cloud point (°C) and kinematic viscosity (cSt) conventions.
- ecnet.blends.cetane_number(values, vol_fractions)[source]¶
Calculates blended CN from individual CNs, volume fractions of each individual CN in blend; blend assumed proportionally linear: NREL/SR-540-36805
- Args:
values (list[float]): CN values vol_fractions (list[float]): list of volume fractions, sum(vol_fractions) == 1.0
- Returns:
float: blended CN
- ecnet.blends.cloud_point(values, vol_fractions)[source]¶
Calculates blended CP from individual CPs, volume fractions of each individual CP in blend; from paper “Predictions of pour, cloud and cold filter plugging point for future diesel fuels with application to diesel blending models” by Semwal et al.
CP_{b}^{13.45} = sum_{i}^{N} V_{i} CP_{i}^{13.45}
Where V_i is the ith components weight percent, CP_i is the ith component’s CP, in Rankine, and CP_b is the blend’s CP, in Rankine
- Args:
values (list[float]): CP values, in Celsius vol_fractions (list[float]): list of volume fractions, sum(vol_fractions) == 1.0
- Returns:
float: blended CP, in Celsius
- ecnet.blends.exponential_blend_err(values, result, errors, proportions, a, b)[source]¶
Calculates the error of a blend whose equation is of the form f = a * A**b.
- Return type:
- Parameters:
- Args:
values (list[float]): predicted values result (float): resulting blend property value errors (list[float]): errors for predicted values in values proportions (list[float]): contribution of each value to blend; sum = 1 a (float): scalar coefficient preceeding variable A b (float): exponential coefficient which A is raised to
- Returns:
float: weighed exponential error
- ecnet.blends.kinematic_viscosity(values, vol_fractions)[source]¶
Calculates blended KV from individual KVs, volume fractions of each individual KV in blend; equation 8 from paper “Estimation of the kinematic viscosities of bio-oil/alcohol blends: Kinematic viscosity-temperature formula and mixing rules” by Ding et al.
1 / ln(2000 * kv_{blend}) = sum_{i}^{N} frac{V_i}{ln(2000 * kv_i)}
Where V_i is the volume fraction of the ith component, kv_i is the kinematic viscosity of the ith component, and kv_{blend} is the kinematic viscosity of the blend
- Args:
values (list[float]): KV values, in cSt vol_fractions (list[float]): list of volume fractions, sum(vol_fractions) == 1.0
- ecnet.blends.kv_error(values, errors, proportions)[source]¶
Calculate kinematic-viscosity blend error for f = a * ln(b * A).
For the implemented KV rule, a = 1.0 and b = 2000.
- Args:
values (list[float]): predicted values errors (list[float]): errors for predicted values in values proportions (list[float]): contribution of each value to blend; sum = 1
- Returns:
float: weighted inverse logarithmic error for KV blend
- ecnet.blends.linear_blend_err(errors, proportions)[source]¶
Propagate component errors for a linear blend (root-sum-square).
- ecnet.blends.lower_heating_value(values, vol_fractions)[source]¶
Calculates blended LHV from individual LHVs, volume fractions of each individual LHV in blend; blend assumed proportionally linear: https://doi.org/10.1016/j.ejpe.2015.11.002
- Args:
values (list[float]): LHV values vol_fractions (list[float]): list of volume fractions, sum(vol_fractions) == 1.0
- Returns:
float: blended LHV
- ecnet.blends.yield_sooting_index(values, vol_fractions)[source]¶
Calculates blended YSI from individual YSIs, volume fractions of each individual YSI in blend; blend assumed proportionally linear: https://doi.org/10.1016/j.fuel.2020.119522
- Args:
values (list[float]): YSI values vol_fractions (list[float]): list of volume fractions, sum(vol_fractions) == 1.0
- Returns:
float: blended YSI