Hello matminer team!
Thank you for this excellent library! I'm using WenAlloys for research on Fe-Si-Al Sendust alloys and would like to follow up on Issue #954 (December 2025) regarding the configurational entropy formula.
I can confirm that this issue still exists and have identified an additional related error in the mixing enthalpy calculation.
Issue 1: Missing negative sign in configurational entropy [Related to Issue #954]
Current implementation (matminer v0.1.0, compute_configuration_entropy):
ΔSmix = R * Σ(ci * ln(ci))
Should be (Guo, 2015, Equation 1):
ΔSmix = -R * Σ(ci * ln(ci))
Impact: Without the negative sign, ΔSmix becomes negative (since ln(ci) < 0 for ci < 1), which is physically incorrect. Configurational entropy must be positive for random solid solutions.
Issue 2: Incorrect use of absolute value in mixing enthalpy
Current implementation (appears to use abs() in some calculations):
ΔHmix = abs(Σ 4 * ci * cj * ΔHij)
Impact: The sign of ΔHmix indicates bonding character:
ΔHmix < 0: attractive interactions (ordered phases, intermetallics)
ΔHmix > 0: repulsive interactions (phase separation)
Taking absolute value removes this critical information.
Issue 3: Yang Omega parameter affected by above errors
Yang Omega (Ω) should be:
Ω = (Tm * ΔSmix) / |ΔHmix|
Note: Modulus is needed ONLY for Omega, not for ΔHmix itself.
Due to:
ΔSmix having wrong sign (negative instead of positive)
ΔHmix potentially using absolute value incorrectly
The Omega parameter gives incorrect predictions for solid solution formation (Ω > 1.1 criterion).
Issue 4: Yang Omega calculation requires manual Tm computation
Problem: The base class WenAlloys.featurize() calculates Yang Omega internally using the original (incorrect) ΔSmix and ΔHmix formulas. Simply overriding compute_configuration_entropy() and compute_enthalpy() methods is insufficient because:
The base class has already computed Omega before returning the feature vector
The corrected ΔSmix and ΔHmix values don't propagate to the Omega calculation
Mean melting temperature (Tm) is calculated internally and cannot be accessed
Required fix: The entire featurize() method must be overridden to:
Use corrected ΔSmix (positive value)
Use corrected ΔHmix (with sign)
Manually calculate Tm to ensure transparency
Recalculate Yang Omega with correct formula: Ω = (Tm * ΔSmix) / |ΔHmix|
Manual Tm calculation:
# Mean melting temperature must be calculated manually
# because base class computes Omega internally with incorrect values
melting_temps = [self.data_source_magpie["MeltingT"][e] for e in elements]
Tm = PropertyStats.mean(melting_temps, fractions)
# Recalculate Yang Omega with corrected values
H_mixing_abs = max(1e-6, abs(H_mixing)) # abs() only in denominator
yang_omega_corrected = (Tm * S_config) / H_mixing_abs
Impact: Without manual Tm calculation and featurize() override, Yang Omega remains incorrect even if individual methods are fixed, leading to wrong phase stability predictions.
Proposed fix
Key corrections to the formulas:
- Configurational entropy (add negative sign)
@staticmethod
def compute_configuration_entropy(fractions):
"""Corrected ΔSmix with proper sign per Guo (2015), Eq. 1"""
return -np.dot(fractions, np.log(fractions)) * 8.314 / 1000
Impact: ΔSmix is now positive for random solutions (was negative).
- Mixing enthalpy (preserve sign)
def compute_enthalpy(self, elements, fractions):
"""Corrected ΔHmix preserving sign per Guo (2015), Eq. 3"""
enthalpy = 0
for i, e1 in enumerate(elements):
for j, e2 in enumerate(elements[:i]):
enthalpy += (
fractions[i] * fractions[j] *
self.data_source_enthalpy.get_mixing_enthalpy(
Element(e1), Element(e2)
)
)
return enthalpy * 4 # Sign preserved!
Impact: Bonding information retained (attractive vs repulsive).
- Override featurize() with manual Tm and Omega calculation
def featurize(self, comp):
"""
Complete override required because base class calculates
Yang Omega internally with incorrect ΔSmix and ΔHmix.
"""
# ... [standard feature calculations] ...
# Corrected values
S_config = self.compute_configuration_entropy(fractions) # Now positive
H_mixing = self.compute_enthalpy(elements, fractions) # Sign preserved
# Manual Tm calculation for transparency and correctness
melting_temps = [self.data_source_magpie["MeltingT"][e] for e in elements]
Tm = PropertyStats.mean(melting_temps, fractions)
# Corrected Yang Omega: Ω = (Tm * ΔSmix) / |ΔHmix|
H_mixing_abs = max(1e-6, abs(H_mixing)) # abs() only here!
yang_omega_corrected = (Tm * S_config) / H_mixing_abs
return [
...
yang_omega_corrected, # Position - now correct
...
S_config, # Position - now positive
...
H_mixing, # Position - sign preserved
...
]
Why full override is necessary:
Fixes cascading effect: corrected ΔSmix → corrected Omega
Ensures calculation order: Tm → ΔSmix → ΔHmix → Omega
Provides transparency in Tm computation
Prevents using cached/internal incorrect values
Implementation
I have already implemented and tested these corrections in my research project:
https://github.com/Niccuby/Sendust-ml-featurization-SHAP/ (/scripts folder)
The implementation includes:
Corrected compute_configuration_entropy() with negative sign
Corrected compute_enthalpy() preserving sign information
Complete featurize() override with manual Tm calculation
Validation on Fe-Si-Al Sendust alloys dataset
Reference
Guo, S. (2015). Phase selection rules for cast high entropy alloys: An overview. Materials Science and Technology, 31(10), 1-7. doi:10.1179/1743284715Y.0000000018
The implementation includes:
- Corrected compute_configuration_entropy() with negative sign
- Corrected compute_enthalpy() preserving sign information
- Complete featurize() override with manual Tm calculation
- Validation on Fe-Si-Al Sendust alloys dataset
You're welcome to use this code directly, or I can submit a formal Pull Request
with proper integration into matminer's structure and unit tests if you confirm
this is indeed an error.
Hello matminer team!
Thank you for this excellent library! I'm using WenAlloys for research on Fe-Si-Al Sendust alloys and would like to follow up on Issue #954 (December 2025) regarding the configurational entropy formula.
I can confirm that this issue still exists and have identified an additional related error in the mixing enthalpy calculation.
Issue 1: Missing negative sign in configurational entropy [Related to Issue #954]
Current implementation (matminer v0.1.0, compute_configuration_entropy):
ΔSmix = R * Σ(ci * ln(ci))
Should be (Guo, 2015, Equation 1):
ΔSmix = -R * Σ(ci * ln(ci))
Impact: Without the negative sign, ΔSmix becomes negative (since ln(ci) < 0 for ci < 1), which is physically incorrect. Configurational entropy must be positive for random solid solutions.
Issue 2: Incorrect use of absolute value in mixing enthalpy
Current implementation (appears to use abs() in some calculations):
ΔHmix = abs(Σ 4 * ci * cj * ΔHij)
Impact: The sign of ΔHmix indicates bonding character:
ΔHmix < 0: attractive interactions (ordered phases, intermetallics)
ΔHmix > 0: repulsive interactions (phase separation)
Taking absolute value removes this critical information.
Issue 3: Yang Omega parameter affected by above errors
Yang Omega (Ω) should be:
Ω = (Tm * ΔSmix) / |ΔHmix|
Note: Modulus is needed ONLY for Omega, not for ΔHmix itself.
Due to:
ΔSmix having wrong sign (negative instead of positive)
ΔHmix potentially using absolute value incorrectly
The Omega parameter gives incorrect predictions for solid solution formation (Ω > 1.1 criterion).
Issue 4: Yang Omega calculation requires manual Tm computation
Problem: The base class WenAlloys.featurize() calculates Yang Omega internally using the original (incorrect) ΔSmix and ΔHmix formulas. Simply overriding compute_configuration_entropy() and compute_enthalpy() methods is insufficient because:
The base class has already computed Omega before returning the feature vector
The corrected ΔSmix and ΔHmix values don't propagate to the Omega calculation
Mean melting temperature (Tm) is calculated internally and cannot be accessed
Required fix: The entire featurize() method must be overridden to:
Use corrected ΔSmix (positive value)
Use corrected ΔHmix (with sign)
Manually calculate Tm to ensure transparency
Recalculate Yang Omega with correct formula: Ω = (Tm * ΔSmix) / |ΔHmix|
Manual Tm calculation:
Impact: Without manual Tm calculation and featurize() override, Yang Omega remains incorrect even if individual methods are fixed, leading to wrong phase stability predictions.
Proposed fix
Key corrections to the formulas:
Impact: ΔSmix is now positive for random solutions (was negative).
Impact: Bonding information retained (attractive vs repulsive).
Why full override is necessary:
Fixes cascading effect: corrected ΔSmix → corrected Omega
Ensures calculation order: Tm → ΔSmix → ΔHmix → Omega
Provides transparency in Tm computation
Prevents using cached/internal incorrect values
Implementation
I have already implemented and tested these corrections in my research project:
https://github.com/Niccuby/Sendust-ml-featurization-SHAP/ (/scripts folder)
The implementation includes:
Corrected compute_configuration_entropy() with negative sign
Corrected compute_enthalpy() preserving sign information
Complete featurize() override with manual Tm calculation
Validation on Fe-Si-Al Sendust alloys dataset
Reference
Guo, S. (2015). Phase selection rules for cast high entropy alloys: An overview. Materials Science and Technology, 31(10), 1-7. doi:10.1179/1743284715Y.0000000018
The implementation includes:
You're welcome to use this code directly, or I can submit a formal Pull Request
with proper integration into matminer's structure and unit tests if you confirm
this is indeed an error.