Releases: WISDEM/RAFT
v1.3.1
Overview
This release Includes bug fixes that we found after v1.3.0:
- We were overwriting the maximum tension of the mooring lines with the minimum tension in the output dictionary. This bug was introduced quite recently by commit a22d868 when we added minimum values to the output dictionary (2f47591)
- The plotting functions for case visualization were double counting the FOWT position, thus resulting in weird visualizations (68a615a)
- Fixes in MHK modeling (469caa0)
- New optional "currentMod" switch in the moorings section of the input YAML file which is used to pass current information to MoorPy (0: no current; 1: uniform current included in MoorPy) (6046b13)
- The computation of hydrodynamic forces with BEM coefficients wasn't properly accounting for wave incidence and body orientation (d7268c3, 81697c7, and 6337880)
List of PR's included in this release
- RAFT v1.3.1 by @lucas-carmo in #64
v1.3.0
Overview
This release contains the following main functionality and bugfixes
- Change in overhang convention. Before, overhang was positive for upwind turbines. The sign convention is now along +x (opposite of before), thus following OpenFAST convention. For now, the code issues a warning when the overhang is positive to make sure that the user meant to analyze a downwind turbine. This warning will probably be removed after a few releases.
- New set of automated tests in the
tests
directory, including both unit and regression tests. Developers should run those tests usingpytest
locally before submitting a PR. The tests are also run after each push and PR using GitHub Actions. Please consider adding new tests when you implement new features to make sure that the automated tests are comprehensive 😀 - Ability to use preexisting WAMIT files (added mass from .1 file and wave excitation from .3 file) for hydrodynamic loads.
- MacCamy-Fuchs and Kim-and-Yue corrections to approximate wave scattering effects in the first- and second-order wave loads computed with the strip-theory approach (#48). The Kim-and-Yue correction is particularly useful to get more accurate QTFs with the strip-theory approach in some cases of interest.
- Overhaul of the rotor class. Most of the changes are internal to the code and shouldn't affect the user, except for items 1 and 2 listed above.
- Bug fix in helper function getRMS(). The RMS value was missing a factor of sqrt(0.5). This bug fix affects the calculation of the linearized drag force/damping, as well as the standard-deviation, maximum, and minimum values that were printed to the console. This wasn't a problem in the past because the calculation of the wave amplitudes also missed that factor of 0.5, so they cancelled out. But I forgot to add this factor in getRMS() when we fixed the calculation of the wave amplitudes about a year ago.
- Other bug fixes listed below
API changes
- Besides the already available option of specifying the hub height (using input key
hHub
), now the user can also specify the coordinates of the RNA reference position (with respect to the FOWT reference frame) via the input keyrRNA
. For multirotor designs, the user has to providerRNA
for each RNA/rotor - Precomputed frequency-dependent added mass and wave force/moments coefficients can be adopted using WAMIT's .1 and .3 file format. Those files are specified using keys
hydroPath
andpotFirstOrder
(seeexamples/OC4semi-WAMIT_Coefs.yaml
) - Removed input key
qtfPath
. Now, the path to precomputed QTFs is specified byhydroPath
- New flag
MCF
within eachmember
of a platform to specify whether MacCamy-Fuchs and Kim-and-Yue corrections should be used. Documented in #48 and exemplified byexamples/OC4semi-RAFT_QTF.yaml
- The user can output the QTFs computed with RAFT (using the slender-body approach with or without the Kim-and-Yue correction) in WAMIT .12d format. Documented in #48 and exemplified by
examples/OC4semi-RAFT_QTF.yaml
- Now the output channels also include the minimum value of the quantities of interest
Bug fixes and other code changes
- Removed a lot of commented pieces of code (old code, temporary code that we forgot to remove, etc). Tried to keep some chunks of commented code that seemed to be work in progress. Commit #ref# (in case we need to retrieve something).
Helper functions (helpers.py
)
- Function
VecVecTrans()
was changed to return the same type as the input vector, so that complex vectors are no longer converted to float. - The Rodrigues formula used to get the rotation matrix in function
RotFrm2Vect()
assumes unit vectors. The input vectors are now divided by their norm to make sure this is the case. - New functions
getRAO()
and functions for wave kinematics used in Rainey's equation (getWaveKin_grad_u1()
and others).
Member class (raft_member.py
)
- In
Member.RectangularFrustrumMOI()
, there was a missing*
in the case of a truncated pyramid that caused an error because the intended multiplication was interpreted as a function call. - In
Member.getHydrostatics()
, the waterplane moment of area of a rectangle about the local y axis (variableIyWP
) was wrong - In
Member.getHydrostatics()
, the expression for the buoyancy moment about end A only works for a circular cylinder. It's now set to zero for a rectangular cylinder, so we still need to include the right expression for a rectangular cylinder.
FOWT class (raft_fowt.py
)
Many code changes to implement the capabilities listed above in Overview. Listing only bug fixes
- In
FOWT.calcHydroExcitation()
there was adeg2rad()
missing when computing the wave incidence. - In
FOWT.calcHydroLinearization()
the call to functiongetKinematics()
was using the global position of the node instead of the position with respect to the platform to compute node kinematics. - In
FOWT.calcHydroLinearization()
the drag force transverse to a circular element wasn't parallel to the relative transverse fluid velocity because each velocity component was treated independently in the drag part of Morison's equation. This fix does not affect rectangular cylinders, as we still treat the flow along each direction independently in that case. - Same thing for
FOWT.calcCurrentLoads()
, i.e. the drag drag force transverse to a circular element wasn't parallel to the relative transverse fluid velocity. For example, for a vertical circular cylinder under a current with an incidence of 15deg,FOWT.calcCurrentLoads()
now returns a horizontal force with a direction of 15deg. - We weren't accounting for shaft tilt when computing the contribution of the RNA to the inertia of the FOWT in
FOWT.calcStatics()
.
Rotor class (raft_rotor.py
)
Many code changes to overhaul the rotor class to make the code clearer and more organized. Listing only bug fixes
- Fixed the total shaft tilt (shaft+platform tilt) in
rotor.runCCBlade
- in
rotor.calcAero()
, we were reading the yaw angle of the platform of a previous case whenyaw_mode=2
oryaw_mode=3
- The vertical coordinate of the center of gravity of the RNA was assumed to be at hub height, but now it's computed based on
rotor.xCG_RNA
along the shaft.
List of PR's included in this release
- Second-order wave loads in RAFT by @lucas-carmo in #37
- Update openmdao interface for WEIS by @dzalkind in #38
- Temp branch by @mattEhall in #42
- Improvement to hydrodynamic capabilities - Mostly MacCamy-Fuchs and second-order loads by @lucas-carmo in #48
- More robust README install instructions by @gbarter in #47
- RAFT v1.3.0 by @lucas-carmo in #62
Bug fix for prep for rectangular members
Merge pull request #58 from WISDEM/omdao_rect Rectangular connections to WEIS
Patch OpenMDAO wrapper
Added helpful debugging routines and automated plotting of RAFT designs to OpenMDAO wrapper
Patch to openmdao wrapper
This patch removes the discrete inputs from the openmdao wrapper and translates them into modeling options.
Auto-upload to PyPI
v1.2.1 adding auto publish script
Establish CI and working OpenMDAO wrapper
This is an incremental release that establishes a CI with regression tests and fixes errors in the OpenMDAO wrapper.
Incremental release
This marks an incremental improvement in code accuracy, speed, and robustness beyond the prior release. This is the currently recommended version for general use.
v1.0.0
This marks the first release of RAFT, with the following summarized capabilities:
- Platform structure: modeled as rigid using cylindrical or rectangular members with taper, end plates, ballast, etc.
- Hydrodynamics: modeled with strip theory and/or pyHAMS potential-flow (automatic meshing without intersection handling).
- Moorings: modeled with MoorPy giving nonlinear offset calculations and linear coefficients about mean offset.
- Turbine structure: modeled with rigid tower and rotor; rotor speed variations supported through control model.
- Aerodynamics: based on fore-aft rotor coefficients from CCBlade blade element momentum analysis.
- Control: blade-pitch and generator-torque control in regions II and III, combining with rotor properties to compute aero-servo contributions to system damping and added mass.