Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BeamDyn bug fixes and updates #114

Merged
merged 35 commits into from
May 14, 2018
Merged

BeamDyn bug fixes and updates #114

merged 35 commits into from
May 14, 2018

Conversation

rafmudaf
Copy link
Collaborator

This pull request will merge significant updates to BeamDyn developed at Envision Energy. These updates have been tested and validated as shown below.

The following updates are included:

Issue 11

Sectional load calculations are fixed in commit 0829f84 at line 1569.

This issue is exposed by evaluating the results of the BeamDyn regression test case 5MW_Land_BD_DLL_WTurb. In the OpenFAST dev branch, the first node is at the root but the sectional loads do not match the root loads. Furthermore, the BeamDyn sectional loads do not match the ElastoDyn sectional loads. In this case, the blade root has 13.3 degrees of structural twist so the difference in loads between section 1 and root is related to the offset coordinate systems between blade local and blade reference.

The charts below compare the solutions of the NREL 5MW turbine regression test cases with ElastoDyn and BeamDyn. The left and right columns (ElastoDyn and BeamDyn solutions, respectively) are expected to match. The charts in the upper and lower rows (root and first section, respectively) are expected to differ in magnitude. However, a difference in the ElastoDyn and BeamDyn solution is clearly shown.

Note the difference in units: N vs kN.

issue11 001
issue11 002

The updated BeamDyn solutions demonstrate agreement between the sectional and root loads and are validated by ElastoDyn.

issue11 003
issue11 004

The OpenFAST regression test case using BeamDyn, 5MW_Land_BD_DLL_WTurb, does not currently output the sectional loads, so this bug was not exposed there and it does not require an updated baseline solution. However, the BeamDyn specific regression test bd_5MW_dynamic does require an update to the baselines as the sectional loads have been updated. The root and node 1 forces and moments are shown side by side with the corrected BeamDyn solutions below.

issue11 005
issue11 006

Issue 26

Initial translational velocity calculation is fixed at commit 97d1c2a.

The problems is exposed by running 5MW_Land_BD_DLL_WTurb with initial azimuth angle 0 and 120 from the OpenFAST dev branch. With an initial azimuth of 120 degrees, it is expected that the root moments would simply shift blade numbers in this pattern:

  • Blade 1 at azimuth 0 -> Blade 3 at azimuth 120
  • Blade 2 at azimuth 0 -> Blade 1 at azimuth 120
  • Blade 3 at azimuth 0 -> Blade 2 at azimuth 120

The solution from openfast/dev is shown in the charts below where the root moments do not shift as expected and a frequency variation is introduced in the rotor torque.
slide1

The following charts show that this pull request fixes the root moment blade shift and calculates a consistent rotor torque.

slide2

andrew-platt and others added 30 commits May 30, 2017 21:50
Moved some of the calculations that don't change at each node outside the node loop.
… the loop.

