Open ianhbell opened 2 years ago
In 10.0, the same script yields much smaller round-trip error, but many failures:
10.0.0.02
10000075.525 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
10000085.330689656 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
10000095.13637931 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
10000104.942068966 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
10000114.747758621 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
10000124.553448277 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
-3.8824055081931874e-11
10000144.164827587 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
10000153.97051724 [HSFLSH error 260] h-s inputs are two-phase or out of bounds, iterative routine is not available to find a solution.
-8.895995051716454e-12
-3.808509063674137e-12
2.8421709430404007e-13
1.0800249583553523e-12
-6.821210263296962e-13
4.888534022029489e-12
1.3073986337985843e-12
8.799361239653081e-11
-5.400124791776761e-13
-9.663381206337363e-13
-3.007016857736744e-11
5.115907697472721e-13
-2.2737367544323206e-13
-1.2846612662542611e-11
-2.2737367544323206e-13
-2.326601133972872e-10
1.1368683772161603e-13
-1.5916157281026244e-12
1.0800249583553523e-12
-1.2789769243681803e-10
-2.3931079340400174e-10 [PSFLSH warning -235] Saturation state routine failed to converge and thus the phase is unknown; however, the state appears to be either single phase or metastable. Additional analysis is needed.
Description
Starting at a given temperature and vapor quality, calculating enthalpy and entropy, and then back-calculating temperature and density, the worst case errors in T are on the order of 0.1 mK. It's not terrible, but not great, and can be improved by iterating directly for temperature. Even the best points are still in error by 1e-5 K, and this should be able to be reduced by at least 4 orders of magnitude.
Example
yields