Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IMPORTANT: Code error in calculating advective flux in bug fix release 0.7.2 #92

Closed
csyhuang opened this issue Nov 5, 2023 · 0 comments
Assignees

Comments

@csyhuang
Copy link
Owner

csyhuang commented Nov 5, 2023

The equation in #83 was correct but the fortran code implementation was unfortunately wrong. This shall be fixed in release 1.0.0. Thanks Christopher Polster for spotting that.

As mentioned in #83 , the correct expression for $u_e$ in the integral should be:

$$u_e(\lambda, \phi, \phi^\prime, z, t) \equiv \omega_e a \cos\phi = \frac{u(\lambda, \phi + \phi^\prime, z, t)\cos\phi}{\cos(\phi+\phi^\prime)} - u_{\text{REF}}(\phi, z, t)$$

where $\omega = \frac{u}{a\cos\phi}$ is the angular velocity (and $\phi^\prime \in [0, \Delta\phi]$).

The integral, which should have been computed as

eqn1_jpg

in release v0.7.2 was computed by mistake as

eqn2_jpg

Release v1.0.0 has this mistake corrected.

@csyhuang csyhuang self-assigned this Nov 5, 2023
@csyhuang csyhuang pinned this issue Nov 5, 2023
@csyhuang csyhuang mentioned this issue Nov 5, 2023
5 tasks
@csyhuang csyhuang closed this as completed Dec 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant