Windrose conditional statement ignored

#1

Hi @AbrahamYezioro ,

I see you answred a topic about windroses and conditional statements, although it seems there are still some problems about how the windrose component takes into account conditional statements.

Contexte : my goal is to make a windrose for only certain hours of the years. For example, the hours where a building is occupied in july and august. For this, the analysis period component cannot do the trick alone. So my strategy was to make a conditional statement based on an hourly data from the EPW file (for example barometric pressure) that I modify by multipling some of the values by zero. Then I apply “a>1” conditional statement on this annual hourly data in order to remove all data that I’m not intersted in.

This strategy works fine for the radiation analysis, but for the wind rose, it doesn’t take into account the conditional statement properly. I carried out a test : a wind rose for the month of july and august. One made with a simple analysis period component. The other one is made with my strategy as explained above. They give completly different results.

Do you have any idea what could be the problem ? What is weird is that the component doesn’t complain about the modified hourly data, as it is exactly the same format as an hourly data strait from the EPW component…

There is the Gh file and a picture of the canva attached

Cheers,

Vincent

problem windrose.gh (551.0 KB)

#2

Hi @Vincent,
Sorry for the delay.
Your analysis period doesn’t fit the months july/august.
The first day of july is 4345 and yours is 4380. There is a difference of 35 hours. Those may e causing the issue you are mentioning. You can see the 3dGraph that the red field doesn’t fit the start and end of the period.


See below how it should fit:

Hope it helps,
-A.

#3

Hi @AbrahamYezioro

Thanks for your reply. However the 35 hours difference in the analyss period cannot explain the error between the two analysis (I made another test run with the start at 4345 just to make sure, but it gives the same results).

To give you an idea of the difference between analysis, the one with the analysis period component shows a frequency of 18.41% for winds comming from the west, versus 10.9% for the one with the conditional statement. The one with the conditional statement is very close but somehow slightly different from the whole year wind rose (11.76% of winds comming from the west). This suggests that the conditional statement is not completely ignored but simply properly taken into account. See the pictures of the wind rose below :

One more thing : if I make sure the conditional statement is always true (meaning it runs for all the hours of the year), it still gives the same result as before (10.9% of wind comming from the west), and this result is different than a simple whole year analysis. So I think there’s definitly a bug here when it comes to taking into account the conditional statements.

#4

It also bugs for simple conditional statements (for exemple temperature based conditions, with no manipulation of the annual hourly data). In the example below, the windrose can’t handle the condition of drybulb temperature > 20 °C. (Which happens 963 hours in a year in Paris)

#5

@Vincent,
I can’t look right now at the files, I’m on the road. I will in a couple of days.
Though some things you need to be aware of:
For the conditional in the wind rose component “a” is related to wind data explicitly. So if you want to give a conditional on another data type you need to go from “b” and on. There is no problem with your checking above. Just set the conditional to b>20.

For specific period (months and/or hours) i wrote a small script to create 8760 list of 0s and 1s (similar to what you did), but in my case it works for me and i don’t see those differences you mention. Pay also attention that there is a possibility that the summer winds are those that set also the year results, so you don’t see much difference.
As i said, i’ll check this again in a few days and will get back to you. In any case, i don’t believe there is a bug here but probably some misunderstanding (yours … or mine … :-))
Best,
-A.

#6

@AbrahamYezioro

Thanks for your quick reply, I see the misunderstanding now. I always thought that “a”, “b”, “c” etc. reffered to the first, second, third etc. hourly data that is connected to annualHourlyData_ like in the other analysis components. And that if one wanted to put a condition on wind speeds, he had to connect the wind speed to the annualHourlyData_ … So basically I was putting conditions on wind speeds all this time without even realizing it.

#7

It means everything is fine now? Or we are still discussing the original issue?
-A.

#8

Yeah it’s fine now thanks !

Do you know if we can use the recolor mesh component after a windrose ? Connecting the meshes and the corresponding analysis results seems tricky. The goal beeing to modify the frequencies so they are calculated based on the number of hours that passes the conditional statement and not the number of hours in the analysis period.

I’ve looked on hydra share if their was any wind rose with a recolor mesh example but couldn’t find anything.

#9

Glad to hear.
Why don’t you use one of the predefined color schemes?
I don’t remember if i did in the past a recolor mesh for the wind but i believe it is possible … but again, right now i can’t check.
-A.

#10

Didn’t find how to do a recolor mesh for the wind analysis. The results outputs don’t contain the information for the mesh in the wind rose.
-A.

#11

Yeah that’s what I thought,

Thanks anyways !