NOAA-GFDL / GFDL_atmos_cubed_sphere

The GFDL atmos_cubed_sphere dynamical core code
Other
56 stars 118 forks source link

fv3atm needs the global_tile from atmosphere_control_data so CCPP can read per-tile static files #329

Closed SamuelTrahanNOAA closed 5 months ago

SamuelTrahanNOAA commented 6 months ago

Is your feature request related to a problem? Please describe. Additional information is here:

https://github.com/NOAA-EMC/fv3atm/issues/797

In the fv3atm, some CCPP physics schemes read per-tile static files. With a global simulation that has a single static nest (tile 7) the nest will read tile 1, which is the first global tile. This is because the model is using tile_of_mosaic instead of global_tile.

Describe the solution you'd like The atmosphere_control_data should be able to provide the global_tile.

Suggested Solution In addition to relevant model-level changes: ```diff diff --git a/driver/fvGFS/atmosphere.F90 b/driver/fvGFS/atmosphere.F90 index dcd43fb..a718b95 100644 --- a/driver/fvGFS/atmosphere.F90 +++ b/driver/fvGFS/atmosphere.F90 @@ -864,17 +864,18 @@ contains end subroutine atmosphere_pref - subroutine atmosphere_control_data (i1, i2, j1, j2, kt, p_hydro, hydro, tile_num) + subroutine atmosphere_control_data (i1, i2, j1, j2, kt, p_hydro, hydro, tile_of_mosaic, global_tile_num) integer, intent(out) :: i1, i2, j1, j2, kt logical, intent(out), optional :: p_hydro, hydro - integer, intent(out), optional :: tile_num + integer, intent(out), optional :: tile_of_mosaic, global_tile_num i1 = Atm(mygrid)%bd%isc i2 = Atm(mygrid)%bd%iec j1 = Atm(mygrid)%bd%jsc j2 = Atm(mygrid)%bd%jec kt = Atm(mygrid)%npz - if (present(tile_num)) tile_num = Atm(mygrid)%tile_of_mosaic + if (present(global_tile_num)) global_tile_num = Atm(mygrid)%global_tile + if (present(tile_of_mosaic)) tile_of_mosaic = Atm(mygrid)%tile_of_mosaic if (present(p_hydro)) p_hydro = Atm(mygrid)%flagstruct%phys_hydrostatic if (present( hydro)) hydro = Atm(mygrid)%flagstruct%hydrostatic ```

Describe alternatives you've considered Can't think of any.

Additional context This is for the Water in the West project, which aims to have a static nest over the north-east pacific within a global model.