From 0945a6de9bf7f00aeeff7235ba100720d95e749e Mon Sep 17 00:00:00 2001 From: Ray Speth Date: Wed, 19 Jun 2013 15:26:54 +0000 Subject: [PATCH] [clib] Enable access to critical properties of non-pure phases Previously, only the critical properties of PureFluidPhase objects could be accessed, but there are other ThermoPhase classes (specifically, RedlichKwongMFTP) which overload the critTemperature, critPressure, and critDensity functions. --- src/clib/ct.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/clib/ct.cpp b/src/clib/ct.cpp index ffe39b49d..911189e71 100644 --- a/src/clib/ct.cpp +++ b/src/clib/ct.cpp @@ -697,7 +697,7 @@ extern "C" { double th_critTemperature(int n) { try { - return ThermoCabinet::get(n).critTemperature(); + return ThermoCabinet::item(n).critTemperature(); } catch (...) { return handleAllExceptions(DERR, DERR); } @@ -706,7 +706,7 @@ extern "C" { double th_critPressure(int n) { try { - return ThermoCabinet::get(n).critPressure(); + return ThermoCabinet::item(n).critPressure(); } catch (...) { return handleAllExceptions(DERR, DERR); } @@ -715,7 +715,7 @@ extern "C" { double th_critDensity(int n) { try { - return ThermoCabinet::get(n).critDensity(); + return ThermoCabinet::item(n).critDensity(); } catch (...) { return handleAllExceptions(DERR, DERR); }