* attempt to add fugacity functions needed for CoolProp.jl
* address first round of PR edits
change std:size_t to long
remove get_fugacity_coefficients
add .def exports
* remove fugacity refs in CoolPropLib.def
* Add AbstractState functions to CoolPropLib
AbstractState_get_mole_fractions_satState
AbstractState_keyed_output_satState
AbstractState_backend_name
add_fluids_as_JSON
* Overloaded AbstractState_get_phase_envelope_data and appended checkedMemory to function name
* Add parser for HMX.BNC from REFPROP; closes#1294
Also move configuration variables into main pybind11 module
* Add the ability to over-write departure functions and binary interaction parameters
* Added first working version of VTPR;
* Get VTPR building hopefully
* Remove more constant iterators
* Make VTPR accessible through factory
* One last const iterator
* Fix a_alpha bug and make sqrt(2) into sqrt(2.0)
* Added analytic first derivative for VTPR
* Fix another set of sqrt(2) -> sqrt(2.0)
* Add some info on the derivatives for VTPR
Looks less hopeless than I had feared
* gE/RT needs to be multiplied by RT; closes#1161
* Added first working version of VTPR;
* Get VTPR building hopefully
* Remove more constant iterators
* Make VTPR accessible through factory
* One last const iterator
* Fix a_alpha bug and make sqrt(2) into sqrt(2.0)
* Added analytic first derivative for VTPR
* Fix another set of sqrt(2) -> sqrt(2.0)
* Add some info on the derivatives for VTPR
Looks less hopeless than I had feared
* gE/RT needs to be multiplied by RT; closes#1161
* Add VTPR code from @JonWel (#1194)
* 1rst draft to implement a simple volume translation to cubics
* A bit more of VT
* Derivatives for volume translation
* Better cm initialisation
* Solves the cubic equation with volume translation
* Correct the volume translation analytic development
Looks good now
* Update VTPR to be able to use volume translation
* Unprotect cm_term
This allows it to be used from the VTPR backend
* Update CoolPropLib.def
* Better derrivative of PI_12
The expression is simpler this way
* Solves #1176
Thanks @ibell
* Change the way the volume translation parrameter is set
* Start the bm derivatives for VTPR
* Correct one derivative
* Small bug
* Better bm derivatives for VTPR
* Add am and bm component derivatives for VTPR
@ibell I did not check yet the component derivatives of this commit, bu I checked the other ones with your code.
I'll have to addapt your code to also check these ones.
I separate the `am_term` and `bm_term` as the `am_bm_term` function was called twice. This reduce the call to the am_term part as this part ends up being called only once, and this helped writing the component derivatives.
The tau derivative is done numerically untill we find time to develop the analytical one.
The `am_bm_term` function started with a `set_temperature()`. I did not checked yet why this is needed and put this set temperature at the beginning of each of the `am_term` component derivatives.
I'll try to addapt the checking code tomorow.
* tab to spaces
* Re-writing of cubic coefficients
Introducing 3 intermediary varriables that simplify the cubic's coefficient with the volume translation.
* 1rst draft to implement a simple volume translation to cubics
* A bit more of VT
* Derivatives for volume translation
* Better cm initialisation
* Solves the cubic equation with volume translation
* Correct the volume translation analytic development
Looks good now
* Update VTPR to be able to use volume translation
* Unprotect cm_term
This allows it to be used from the VTPR backend
* Update CoolPropLib.def
* Better derrivative of PI_12
The expression is simpler this way
* Solves #1176
Thanks @ibell
* Change the way the volume translation parrameter is set
* Start the bm derivatives for VTPR
* Correct one derivative
* Small bug
* Better bm derivatives for VTPR
* Add am and bm component derivatives for VTPR
@ibell I did not check yet the component derivatives of this commit, bu I checked the other ones with your code.
I'll have to addapt your code to also check these ones.
I separate the `am_term` and `bm_term` as the `am_bm_term` function was called twice. This reduce the call to the am_term part as this part ends up being called only once, and this helped writing the component derivatives.
The tau derivative is done numerically untill we find time to develop the analytical one.
The `am_bm_term` function started with a `set_temperature()`. I did not checked yet why this is needed and put this set temperature at the beginning of each of the `am_term` component derivatives.
I'll try to addapt the checking code tomorow.
* tab to spaces
* Re-writing of cubic coefficients
Introducing 3 intermediary varriables that simplify the cubic's coefficient with the volume translation.
* Cubic calc_molar_mass, closes#1124
* Add simplified update and output functions
This allows simpler use of the low level interface by using the strings name instead of the parameter number.
The parameter number version stays and will be faster for more than one call with the same parameter.
* Add AbstractState_update_and_1_out
* Export specify_phase() to the library
* small correction
Safer to only accept an array of real numbers here.
* Small correction
Specifying the type of the array to avoid any convertion
* Precompiling of Julia Wrapper only for Julia 0.4+
Should allow to keep compatibility with Julia 0.3
* Export set_binary_interaction_double
to the shared library and add it to Julia Wrapper
* Correct comment in previous commit
* Change tab to spaces in precendent commit
* Add update_and_*_out functions
Add `AbstractState_update_and_common_out` and `AbstractState_update_and_5_out` to the wrapper
* Update .gitignore
1. Another set of arguments optimized:
* args-by-val converted to args-by-ref
* in some cases, reverse has been done, if that is better: if the
object's copy is modified in the func, it's better to avoid extra copy
from arg to local var
2. some const functions marked as such (this is just a beginning)
3. iterators were replaced with const_iterators where applicable
4. catches that catch std::exception& changed to catch (...) - that is
safer; if exception handling is restructured, this will have to be
reconsidered anyway
5. removed some basic structures' constructors; changed them to hold
const char*s to avoid unnecessary string constructions;
6. in some places, moved variable declarations to their definitions, to
avoid calling default constructors and then assigning
7. removed some unnecessary shared_pointers in favor of local objects;
8. in FORTRAN-style functions, added const specifiers to input doubles;
9. fixed a place where values were inserted into a map while iterating
through it
10. fixed is_valid_*_derivative: they could accept incorrect values and
throw when upper index is less than lower
Added PhaseSI function which will return phase for given input - exposed to DLL
PropsSI can also return phase as double if "Phase" is the input
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>