Combination of Jimenez wake deflection and VortexCylinder blockage produces an error.
The example below combines:
- blockage_deficitModel=VortexCylinder(upstream_only=True),
- deflectionModel=JimenezWakeDeflection()
and produces an error that seems to be related to a dimension mismatch.
In [this commit](https://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/commit/75b32657c89b65c37303bceeb094487a77b8260f) on the combine_cj_eddy_viscosity_lwfc branch, I am making a quick fix but I am not sure it meets your standards.
Then in [another commit](https://gitlab.windenergy.dtu.dk/TOPFARM/PyWake/-/commit/f7b9a550ea5a08bcd54107fbe30c2223589a0989) on the same branch I am making an early return to have a quicker evaluation for the case of yaw and tilt = 0, but in principle it is not needed.
```
from py_wake.examples.data.iea37 import IEA37Site, IEA37_WindTurbines
from py_wake.deficit_models import (
VortexCylinder,
TurboGaussianDeficit,
SelfSimilarityDeficit2020
)
from py_wake.deflection_models import JimenezWakeDeflection
from py_wake.superposition_models import SquaredSum
from py_wake.wind_farm_models import All2AllIterative
import numpy as np
site = IEA37Site(16)
x, y = site.initial_position.T
wt = IEA37_WindTurbines()
# First part goes fine...
wfm = All2AllIterative(
site, wt,
wake_deficitModel=TurboGaussianDeficit(),
blockage_deficitModel=SelfSimilarityDeficit2020(),
deflectionModel=JimenezWakeDeflection()
)
sim = wfm(x, y, wd=np.arange(0, 360, 30), ws=np.arange(1., 41.), yaw=0, tilt=0)
print(sim.aep().sum())
# but if we use VortexCylinder, it fails
wfm = All2AllIterative(
site, wt,
wake_deficitModel=TurboGaussianDeficit(),
blockage_deficitModel=VortexCylinder(upstream_only=True),
deflectionModel=JimenezWakeDeflection()
)
# yaw=0 still goes through Jimenez; so Jimenez needs to produce matrices in the proper format.
wfm(x, y, wd=np.arange(0, 360, 30), ws=np.arange(1., 41.), yaw=0, tilt=0)
# The above produces:
# IndexError: boolean index did not match indexed array along axis 3; size of axis is 40 but size of corresponding boolean axis is 1.
```
issue