From a278779178ec9f7ff1b8aeb1bb311e375ae46aac Mon Sep 17 00:00:00 2001 From: Harry Moffat Date: Sat, 6 Oct 2007 02:24:13 +0000 Subject: [PATCH] Fixed an error that affected the calculation of transport properties for mechanisms with all NASA9 species. The max and min temperatures weren't being computed, which caused NaN's to appear during the transport property data fitting procedure. --- Cantera/src/thermo/GeneralSpeciesThermo.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Cantera/src/thermo/GeneralSpeciesThermo.cpp b/Cantera/src/thermo/GeneralSpeciesThermo.cpp index 9b1a42350..1b28f9535 100644 --- a/Cantera/src/thermo/GeneralSpeciesThermo.cpp +++ b/Cantera/src/thermo/GeneralSpeciesThermo.cpp @@ -180,6 +180,15 @@ namespace Cantera { * Now, simply assign the position */ m_sp[index] = stit_ptr; + + /* + * Calculate max and min + */ + double minTemp = stit_ptr->minTemp(); + double maxTemp = stit_ptr->maxTemp(); + + m_tlow_max = max(minTemp, m_tlow_max); + m_thigh_min = min(maxTemp, m_thigh_min); } /**