amr-wind icon indicating copy to clipboard operation
amr-wind copied to clipboard

Geostrophic Forcing flaws

Open mbkuhn opened this issue 10 months ago • 4 comments

I see two problems in the Geostrophic Forcing routine

  1. The intended vertical forcing component (in z) has a 1 as the component index, instead of a 2. This is a simple bug to correct. https://github.com/Exawind/amr-wind/blob/main/amr-wind/equation_systems/icns/source_terms/GeostrophicForcing.cpp#L123
  2. Although the possibility of a vertical component is implied by the "is_horizontal" option, it seems like the implementation does not allow for a nonzero vertical component. This seems like a flaw in the coupling with the parameters from Coriolis Forcing. https://github.com/Exawind/amr-wind/blob/main/amr-wind/equation_systems/icns/source_terms/GeostrophicForcing.cpp#L53

mbkuhn avatar Apr 23 '24 15:04 mbkuhn

@gdeskos @mchurchf I'd love your input on what things are supposed to look like regarding point 2. above.

mbkuhn avatar Apr 23 '24 15:04 mbkuhn

This issue is stale because it has been open 30 days with no activity.

github-actions[bot] avatar May 24 '24 02:05 github-actions[bot]

@mbkuhn In this line https://github.com/Exawind/amr-wind/blob/7c660c1685cfa85d875acd98b769d14cbf9c0019/amr-wind/equation_systems/icns/source_terms/GeostrophicForcing.cpp#L162 there is a bug. The index should be 2 instead of 1?

gdeskos avatar May 25 '24 01:05 gdeskos

@gdeskos that's true, and that is one of the things I noted originally. However, I'm also saying that forcing[2] is always 0.0. So even if this bug is fixed, there's no possibility of there being a src_term component in z. That seems like a feature is missing, given that the hfac factor is there. Is there a formula for what that component should be, if it's turned on?

mbkuhn avatar May 28 '24 13:05 mbkuhn

Discussed: for now, @mbkuhn is going to fix the one line bug and then close this issue

marchdf avatar Jun 26 '24 17:06 marchdf