Commit Graph

186 Commits

Author SHA1 Message Date
Ian Bell
799422fe40 Implemented generalized second derivative, seems to work, implemented at PropsSI level too
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-24 17:26:46 +02:00
Ian Bell
4b082029c4 Finally repaired flash routines.
Some edge cases remain

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-24 13:40:46 +02:00
Ian Bell
d3261395bf Replaced all fabs() with std::abs()
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-23 14:56:07 +02:00
Ian Bell
cd8ee9eb52 Added code and tests for saturation ancillaries (p, rho', rho'')
Closes https://github.com/CoolProp/CoolProp/issues/75

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-23 13:01:56 +02:00
Ian Bell
69bbdc693b Reimplemented critical region splines all the way from scripts to build to C++ code
Closes https://github.com/CoolProp/CoolProp/issues/94

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-22 22:14:48 +02:00
Ian Bell
ab98aae25d Added cross-references for transport flags 2014-08-21 01:17:54 +02:00
Ian Bell
b4ff7a8cc5 Implemented viscosity for cyclohexane from Tariq, 2014.
Added unit tests, reformulated initial density term

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-21 00:50:57 +02:00
Ian Bell
b4b24ae1a3 Fixed macros for POW2, POW3, etc.
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-21 00:45:53 +02:00
Ian Bell
0dcdf7ef5d Implemented PQ for pseudo-pure to close https://github.com/CoolProp/CoolProp/issues/92
* As a consequence, made update function take CoolProp::input_pairs enum as first input (thanks @jowr for the idea)
* Decoupled the pre_update and post_update functions in order to allow for more creative update functions using guess values, etc.

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-20 21:44:13 +02:00
Ian Bell
f43a0b792b Humid air properties now use string instead of char*
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-19 21:55:23 +02:00
Ian Bell
881a6c4616 Added handling for first partial derivative as a string - added tests - they pass
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-19 00:34:26 +02:00
Ian Bell
e32dfcf255 Updates to docs
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-19 00:30:56 +02:00
Ian Bell
ad15288c23 Byebye to Armadillo (maybe reconsider later on)
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-18 19:28:00 +02:00
Ian Bell
39a99e183c Removed _forceSinglePhase, _forceTwoPhase (not used), specify_phase() should be used instead
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-18 19:25:25 +02:00
Ian Bell
9293c6355c For posterity's sake, a version using armadillo - not an improvement... slower than Eigen
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-18 09:47:02 +02:00
Ian Bell
f7464fcaa2 Implemented Eigen solution for all() function, speed testing next
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-17 21:09:27 +02:00
Ian Bell
9a1a0122e3 Renamed Derivatives to HelmholtzDerivatives; they all check fine
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-16 14:26:25 +02:00
Ian Bell
5cad463158 Parallel derivatives finished for NonAnalytic term
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-16 14:11:27 +02:00
Ian Bell
68d3725ffd Added tests for undefined parameters; documented undocumented parameters
Closes https://github.com/CoolProp/CoolProp/issues/97

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-16 12:40:35 +02:00
Ian Bell
c1e9455cb2 Reset the values for the Generalized Exponential term
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-16 01:27:38 +02:00
Ian Bell
eee8139306 SAFT has transitioned to parallel evaluation of derivatives, though it isn't truly parallel since there is some duplication
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-15 22:34:24 +02:00
Ian Bell
29632c72e6 Transition complete to generalized exponential term
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-15 22:03:40 +02:00
Ian Bell
2270f9f076 Helmholtz derivatives are all calculated using parallel code - next step is to remove classes from Helmholtz
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-15 21:16:41 +02:00
Ian Bell
61bc24e7b1 phases is now an enum, added (non-working) critical region VLE solver
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-15 17:13:00 +02:00
Ian Bell
c3508c3f55 Added parallel evaluation of residual helmholtz terms
Should in the end only slow down by 1.2x, but calculate at least up to second order derivatives all at once, so net speedup of 5 if calculating all first and second order partials !!

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-15 15:42:47 +02:00
Ian Bell
a84edcdb57 Implemented saturation P 1D solver for low pressure for some fluids like n-Propane
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-13 11:24:27 +02:00
Ian Bell
f7c0cb0b06 Relaxed some pressure domain checks and pass state by reference
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-12 23:40:16 +02:00
Ian Bell
36620cdc94 Fixed parameters in AbstractState header - SWIG is not pleased
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-12 22:25:24 +02:00
Ian Bell
8f9c6ca438 Added hs_anchor test (passing) and function get_state to allow to get access to states stored in the backends
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-12 21:17:34 +02:00
Ian Bell
e4c8d3f061 Python wrapper is more or less back in action completely. Additional testing is required.
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-12 16:25:33 +02:00
Ian Bell
802495cad3 Last commit before rename of python module to CoolProp
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-12 15:07:57 +02:00
Ian Bell
b7bd58d986 More work on flash routines, number of failures is rapidly decreasing - still have problems for low pressure sat_p calcs
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-12 11:21:12 +02:00
Ian Bell
36d601490f Lots more work on melting curves, can now make pretty phase diagram for water including the melting line 2014-08-10 19:28:04 +02:00
Ian Bell
c3cc696080 P,Y now works if P > pc
Add supercritical_gas and supercritical_liquid phase flags for a bit finer granularity

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-09 15:10:09 +02:00
Ian Bell
801aa61485 Implemented psat_max and Tsat_max for pseudo-pure fluids to close https://github.com/CoolProp/CoolProp/issues/89 2014-08-09 12:17:44 +02:00
Ian Bell
faf530d588 Fixed melting curves, PY flash works for subcritical cases 2014-08-09 11:07:21 +02:00
Ian Bell
8e3f4f183b Moved ancillaries into their own header
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-09 10:56:21 +02:00
Ian Bell
1aec75df85 PY subcrit superheated tests pass
There was a typo in umass() function

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-08 11:26:35 +02:00
Ian Bell
dedbd3dccb Updated shared_ptr header to allow it to be used with clang on linux independent of runtime library 2014-08-07 19:45:01 +02:00
Ian Bell
a3a122c6eb Finally comprehensively fixed the shared_ptr header - more cleaning can be done I guess, but most cases are covered here I think. 2014-08-07 02:52:14 +02:00
Ian Bell
2c844597c9 Calculate pressure and temperature limits for HEOS and REPFPROP backends
Closes https://github.com/CoolProp/CoolProp/issues/83

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-06 10:23:10 +02:00
Ian Bell
d5ad1e371b Merge branch 'master' of https://github.com/coolprop/coolprop 2014-08-04 18:58:30 +02:00
Ian Bell
138135f5b7 Added Tmin and Tmax
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-04 18:58:13 +02:00
jowr
4f9df69c96 No problems compiling and running the tests... 2014-08-04 17:14:35 +02:00
Ian Bell
23337e4035 Update crossplatform_shared_ptr.h 2014-08-04 01:15:36 +02:00
Ian Bell
3f8e91d86f Think I fixed OSX shared_ptr bug 2014-08-04 01:02:29 +02:00
Ian Bell
79d7a4965a Added triple point temperature
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-03 23:58:16 +02:00
Ian Bell
17458261b5 Modifications to saturation routines (work great now)
Including:
adding critical pressure parameter
Adding relaxation parameter for NR sat_T
Only evaluate correction step if not near critical temp
Fixed bug with fluids like "n-Propane" that was getting interpreted as an incompressible fluid

Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-03 23:36:22 +02:00
Ian Bell
a2f45e29da Added functionality for trivial outputs
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-03 18:55:52 +02:00
Ian Bell
d1c3a19d24 Fixed include for OSX hopefully
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
2014-08-03 16:39:24 +02:00