jiskattema / dales

Dutch Atmospheric Large-Eddy Simulation model
GNU General Public License v3.0
1 stars 0 forks source link

bulkmicrostat3 output #8

Closed jiskattema closed 4 years ago

jiskattema commented 4 years ago

Current output is not time averaged, but it is an average over a number of samples. Is it not better to do real time averaging?

jchylik commented 4 years ago

Do you mean first average in time, and then average between the cores?

jiskattema commented 4 years ago

The current output is a snapshot at regular intervals (ie. sum every X seconds), which then get averaged before writing (ie. divide by the number of snapshots). The rk3 timestepping is adjusted to land exactly at the necessary times, and only steps with rk3step = 3 (i think..) are used.

For 'real' time averaging, we would need to sum (at rk3step=3?) the product of the tendency and the timestep, and later divide by the elapsed time. I thought this might be easier, but it will be similarly complex as the current implementation. We would then also have differently averaged output, depending on the scheme, or we would need to rewrite all outher output routines, too.

The sampling is actually more versatile and faster, so let's keep it like this.