willaguiar / ASC_and_heat_transport

Github repository for Analysis of ASC speed and cross slope heat transport on Panan simulation
0 stars 0 forks source link

Bining of ASC speed into sigma increase maximums #39

Closed willaguiar closed 5 months ago

willaguiar commented 6 months ago

I have been using xhistogram to bin the ASC speed along the 1 km isobath into density levels according to this notebook. However, I noticed that after rebbinning the maximums and minimums (along vertical) of the speed increase.:

Screenshot 2024-05-20 at 2 42 09 PM Screenshot 2024-05-20 at 2 42 00 PM

Since we want the average for the rebining, I calculated the new ASC speed as xhist(weight=speed*Area)/xhist(Area), as suggested by Xhistogram . I tried using volume instead of Area for weighting, and the same intensification happens...... It seems weird to me, as I think we could have different means in the ASC speed between $\sigma$ and $z$ (for non-weighted averages), but the maximums should be the same... Unless I am missing something......

Any ideas @adele-morrison ?

adele-morrison commented 6 months ago

Agreed, that doesn't seem right. I think you want to weight by dz. Which grid is u_along on again?

What about testing the different density binning algorithms in that notebook just for a single daily average? Might help to spot where the bug in the xhistogram method is.

willaguiar commented 6 months ago

U_along is on the U and V grids. I did a second test using area*dzt as weight for the averages, and it gives similar results. Lemme try to weight with only dzt, and other methods to see how it'll look like.

willaguiar commented 6 months ago

I tested xhistogram-binning the monthly data with monthly dzt instead. The issue persists. One problem could be that these binning tests Im doing are using the monthly data, instead of daily.

I couldn't find dzt for IAF_cycle_3.... could we get it by calculating uhrho/(u*rho)?

willaguiar commented 6 months ago

I believe I figured out why the maximums and minimums of ASC speed are larger in $\sigma$ than in $z$.

Explanation: Umin(z) has to always be more negative than Umin(sigma), since Usigma is binned and averaged from Uz. That indeed happens monthly( see that delta Umin (z – sigma) is always negative in the hovmoller below, as it should)

Screenshot 2024-05-24 at 11 16 56 AM

The delta is only positive when we average between months in each year ( hovmoller below for annual means, black line 7E, green line 225W)

Screenshot 2024-05-24 at 11 18 21 AM

That is because at the sigma resolution chosen, we end up not having ASC speed in all sigma layers during the whole year, and therefore the minimum(sigma) don’t get properly averaged by the nanmean. While in Z levels, the minimum gets averaged. Check for example the case 7E below, year 2000, where the minimum occurs in May, at surface and around 1027.4… Screenshot 2024-05-24 at 11 24 24 AMScreenshot 2024-05-24 at 11 42 39 AM For comparisson, look below at the 225W case , where Umin(z) is always more negative than Umin(sigma) both monthly and annually (e.g., two first plots of this issue). In this case the Umin at ~1027.5 seem to be more reasonably averaged with speeds in July and December Screenshot 2024-05-24 at 11 38 15 AMScreenshot 2024-05-24 at 11 39 50 AM Bottomline, the problem is likely because of the high-resolution bin spacing. This should be solved once we have the data separated into 3-6 large sigma bins as discussed in the last meeting.

I think for the next steps we should move on to decide which density bins classification we will use, and afterwards revisit this ASC speed issue to see if the problem went away.