MHKiT-Software / MHKiT-MATLAB

MHKiT-MATLAB provides the marine renewable energy (MRE) community tools for data processing, visualization, quality control, resource assessment, and device performance.
https://mhkit-software.github.io/MHKiT/
BSD 3-Clause "New" or "Revised" License
15 stars 23 forks source link

Correctly map `Hs` argument in `jonswap_spectrum` #133

Closed simmsa closed 3 days ago

simmsa commented 1 month ago

This fixes a bug, described in #132, where the Hs argument input into the jonswap_spectrum function is not properly mapped to the corresponding mhkit.wave.resource.jonswap_spectrum function. This maps Hs into the 3rd argument of jonswap_spectrum when the gamma parameter is passed. Test failures are expected until this is rebased to include #131.

simmsa commented 1 week ago

@rpauly18 and @hivanov-nrel, this is good to go. This is a simple fix and test for the jonswap_spectrum function. Prior to this addition we were not passing the Hs argument to MHKiT-Python. This fix passes Hs to MHKiT-Python when the number of inputs is 4.