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

Refactoring of Drag Forcing

Open hgopalan opened this issue 2 months ago • 5 comments

When Immersed Boundary Forcing method was developed, there was a need for having sponge layers to ensure that solution was not contaminated. However, with algorithm improvement, this feature became redundant and is being removed. On the other hand for strong inversions, gravity waves were being reflected back from the horizontal boundaries. A new lateral damping has been added within drag forcing to ensure that the gravity waves do not contaminate the solution.

Please check the type of change introduced:

  • [ ] Bugfix
  • [X ] Feature
  • [ ] Code style update (formatting, renaming)
  • [X ] Refactoring (no functional changes, no api changes)
  • [ ] Build related changes
  • [ X] Documentation content changes
  • [ ] Other (please describe):

Checklist

The following is included:

  • [ ] new unit-test(s)
  • [ ] new regression test(s)
  • [X ] documentation for new capability

This PR was tested by running:

  • the unit tests
    • [X ] on GPU Kestrel
    • [X] on CPU Kestrel
  • the regression tests
    • [X ] on GPU Kestrel
    • [ X] on CPU Kestrel

hgopalan avatar Dec 04 '25 14:12 hgopalan

Need to update documentation and add examples.

hgopalan avatar Dec 04 '25 17:12 hgopalan

This is an useful feature that is needed for certain scenarios-- thanks for implementing it. I have one minor comment/request in terms of the inputs. It does not seem like it is arbitrary enough. The user can only set the damping length for each boundary and a single lateral damping start. I would be helpful to have settings like the Rayleigh damping, where we can specify the sloped and complete damping part. For example, if we want to setup a damping on the west boundary that starts at z=1000, has a (cosine?) slope until z=1200, then it's fully active until z=zhi, I don't see a way to set that up right now. I see that being useful depending on the boundary layer we have coming into the domain.

rthedin avatar Dec 05 '25 16:12 rthedin

This is an useful feature that is needed for certain scenarios-- thanks for implementing it. I have one minor comment/request in terms of the inputs. It does not seem like it is arbitrary enough. The user can only set the damping length for each boundary and a single lateral damping start. I would be helpful to have settings like the Rayleigh damping, where we can specify the sloped and complete damping part. For example, if we want to setup a damping on the west boundary that starts at z=1000, has a (cosine?) slope until z=1200, then it's fully active until z=zhi, I don't see a way to set that up right now. I see that being useful depending on the boundary layer we have coming into the domain.

Added the slope damping to horizontal and lateral direction. Have not added complete damping yet since PALM-LES showed success with just sloped damping. We may need complete damping for full MMC. Will keep running more tests.

hgopalan avatar Dec 08 '25 16:12 hgopalan

Moved damping to Rayleigh Damping instead of inside DragForcing

hgopalan avatar Dec 09 '25 14:12 hgopalan

@mbkuhn Everything is ready for integration. @moprak-nrel Can I have your review since Michael also pushed changes?

hgopalan avatar Dec 12 '25 07:12 hgopalan