PyWake issueshttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues2021-05-27T07:36:23Zhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/58flow map from time-series simulationResult2021-05-27T07:36:23ZMads M. Pedersenflow map from time-series simulationResulthttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/56possible bug in vortex model2021-04-16T08:38:12ZTobias Ahsbahspossible bug in vortex modelI was using the pywake implementation for a benchmark for an implementation. Some issues:
The deficit seems to not symmetric:
![image](/uploads/8ed04e701e96bbe215b1b8086a665f45/image.png)
Code for generating the plot below:
```
from py_wake.deficit_models import VortexCylinder
if __name__ == '__main__':
import numpy as np
import matplotlib.pyplot as plt
import time
bm_PW = VortexCylinder()
WS, D_src, ct = 10, 75, 0.8
print("Across centerline")
dw = 2*D_src
cw_array = np.arange(-3*D_src, 3*D_src, 1)
deficit_PW = []
for cw in cw_array:
deficit_PW.append(bm_PW.calc_deficit(np.array([[[WS]]]),
np.array([[D_src]]),
np.array([[[[-dw]]]]),
np.array([[[[cw]]]]),
np.array([[[ct]]]))[0, 0, 0, 0])
plt.figure()
plt.plot(cw_array/D_src, deficit_PW, label='pywake')
plt.legend()
plt.xlabel("relative crosswind distance [-]")
plt.ylabel("wind speed deficit [m/s]")
plt.show()
```
I presume this is due to the coordinate system in the Vortex model. r is always positive, whereas cw_x can also be negative.
The issue is resolved when adding
```
cw_ijlk = np.abs(cw_ijlk)
```
to the beginning of VortexCylinder.calc_deficit.
![image](/uploads/6540140f65565966fcf1a3b6dda1458d/image.png)
A second issues seems to be the definition of:
```
# radial distance from turbine centre
r_ijlk = np.hypot(dw_ijlk, cw_ijlk)
```
the wiz package (where this code comes from), uses
```
r = np.sqrt(Xcp ** 2 + Ycp ** 2)
```
x and y are defined as the coordinates in the rotor plane. Whereas dw_x is perpendicular to the rotor plane.
r_ijlk is only used here:
```
ir = (np.abs(r_ijlk / R_il[:, na, :, na] - 1.) < self.limiter) & (np.abs(dw_ijlk / R_il[:, na, :, na]) < self.limiter)
```
I am not sure if this is an issue. As it is now this would be the point one radius upstream and downstream of the center of the rotor.
/Best
TobiasI was using the pywake implementation for a benchmark for an implementation. Some issues:
The deficit seems to not symmetric:
![image](/uploads/8ed04e701e96bbe215b1b8086a665f45/image.png)
Code for generating the plot below:
```
from py_wake.deficit_models import VortexCylinder
if __name__ == '__main__':
import numpy as np
import matplotlib.pyplot as plt
import time
bm_PW = VortexCylinder()
WS, D_src, ct = 10, 75, 0.8
print("Across centerline")
dw = 2*D_src
cw_array = np.arange(-3*D_src, 3*D_src, 1)
deficit_PW = []
for cw in cw_array:
deficit_PW.append(bm_PW.calc_deficit(np.array([[[WS]]]),
np.array([[D_src]]),
np.array([[[[-dw]]]]),
np.array([[[[cw]]]]),
np.array([[[ct]]]))[0, 0, 0, 0])
plt.figure()
plt.plot(cw_array/D_src, deficit_PW, label='pywake')
plt.legend()
plt.xlabel("relative crosswind distance [-]")
plt.ylabel("wind speed deficit [m/s]")
plt.show()
```
I presume this is due to the coordinate system in the Vortex model. r is always positive, whereas cw_x can also be negative.
The issue is resolved when adding
```
cw_ijlk = np.abs(cw_ijlk)
```
to the beginning of VortexCylinder.calc_deficit.
![image](/uploads/6540140f65565966fcf1a3b6dda1458d/image.png)
A second issues seems to be the definition of:
```
# radial distance from turbine centre
r_ijlk = np.hypot(dw_ijlk, cw_ijlk)
```
the wiz package (where this code comes from), uses
```
r = np.sqrt(Xcp ** 2 + Ycp ** 2)
```
x and y are defined as the coordinates in the rotor plane. Whereas dw_x is perpendicular to the rotor plane.
r_ijlk is only used here:
```
ir = (np.abs(r_ijlk / R_il[:, na, :, na] - 1.) < self.limiter) & (np.abs(dw_ijlk / R_il[:, na, :, na]) < self.limiter)
```
I am not sure if this is an issue. As it is now this would be the point one radius upstream and downstream of the center of the rotor.
/Best
Tobiashttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/52Build conda package for PyWake to support integration with PyWAsP2021-02-01T13:02:08ZNeil DavisBuild conda package for PyWake to support integration with PyWAsP- [ ] Add recipe
- [ ] Update CI to build and deploy to Conda channels- [ ] Add recipe
- [ ] Update CI to build and deploy to Conda channelshttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/51Effect of different Rotor-average models with NOJDeficit Model2021-01-19T14:34:01ZRavichandra JupudiEffect of different Rotor-average models with NOJDeficit ModelHi,
We designed a layout with three turbines. All three turbines are placed in a horizontal row (wt_x is different but wt_y is constant for all the three turbines) and wind speed is specified from eastern (wd=90degrees) direction only. We calculated the wake loss with the same NOJDeficit model but with different Rotor-average models. With NOJDeficit model, the deficit is expected to not vary over the rotor. Due to this, all rotor-average models should result in same wake loss or effective wind speeds at the turbines. However, we noticed a difference with the layout in which the distance between adjacent turbines is equal to three rotor diameters. For example, effective wind speed at the most waked turbine (most downstream) using 'RotorCenter' is 6.5m/s while effective wind speed with 'GridRotorAvg with x = y = np.array([-.6, 0,.6])' is 7.1m/s. We did not expect to see this. However, when we use 'GridRotorAvg' with x = y = np.array([-.01, 0,.01]), the effective wind speed is matching with the effective wind speed from 'RotorCenter'. This means that something unexpected is happening when we consider points away from the rotor center for rotor averaging. We saw this behavior with other Rotor-average models as well. We have attached our python note book with this issue. Can you please check and let us know if we did anything wrong at our end or if there is any correction needed in the pywake code?
Regards,
Ravi
[NOJ_with_different_Rotor_Avg_Models.ipynb](/uploads/2b8b4855b42f7b456c94ec7396ddf6ba/NOJ_with_different_Rotor_Avg_Models.ipynb)
[test_pct_3WTGs.txt](/uploads/f2329579f136d2b504fab485e18fbe8d/test_pct_3WTGs.txt)Hi,
We designed a layout with three turbines. All three turbines are placed in a horizontal row (wt_x is different but wt_y is constant for all the three turbines) and wind speed is specified from eastern (wd=90degrees) direction only. We calculated the wake loss with the same NOJDeficit model but with different Rotor-average models. With NOJDeficit model, the deficit is expected to not vary over the rotor. Due to this, all rotor-average models should result in same wake loss or effective wind speeds at the turbines. However, we noticed a difference with the layout in which the distance between adjacent turbines is equal to three rotor diameters. For example, effective wind speed at the most waked turbine (most downstream) using 'RotorCenter' is 6.5m/s while effective wind speed with 'GridRotorAvg with x = y = np.array([-.6, 0,.6])' is 7.1m/s. We did not expect to see this. However, when we use 'GridRotorAvg' with x = y = np.array([-.01, 0,.01]), the effective wind speed is matching with the effective wind speed from 'RotorCenter'. This means that something unexpected is happening when we consider points away from the rotor center for rotor averaging. We saw this behavior with other Rotor-average models as well. We have attached our python note book with this issue. Can you please check and let us know if we did anything wrong at our end or if there is any correction needed in the pywake code?
Regards,
Ravi
[NOJ_with_different_Rotor_Avg_Models.ipynb](/uploads/2b8b4855b42f7b456c94ec7396ddf6ba/NOJ_with_different_Rotor_Avg_Models.ipynb)
[test_pct_3WTGs.txt](/uploads/f2329579f136d2b504fab485e18fbe8d/test_pct_3WTGs.txt)https://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/50Implement deflection model from Zong 2020 & Shapiro 20182021-01-05T10:08:45ZPierre-Elouan RethoreImplement deflection model from Zong 2020 & Shapiro 2018For the sake of completeness and accomodating to the need of an ongoing MSc thesis, I suggest that we prioritize implementing the deflection model from Zong:
From Zong et al. 2020. doi:10.1017/jfm.2020.77:
![image](/uploads/51569c32722d97275008e0565404afd5/image.png)For the sake of completeness and accomodating to the need of an ongoing MSc thesis, I suggest that we prioritize implementing the deflection model from Zong:
From Zong et al. 2020. doi:10.1017/jfm.2020.77:
![image](/uploads/51569c32722d97275008e0565404afd5/image.png)Mads M. PedersenMads M. Pedersenhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/47make notebook demonstrating linear vs constant power in weibull weighted power2020-11-16T09:52:10ZMads M. Pedersenmake notebook demonstrating linear vs constant power in weibull weighted powerhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/46Make notebook demonstrating local speed up vs local weibull2020-11-16T09:51:40ZMads M. PedersenMake notebook demonstrating local speed up vs local weibullhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/43Idea: WindTurbines generated from htc via HS2/H2Aero/H22020-08-26T12:26:18ZMads M. PedersenIdea: WindTurbines generated from htc via HS2/H2Aero/H2The idea is to generate power and ct curves via BEM
Questions and problems:
- Controller cannot be used to select rpm and pitch in HS2 (and H2Aero?)
- HS2 not working with yaw deflectionThe idea is to generate power and ct curves via BEM
Questions and problems:
- Controller cannot be used to select rpm and pitch in HS2 (and H2Aero?)
- HS2 not working with yaw deflectionhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/40No support for WeightedSum in memory-saving flow_map2020-06-29T06:19:38ZMads M. PedersenNo support for WeightedSum in memory-saving flow_maphttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/34Implement the wind direction uncertainty propagation for benchmarking2020-03-20T08:26:13ZPierre-Elouan RethoreImplement the wind direction uncertainty propagation for benchmarkinghttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/32Implement the wake meandering as a common feature to all the wake models in p...2020-03-20T08:24:03ZPierre-Elouan RethoreImplement the wake meandering as a common feature to all the wake models in pywakehttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/31Implement a load plugin in pywake2020-03-20T08:22:56ZPierre-Elouan RethoreImplement a load plugin in pywakehttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/22Air density in pywake2019-10-22T08:16:06ZPierre-Elouan RethoreAir density in pywakeAdd air density as an output of pywake or get it from pywasp through the site classAdd air density as an output of pywake or get it from pywasp through the site classhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/19Implement single wake model from Braunbehrens and Segalini2019-09-06T09:25:16ZPierre-Elouan RethoreImplement single wake model from Braunbehrens and Segalini## Reference Paper
Robert Braunbehrens, Antonio Segalini, A statistical model for wake meandering behind wind turbines, Journal of Wind Engineering and Industrial Aerodynamics, Volume 193, 2019 [doi:10.1016/j.jweia.2019.103954](https://www-sciencedirect-com.proxy.findit.dtu.dk/science/article/pii/S0167610519305458)
## Paper Abstract
A new wake model is proposed to account for wake meandering in simulations of wind-turbine wakes performed on steady solvers, through a wake-meandering description based on the dispersion theory of Taylor (1921, P. Lond. Math Soc., vol. 20, pp. 196–211). Single-turbine simulations were performed by means of the linearised solver ORFEUS. By analysing the steady wake behind a turbine, a set of parameters describing the wake was first obtained and synthesised into a look-up table. The proposed meandering model extended the simulation results by superimposing the lateral and vertical meandering motions to the steady wake. As a result, the time-averaged velocity distribution of the wake was increased in width and reduced in intensity. Through this combination, the model provides rationale for the wake-deficit decrease and for the power underestimation effects of several wake models. The new wake model is validated against the Lillgrund and Horns Rev data sets.
## TODO
* [ ] Code the single wake model from equation (11)
* [ ] Make LUT from figure 3.
* [ ] Add the same benchmark of the paper in the automatic benchmark report
Additional work for a MSc thesis:
* [ ] From LES simulations results of Søren Juhl do a surrogate model for the model
* [ ] Make a reproduction jupyter notebook of the paper## Reference Paper
Robert Braunbehrens, Antonio Segalini, A statistical model for wake meandering behind wind turbines, Journal of Wind Engineering and Industrial Aerodynamics, Volume 193, 2019 [doi:10.1016/j.jweia.2019.103954](https://www-sciencedirect-com.proxy.findit.dtu.dk/science/article/pii/S0167610519305458)
## Paper Abstract
A new wake model is proposed to account for wake meandering in simulations of wind-turbine wakes performed on steady solvers, through a wake-meandering description based on the dispersion theory of Taylor (1921, P. Lond. Math Soc., vol. 20, pp. 196–211). Single-turbine simulations were performed by means of the linearised solver ORFEUS. By analysing the steady wake behind a turbine, a set of parameters describing the wake was first obtained and synthesised into a look-up table. The proposed meandering model extended the simulation results by superimposing the lateral and vertical meandering motions to the steady wake. As a result, the time-averaged velocity distribution of the wake was increased in width and reduced in intensity. Through this combination, the model provides rationale for the wake-deficit decrease and for the power underestimation effects of several wake models. The new wake model is validated against the Lillgrund and Horns Rev data sets.
## TODO
* [ ] Code the single wake model from equation (11)
* [ ] Make LUT from figure 3.
* [ ] Add the same benchmark of the paper in the automatic benchmark report
Additional work for a MSc thesis:
* [ ] From LES simulations results of Søren Juhl do a surrogate model for the model
* [ ] Make a reproduction jupyter notebook of the paperhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/14Implement automatic gradient estimation in pyWake2021-01-12T07:00:26ZPierre-Elouan RethoreImplement automatic gradient estimation in pyWake## Task draft
- [x] Look at [autograd](https://github.com/hips/autograd), [JAX](https://github.com/google/jax), and [uncertainties](https://github.com/lebigot/uncertainties) (and others) python packages and decide which one to adopt
- [ ] Autograd a `WakeModel.calc_deficit` method (e.g. Gaussian wake)
- [x] Autograd the `site.local_wind` method
- [x] Autograd the `site.wt2wt_distances` method
- [x] Autograd the `windTurbines._ct_power` method
- [ ] Autograd the `windTurbines._ct_power` method with pchip
- [x] #15 Update `calc_wake` API with respect to H_i and D_i
- [x] Autograd the `WakeModel.calc_wake` method
- [x] Autograd the `AEPCalculator.calculate_AEP` method## Task draft
- [x] Look at [autograd](https://github.com/hips/autograd), [JAX](https://github.com/google/jax), and [uncertainties](https://github.com/lebigot/uncertainties) (and others) python packages and decide which one to adopt
- [ ] Autograd a `WakeModel.calc_deficit` method (e.g. Gaussian wake)
- [x] Autograd the `site.local_wind` method
- [x] Autograd the `site.wt2wt_distances` method
- [x] Autograd the `windTurbines._ct_power` method
- [ ] Autograd the `windTurbines._ct_power` method with pchip
- [x] #15 Update `calc_wake` API with respect to H_i and D_i
- [x] Autograd the `WakeModel.calc_wake` method
- [x] Autograd the `AEPCalculator.calculate_AEP` methodMads M. PedersenMads M. Pedersenhttps://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/issues/5Implement fusedwake wrapper2020-02-23T16:09:55ZMads M. PedersenImplement fusedwake wrapper