Having just acquired a bunch of wind data from NOAA I thought I'd give this a go
First of you need some data on wind turbine power output, the folks over at
WindPower program has some nice
stuff in their library.
Here is some data I found {wind speed(m/s), power output (W)} that can be used to create a function mapping wind-speed to power output:
wdata={{0.5, -12}, {1, -12}, {1.5, -11}, {2, 0}, {2.5, 39}, {3, 102}, {3.5, 229}, {4, 399}, {4.5, 596}, {5, 848}, {5.5, 1151}, {6, 1510}, {6.5, 1938}, {7, 2403}, {7.5, 2949}, {8, 3602}, {8.5, 4306}, {9, 5071}, {9.5, 5960}, {10, 6856}, {10.5, 7849}, {11, 8863}, {11.5, 9928}, {12, 10885}, {12.5, 11619}, {13, 12019}, {13.5, 12276}, {14, 12395}, {14.5, 12449}, {15, 12495}, {15.5, 12508}, {16, 12546}, {16.5, 12555}, {17, 12503}, {17.5, 12528}, {18, 12442}, {18.5, 12396}, {19, 12208}, {19.5, 11878}, {20, 11989}, {20.5, 11495}}
Module[{
wf = Interpolation[wdata],
min = Min[wdata[[All,1]]],
max = Max[wdata[[All,1]]]
},
Attributes[windToPower] = {Listable};
windToPower[speed_] /; min <= speed <= max := wf[speed];
windToPower[speed_] := 0
]
(* Integrate the list {{t1, v1}, {t2, v2}, ... }, will be used later *)
listIntegrate[data_List] :=
Total[ Differences[data[[All, 1]]] MovingAverage[data[[All, 2]], 2] ]
listMean[data_List] := listIntegrate[data]/(#2 - #1)& @@ data[[{1, -1}, 1]]
Plot[windToPower[t], {t,0,25}, Epilog->Point@wdata,AxesLabel->{"m/s","W"}]
Next thing needed is a bunch of wind data for the area, easiest would be to take it from WeatherData, here I just use what is available so far this year:
shortWindData[station_] := shortWindData[station] =
Module[{
wind = Quiet@Map[{N@AbsoluteTime[#[[1]]],#[[2]] 5./18}&,
DeleteCases[
WeatherData[station, "WindSpeed", {{2013}, {2013}, All}],
{_, _Missing}]],
power
},
If[Head[wind]==Missing || Length[wind]<10, Return[$Failed, Module]];
power = wind;
power[[All,2]] = windToPower[wind[[All,2]]];
{"Coordinates"->WeatherData[station, "Coordinates"],
"Interval"->wind[[{1,-1},1]],
"WindAverage"->listMean[wind],
"PowerAverage"->listMean[power]
}]
allWindData := DeleteCases[DownValues[shortWindData][[All, 2]], $Failed]
(* Get weather data for about 5 minutes, wont be much *)
wstations = WeatherData[];
TimeConstrained[
Scan[shortWindData, RandomSample[wstations]],
60*5
]
If you want lots of data it's faster to download it
directly from NOAA, which is what I have done below:
Now we can see how the wind average and power average are related:
ListPlot[
{"WindAverage", "PowerAverage"} /. allWindData,
PlotRange -> All,
AxesLabel -> OverBar/@{"m/s", "W"}]
This looks quadratic so let's try a pretty basic fit:
model = NonlinearModelFit[
{"WindAverage", "PowerAverage"} /. allWindData,
a + b t^2,
{a, b}, t];
errorsModel = (model[#1] - #2)/model[#1] & @@@ ({"WindAverage", "PowerAverage"} /. allWindData);
Column[{model["BestFit"],
Plot[
model[t], {t, 0, 13},
Prolog -> Point[{"WindAverage", "PowerAverage"} /. allWindData],
PlotRange -> All],
SmoothHistogram[Select[errorsModel, -2 < # < 2 &]]
}]
Looking at the plots above and:
Quantile[errorsModel, {.125, .875}]
(* {-0.245282, 0.497163} *)
We see it's not all too exact, but at least it's better than looking at the wind-average directly:
errorsDirect = (#1 - #2)/#1 & @@@DeleteCases[{windToPower["WindAverage" /. allWindData], "PowerAverage" /. allWindData}\[Transpose], {0, _}];
Quantile[errorsDirect, {.125, .875}]
(* {-6.67827, 6.59461} *)
SmoothHistogram[Select[errorsDirect, -8 < # < 8 &]]
Hopefully this will give you some ideas how to go about the problem, I bet you can think of a whole bunch of ways to refine this model by taking more data and parameters into account.