Also apparently added some write statements for figuring out what is going on wit p%uu0 versus p%QuadPt
A few COS and SIN functions were done in single precision, and they ended up causing spikes in BD simulations. Test26 now works in single precision like the double-precision version does!
- fixes for running FAST with BD and BD driver in single precision (should increase speed)
- fix for sectional and root load outputs in static case
- input distributed mesh is along the spline instead of the key-point line
- more code cleanup
- updated crvCompose to use vector math for readability
- updated BD driver for compilation in single precision
- roational velocity vector is now double precision; 
- the BD input file specified in the driver was defined relative to the working directory instead of the directory where the driver input file is located.
4 sets of equations should give same results, assuming the "pivot" is not zero. New implementation picks set of equations with largest pivot value, not just one that is slightly larger than 0. (The values are all bounded by 0 and 4 [or less].)
The initial translation velocity calculation didn't remove the location of the root node when taking the cross product with the rotational velocity. This fixes OpenFAST#26
- fixed initialization of PointLoad mesh (driver only)
- added variables and reorganized loops for optimization
- fixed internal-loads outputs (fixes OpenFAST#11)
- Note that OpenFAST#13 has also been fixed (in a previous commit)
- removed unused variables, including subroutine arguments
- removed duplicated code
- moved some computations into parameters for computational efficiency
a variable was implicitly defined (though it was defined correctly)
I took all of OpenFAST changes, and will modifiy a few issues I noticed when resolving differences later.
 call generic LAPACK_gesvd instead of specific one
I got tired of reading all the compiler warnings about these variables not being used in the Registry and about redefining NDEBUG in MAP++
Setting types with allocatable arrays inside them using the equals sign can cause severe problems on some compilers.
The curve-compose operation was implemented backwards, resulting in incorrect values if the initial rotation was not identity (steady-state simulations gave different mean values for the three blades)
Some instances of the static solve may have incorrectly reported an error.
This changes som comments in the code and some text printed to the summary file
Changed the algorithm to use a bisect approach instead of a predefined, linear load step when the full user-specified load fails to converge
@rafmudaf rafmudaf self-assigned this May 11, 2018
@rafmudaf
Copy link
Collaborator Author

@ghaymanNREL in response to your question in an earlier pull request (#109) regarding the openfast-related regression tests, here are the results from peregrine. As expected, the only failing case is the BeamDyn associated case.

[rmudafor@login2 reg_tests]$ python3 manualRegressionTest.py ../build/glue-codes/fast/openfast linux intel 1e-5 -n
executing AWT_YFix_WSt                           PASS
executing AWT_WSt_StartUp_HighSpShutDown         PASS
executing AWT_YFree_WSt                          PASS
executing AWT_YFree_WTurb                        PASS
executing AWT_WSt_StartUpShutDown                PASS
executing AOC_WSt                                PASS
executing AOC_YFree_WTurb                        PASS
executing AOC_YFix_WSt                           PASS
executing UAE_Dnwind_YRamp_WSt                   PASS
executing UAE_Upwind_Rigid_WRamp_PwrCurve        PASS
executing WP_VSP_WTurb_PitchFail                 PASS
executing WP_VSP_ECD                             PASS
executing WP_VSP_WTurb                           PASS
executing WP_Stationary_Linear                   PASS
executing SWRT_YFree_VS_EDG01                    PASS
executing SWRT_YFree_VS_EDC01                    PASS
executing SWRT_YFree_VS_WTurb                    PASS
executing 5MW_Land_DLL_WTurb                     PASS
executing 5MW_OC3Mnpl_DLL_WTurb_WavesIrr         PASS
executing 5MW_OC3Trpd_DLL_WSt_WavesReg           PASS
executing 5MW_OC4Jckt_DLL_WTurb_WavesIrr_MGrowth PASS
executing 5MW_ITIBarge_DLL_WTurb_WavesIrr        PASS
executing 5MW_TLP_DLL_WTurb_WavesIrr_WavesMulti  PASS
executing 5MW_OC3Spar_DLL_WTurb_WavesIrr         PASS
executing 5MW_OC4Semi_WSt_WavesWN                PASS
executing 5MW_Land_BD_DLL_WTurb                  FAIL

rafmudaf added a commit to OpenFAST/r-test that referenced this pull request May 11, 2018
This updates the baseline solutions for all three supported platforms. The BeamDyn-specific regression test solutions have been corrected and updated. The OpenFAST regression test solutions have simply been updated. Please see the associated OpenFAST pull request for more information: OpenFAST/openfast#114
Gets the updated baseline solutions for BeamDyn related cases from the r-test submodule. Please see the corresponding pull request for more information: OpenFAST#114
@rafmudaf
Copy link
Collaborator Author

The regression test baseline solutions have been updated for all supported platform/compiler combinations. After review, this pull request can be merged.

Copy link
Collaborator

@jjonkman jjonkman left a comment

Choose a reason for hiding this comment

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

Looks good to me. Thanks.

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.

4 participants