Seawater Library for Python
This is a Python re-write of the CSIRO seawater toolbox (SEAWATER-3.3) for calculating the properties of sea water. The package uses the formulas from Unesco’s joint panel on oceanographic tables and standards, UNESCO 1981 and UNESCO 1983 (EOS-80).
The EOS-80 library is considered now obsolete; it is provided here for compatibility with old scripts, and to allow a smooth transition to the new TEOS-10.
The Python version default output unit for sw.dist is ‘km’ instead of ‘nm’.
Here we assume pressure as the first dimension, i.e. M pressure by N positions (See the table below). The MatlabTM version does some guessing at this that we simply ignore to avoid confusions.
The current version was tested against the MatlabTM seawater v3.3 reproducing all functions and results from that release.
More information at http://pythonhosted.org/seawater
- Unified code base for python 2 and 3, we no longer use 2to3 to convert.
- Fixed py3k bug that prevent installation.
- Both gpan and bfrq accepts 3D arrays now.
- Fixed inconsistency in use of ITS-90 and increased convergence precision from 1e-4 to 1e-10 for cndr. Note: Not sure if this fix is needed. However, it is in the original version!
- Corrected sign of potential vorticity in bfrq.
- Added swvel to compute surface wave velocity.
- Converted code so that temperature is now ITS-90 throughout.
- Coding changes to enable functions to return the same shape vector as the input arguments. In previous releases, some functions returned column vectors for row vector input. Also some other tidying up.
- New routine satAr. Solubility of Ar in seawater.
- New routine satN2. Solubility of N2 in seawater.
- New routine satO2. Solubility of O2 in seawater.
- Updated test to include tests for above.
- Fixed bug in alpha where temp used in calculations regardless of the keyword.
- bfrq now also returns potential vorticity. Thanks to Greg Johnson (email@example.com).
- OMEGA=7.29e-5 was changed to OMEGA=7.292e-5 in gvel to be consistent with f.
- Important API change: The usage of alpha, beta and aonb routines has changed! All these routines expect (S,T,P) to be passed instead of (S,PTMP,P) as in previous releases of seawater. Fast execution can still be obtained by passing ptmp=True.
- Fixed a bug in bfrq where empty LAT was needed as argument when no latitude values are being passed.
- Now pass PRESSURE instead of DEPTH, more consistent though only a negligible change is answers.
- First official release and announcement on the networks.
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size seawater-3.3.4.tar.gz (22.9 kB)||File type Source||Python version None||Upload date||Hashes View hashes|