FV3 Bundle
|
Go to the source code of this file.
Functions/Subroutines | |
subroutine | solve_elliptic_system (x, pv, nx, ny, deltax, deltay, F1, F2) |
Solves the elliptic system that arises when inverting potential vorticity. More... | |
subroutine solve_elliptic_system | ( | real(kind=kind_real), dimension(nx,ny,2), intent(out) | x, |
real(kind=kind_real), dimension(nx,ny,2), intent(in) | pv, | ||
integer, intent(in) | nx, | ||
integer, intent(in) | ny, | ||
real(kind=kind_real), intent(in) | deltax, | ||
real(kind=kind_real), intent(in) | deltay, | ||
real(kind=kind_real), intent(in) | F1, | ||
real(kind=kind_real), intent(in) | F2 | ||
) |
Solves the elliptic system that arises when inverting potential vorticity.
Here, we are solving the coupled system:
\begin{eqnarray} \nabla^2 \psi_1 - F_1 (\psi_1 -\psi_2 ) &=& p_1 \\\\ \nabla^2 \psi_2 - F_2 (\psi_2 -\psi_1 ) &=& p_2 \nonumber \end{eqnarray}
where the subscript refers to model level, and \( \nabla^2 \) is the 5-point finite-difference two-dimensional Laplacian.
We reduce this to a 2D problem, which we solve for \( \nabla^2 \psi_1 \):
\[ \nabla^2 \left(\nabla^2 \psi_1 \right) - (F_1 + F_2 ) \nabla^2 \psi_1 = \nabla^2 p_1 - F_2 p_1 - F_1 p_2 \]
Having found \( \nabla^2 \psi_1 \), we invert the Laplacian to determine \( \psi_1 \), and then get \( \psi_2 \) by substitution in equation 1 above.
[in] | nx | Zonal grid dimension |
[in] | ny | Meridional grid dimension |
[out] | x | Streamfunction |
[in] | pv | Right hand side |
[in] | deltax | Zonal grid spacing (non-dimensional) |
[in] | deltay | Meridional grid spacing (non-dimensional) |
[in] | f1 | Coefficient in the PV operator |
[in] | f2 | Coefficient in the PV operator |
Definition at line 31 of file solve_elliptic_system.f90.