Skip to content

Commit

Permalink
Refactoring density integrals for efficiency
Browse files Browse the repository at this point in the history
  Refactored 4 routines (int_density_generic_pcm, int_density_generic_ppm,
int_spec_vol_generic_pcm and int_spec_vol_generic_plm) in density integrals for
greater computational efficiency by doing fewer calls to the equation of state
routines but calculating entire rows of densities at subgrid locations with each
each call, replicating what was already being done int_density_dz_generic_plm.
To accomplish this, a number of variables now use larger arrays than
previously.  The total computational cost of the non-Boussinesq pressure
gradient force calculation was more than 50% greater with the previous code in
some tests.  All answers are bitwise identical.
  • Loading branch information
Hallberg-NOAA committed Mar 31, 2024
1 parent 2b59089 commit 7cff497
Showing 1 changed file with 709 additions and 525 deletions.
Loading

0 comments on commit 7cff497

Please sign in to comment.