pywasp.potential_aep#
- pywasp.potential_aep(wwc, wtg, /, wind_turbines=None, *, air_density_correction='infer', air_density=None, wind_farm_model='PARK2_onshore', ws_stepsize=1.0, ws_upper_limit=None, ws_lower_limit=0.0, n_subsector=5, site_interp_method='nearest', site_interp_bounds='ignore', turbulence_intensity=None, n_cpu_pywake=1)#
Calculate Potential Annual Energy Production using wind farm effects from PyWake.
Warning
This function is experimental and its signature may change.
- Parameters:
wwc (
Dataset) – PyWAsP Weibull Wind Climate Dataset containing wind climates for all the turbine locations.-
If a xr.Dataset is passed it should be a WTG formatted dataset. PyWAsP will assume WWC points match the turbines hub height and that the WTG is the same for all turbines
If a dict of wtg_keys and WTG xr.Datasets is passed, a
turbinesdataset must be passed as well, and the key’s must match between the two.
wind_turbines (
Dataset, optional) – Wind Turbine locations, hub heights, group_id’s, and wtg_keys. Paired with the wind climate by position: turbine i is given point i’s wind climate and air density, and the results come back in the wind climate’s order. A turbine need not stand exactly at its point – a wind climate measured nearby is fine – but there must be one turbine per point, in the same order. Built from the wind climate’s own locations when not passed.air_density_correction (
string, optional) – “infer” –> correct the power curve to the site’s air density. “none” –> use the power curve as it is; the air density is not read.air_density (
float, optional) – Air density to correct the power curve to, used only with air_density_correction=”infer”. Overwrites the air density in the WWC, if present; otherwise the WWC’s own is used.wind_farm_model (
str,function) – Wind farm model to use for deficit calculations. Can either be a name of a predefined wind farm model: “PARK1”, “PARK2_onshore”, “PARK2_offshore”, or a predefined py_wake wind_farm_model object (wrapped in a ‘functools.partial’ function)ws_stepsize (
float, optional) – Wind speed step between the simulated wind speed cases, by default 1.0 m/s. Effective wind speeds are taken as linear between the cases, so a jump in the wake response, where an upstream turbine cuts in or out, is only resolved to this step. That matters most for small deficits, which it can shift by a noticeable fraction of their value.wspddoes not depend on it.ws_upper_limit (
float, optional) – Upper limit of wind speed range, by default None Which means the upper limit of the wind speed range will be the maximumws_lower_limit (
float, optional) – Deprecated since 2.1.0; will be removed in 3.0. Warns for any value other than 0.0. A float is ignored; the wind speed cases start at 0.0 m/s.Nonestarts them at the cut-in wind speed instead, and has no replacement.n_subsector (
int, optional) – Number of equispaced wind directions simulated within each sector, by default 5. Subsectors sample the wake geometry within their sector only: a subsector always uses its parent sector’s wind climate, speed-up and turbulence intensity.site_interp_method (
str, optional) – The interpolation method to use in py_wake XRSite, by default “nearest”. Interpolation applies to the spatial axes; a subsector always uses its parent sector’s speed-up and turbulence intensity.site_interp_bounds (
str, optional) – How to handle values outside the site boundary, by default “ignore” Which means values outside the site bondary will not be checked for.turbulence_intensity (
float, optional) – Turbulence intensity for the calculation; wind climates produced by pywasp do not include it, so it is only available if passed here or added to the WWC as a “turbulence_intensity” variable, which a value passed here overwrites. The built-in wind farm models do not use it – it only feeds the effective turbulence intensity outputs, which are omitted when it is absent – but a custom wind farm model requires it.n_cpu_pywake (
int, optional) – Number of CPUs to use for the PyWake calculations, by default 1 If n_cpu_pywake is None, the number of CPUs will be set to the number of CPUs available on the machine.
- Returns:
Dataset– Potential Annual Energy Production for each turbine/location. Each variable below has a_sectorcounterpart holding the same quantity per sector, alongsidewdfreq.- potential_aep:
Potential AEP in GWh for each location
- gross_aep:
Gross AEP in GWh for each location. Integrated exactly over the Weibull distribution, as
gross_aep()does, but only up to the highest wind speed simulated, so aws_upper_limitstopping short of where the turbine still produces lowers it. Its ratio withpotential_aepis therefore a pure wake effect.
- potential_aep_deficit:
AEP deficit in units of fraction for each location,
1 - potential_aep / gross_aep
- wspd:
Mean wind speed in m/s for each location: the mean of its sector Weibull distributions, weighted by
wdfreq
- wspd_eff:
Mean effective wind speed in m/s for each location. Above the highest wind speed simulated, the effective wind speed keeps its ratio to the free wind speed there.
- wspd_deficit:
Average wind speed deficit in units of fraction for each location,
1 - wspd_eff / wspd
- turbulence_intensity_eff:
Mean effective turbulence intensity for each location, held at its value at the highest wind speed simulated above it (only present when turbulence intensity is available)
- Raises:
PywaspError – If a variable the calculation needs is not in the WWC; if no location has a known air density; if
wind_turbinesdoes not hold one turbine per WWC point; or ifws_upper_limitleaves fewer than two wind speeds to simulate.TypeError – If wtg is neither an xr.Dataset nor a dict of them, or if a dict of several is passed without wind_turbines.
ValueError – If a custom wind farm model is used and turbulence_intensity is neither in the WWC nor passed explicitly.
- Warns:
UserWarning – If the simulated wind speeds do not reach the wind speeds where the turbines still produce, which truncates the AEP integrals. Raise
ws_upper_limitor leave it unset.UserWarning – If some locations have no air density, which leaves their AEP missing.