Skip to content

Conversation

@jtgrasb
Copy link
Contributor

@jtgrasb jtgrasb commented Aug 8, 2025

This PR fixes the nonlinear hydro calculation for cases with wave spreading. The spread term is moved to under the square root to be consistent with our documentation and the other irregular excitation functions.

I tested this to make sure everything runs, but I did not get a chance to test a nonlinear case with spread. A quick test would be to run the OSWEC case with nonlinear hydrodynamics and an irregular wave with spread in a few directions. Then, compare the result to the same irregular wave without spread. The result should show increased excitation for the case without spread (difference depends on the spread values).

@jtgrasb jtgrasb requested a review from MShabara August 8, 2025 21:21
Copy link
Contributor

@MShabara MShabara left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @jtgrasb, the code now matches the documentation for the wave spread.

@MShabara MShabara merged commit 2d4703f into WEC-Sim:dev Aug 8, 2025
10 checks passed
@thomash303
Copy link

@jtgrasb, @MShabara

Hello, I was reviewing the documentation for nonlinear hydro and came across this PR. I see that you changed the nonlinear FK function by moving the spreading weights under the square root:

image

However, upon reviewing the waveElevation function, it appears to still have the spreading weights applied outside of the square root:

image

Could you provide guidance on whether that should be the case?

Thank you,

Thomas

@jtgrasb
Copy link
Contributor Author

jtgrasb commented Dec 15, 2025

@thomash303 Thank you for catching this and letting us know. You are correct that we forgot to make the change in the waveElevation() function. Are you interested in applying this change and submitting a pull request with the changes? Then someone from our team could review the changes and merge the pull request. Otherwise, we will make this update soon on our end.

@thomash303
Copy link

@jtgrasb Yeah, I can submit a pull request!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants