-
Notifications
You must be signed in to change notification settings - Fork 171
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
Clean up and align Turbine and TurbineMultiDim class architectures #762
Conversation
It’s not clear why both exist, but they seem to be redundant so I’ve removed fTilt_interp in favor of tilt_interp
Ultimately, it wasn’t used aside from validating the input data. That has been included through the attrs validator.
All other keys use the singular version rather than the plural version, so this keeps it consistent
# Conflicts: # floris/simulation/farm.py # floris/simulation/turbine.py
@bayc The nrel_5MW_fixed example input file has the Cp/Ct tilt correction flag on, but it does not provide a tilt table. What is the expected behavior in this case? |
power_interp[turb_type](rotor_effective_velocities) | ||
* (turbine_type_map == turb_type) | ||
) | ||
p += power_interp[turb_type](rotor_effective_velocities) * (turbine_type_map == turb_type) | ||
|
||
return p * ref_density_cp_ct |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not for this PR, but for future reference, I think we'll need to change this according to @paulf81 's concept of "sliding" along the power curve.
Clean up Turbine and TurbineMultiDim class architectures
This pull request contains a variety of improvements to the Turbine and TurbineMultiDim classes:
fTilt_interp
andtilt_interp
attributes since they were redundantfCp_interp
in favor ofpower_interp
since the former was not usedPowerThrustTable
class and it ultimately wasn’t used aside from validating the input dataTiltTable
class for the same reason as abovecorrect_cp_ct_for_tilt
andfloating_correct_cp_ct_for_tilt
As a small add on, this pull request updates the plots on the Code Quality page with commits up to v3.5.
Impacted areas of the software
The list of changed files is much larger than the impact of this pull request. It doesn't change any functionality, but it does reduce some complexity and ambiguity in the architecture of the Turbine class. Because of these changes, there are some impacts to the
Farm
,Grid
-subclasses, solvers, and examples.Note minor change to turbine yaml keys for floating turbines to bring into better alignment with fixed turbines. This may be a breaking change for some users interesting in floating turbines.
floating_correct_cp_ct_for_tilt
is renamedcorrect_cp_ct_for_tilt
, andwind_speeds
in thefloating_tilt_table
is changed towind_speed
.Additional supporting information
Simplifying and cleaning up the Turbine classes sets up upcoming work to expand the turbine level controls capabilities.