Closed henningjp closed 8 months ago
Hmm...
As in the comment above, the paclet will only load on Windows 64-bit and Mathematica 13+, for now.
As of Mathematica 13, which the wrapper is limited to through the paclet, only 64-bit OS versions are supported. So we only need to search for the 64-bit REFPRP64 library.
Mathematica 13+ supports Windows, MacOS, and various Linux versions. See MM13 System Requirements and MM14 System Requirements. I have no way to test MacOS or Linux versions (or Mathematica licenses to do so). However,
$dllPath
and $NISTPath
variables to a Windows path structure, but this should be overwritten by either the $RPprefix setting or the paths set in the paclet resource file as set by SetDLL[]
and/or SetPath[]
.$Path
for "REFPRP64.DLL" or "REFPROP64.so" (I'm relying solely on $RPprefix, which may not be set on Linux?)That said, there is a note in the README.md that states (under Prerequisites):
NOTE: Development and testing of this wrapper has been entirely on a Microsoft Windows
installation using Mathematica 13 and REFPROP 10. This wrapper should work on a Linux
installation, but will require testing and may require some code modification. Care has been
taken to ensure that the paclet code uses Mathematica's OS-independent file manipulation tools.
However, I've actually tested it so far on Mathematica 13/14, Windows 10/11, and with REFPROP 9.1 and REFPROP 10.0.0.x. I'll update the README in a subsequent PR.
Shall we stop here with windows support and go for other platforms after?
Yeah, maybe. If there's another patch needed, Windows is all I got.
I don't have a Linux box or a Mac to build and test it. I can probably set up a Linux box on some spare hardware, but I don't know if I can get a Mathematica license for it ($). I'll dig into it. I'm not getting a Mac anytime soon. We only use Mathematica at work on Windows, so that was the focus. So, unless we can find someone else to help out...
A NIST grant for hardware and licenses? 😆 🤣
Ok, I'll merge this one.
I don't think any additional support is forthcoming from my side because I think Mathematica is not one of the most popular interfaces of REFPROP.
Several changes made to the RefpropLink paclet to better locate NIST REFPROP DLLs when installed in a non-standard location. Changes in Mathematica paclet structure caused method of storing path locations as resources was failing.
Changes include:
RPprefix
environment variable first (set by REFPROP installation)SetDLL[1]
andSetPath[1]
functions to store alternate locations in paclet resource file using MM13+ paclet structureSetDLL[-1]
andSetPath[-1]
to simply return current paths for DLL and Fluids location for debugging purposesTesting
SetDLL[]
SetPath[]
Additional Information
RefpropLink.wl
is python-like and should be easy enough to reviewRelated Issues
Fixes #581