Skip to content

Fix for FAST.Farm issue #3183#3243

Merged
andrew-platt merged 8 commits intoOpenFAST:rc-4.2.1from
andrew-platt:b/FF_AD_bounds
Mar 10, 2026
Merged

Fix for FAST.Farm issue #3183#3243
andrew-platt merged 8 commits intoOpenFAST:rc-4.2.1from
andrew-platt:b/FF_AD_bounds

Conversation

@andrew-platt
Copy link
Collaborator

@andrew-platt andrew-platt commented Mar 9, 2026

Ready to merge.

Feature or improvement description
This PR adds a slice of wind at T=T_low - DT_high to the wind passed into AeroDyn from FAST.Farm. The 4D wind box now spans from T=T_low - DT_high through T=T_low + n_high_low * DT_high.

details
AeroDyn has an extrap/interp for inputs during calculations. However, the wind passed from FAST.Farm is a 4D wind box from T=T_low through T=T_low + n_high_low * DT_high. So if T=T_low, the wind that AeroDyn receives is missing the wind slice at T=T_low - DT_high needed for the interpolation of wind. However this rarely triggered an issue due to a bug in the way the time index into the 4D wind box was calculated (this has not been fixed in this PR).

Related issue, if one exists
#3183, in particular comment #3183 (comment)

Impacted areas of the software
FAST.Farm and AWAE module calculations, but results are minimally impacted.

Additional supporting information
Another approach would have been to keep a copy of the previous wind in AeroDyn for the extrap/interp. However, this was attempted with little success and this method was chosen instead.

Generative AI usage
None. AI couldn't handle this one.

Test results, if applicable

  • r-test branch merging potentially required
    • initial testing shows very small changes in the TSinflow cases, which may be in part due to previous rounding.

- Increased arrays by one timeslice.  Wind timeslice index=0 is now at `T_low-DT_high`
- retrieval of wind now accounts for picking up one extra slice
   - if low res timestep `n==0`, set `T=-DT_high` wind equal to `T=0` wind
   - for lowres steps `n>0`, transfer last wind slice at `T=T_low_previous-DT_high` to `T=T_low_now-DT_high`
   - NOTE: it might also be possible to copy the `T=T_low_previous+n_high_low*DT_high` over to `T=T_low` since they are technically the same
@andrew-platt
Copy link
Collaborator Author

andrew-platt commented Mar 9, 2026

NOTE: the changes in the AWAE_UpdateStates should be compared against the AWAE.f90 in the f/AMReX_reader branch for PR #3238 - significant portions of the code rearrangement were pulled in from there. Those changes were pulled in with commit f745420 which passed all regression tests with the rc-4.2.1 branch, so any discrepancies in results are from later commits.

@andrew-platt
Copy link
Collaborator Author

andrew-platt commented Mar 10, 2026

After extensive debugging, the regression results match exactly, so no updates required on those. Testing included comparing the following:

  • FAST.Farm.out comparison
  • FAST.Farm.T#.outb comparison with pyDatView
  • direct difference of vtk slice outputs for low res and high res.

Copy link
Collaborator

@deslaughter deslaughter left a comment

Choose a reason for hiding this comment

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

Great work. The indexing sure looks tricky.

@andrew-platt andrew-platt merged commit 0a2ada4 into OpenFAST:rc-4.2.1 Mar 10, 2026
12 checks passed
@andrew-platt andrew-platt deleted the b/FF_AD_bounds branch March 10, 2026 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants