Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
97 commits
Select commit Hold shift + click to select a range
3a122a2
Add physics/NRL_parse_tracers.F90 as a replacement for GFDL_parse_tra…
climbfuji Sep 18, 2024
edaa649
Add missing tracers from NEPTUNE to physics/NRL_parse_tracers.F90
climbfuji Sep 18, 2024
faee4ed
Remove physics/NRL_parse_tracers.F90, physics/MP/GFDL/GFDL_parse_trac…
climbfuji Sep 25, 2024
baff7cb
Bug fix in physics/GWD/ugwp_driver_v0.F to prevent using uninitialize…
climbfuji Dec 4, 2024
3a6de8b
Merge remote-tracking branch 'grant/rrfsv1-to-ufs/dev6' into ufs-dev-…
scrasmussen Feb 13, 2025
f3077d2
Merge pull request #1111 from scrasmussen/ufs-dev-pr235
scrasmussen Feb 14, 2025
71b1768
Merge branch 'ufs/dev' of https://github.com/ufs-community/ccpp-physi…
dustinswales Feb 14, 2025
3f601d7
Merge pull request #1112 from dustinswales/ufs-dev-pr251
dustinswales Feb 14, 2025
9b41deb
Merge branch 'rrfsv1-to-ufs/dev10' into ufs-dev-pr252
scrasmussen Feb 20, 2025
ff08945
Merge pull request #1114 from scrasmussen/ufs-dev-pr252
dustinswales Feb 20, 2025
0edbdcf
Merge branch 'main' into bugfix/ugwp_driver_v0_uninit_main
grantfirl Mar 10, 2025
0f1b726
Merge pull request #1104 from climbfuji/bugfix/ugwp_driver_v0_uninit_…
grantfirl Mar 10, 2025
1471b2b
Merge branch 'conv_hr5update' into ufs-dev-PR232
hertneky Mar 10, 2025
9fdd4f9
Merge branch 'mr2_rst' into ufs-dev-PR232
hertneky Mar 11, 2025
89bdfb8
Merge branch 'main' of https://github.com/NCAR/ccpp-physics into feat…
climbfuji Mar 18, 2025
b372caf
Merge pull request #1087 from climbfuji/feature/add_nrl_parse_tracers…
dustinswales Mar 18, 2025
7e42e7e
Merge pull request #1117 from hertneky/ufs-dev-PR232
grantfirl Mar 20, 2025
1ec0940
Merge branch 'updraft_velocity' into ufs-dev-PR246
hertneky Mar 26, 2025
0d4b4b9
fix intent error in GFS_suite_interstitial_3_run
grantfirl Mar 31, 2025
addf7c6
Merge pull request #1121 from hertneky/ufs-dev-PR246
grantfirl Mar 31, 2025
d89b29a
Merge branch 'feature/remove_gfs_int_radphys_reset' into ufs-dev-PR258
grantfirl Apr 10, 2025
fce2a4e
Merge pull request #1127 from grantfirl/ufs-dev-PR258
grantfirl Apr 11, 2025
8d3d071
add three ecmwf related files
BoYang-NOAA Apr 15, 2025
a185032
Merge branch 'memcheck_fixes' into ufs-dev-PR260-memcheck-fixes
scrasmussen Apr 18, 2025
3f58f9f
Merge branch 'feature/cmake_updates_from_neptune_20250318_for_ufs_dev…
scrasmussen Apr 18, 2025
e45f198
hotfix: bumping Ubuntu version to latest, bumping python version to o…
scrasmussen Apr 21, 2025
5e2d647
Merge remote-tracking branch 'ufs-community/ufs/dev' into ecmwf
BoYang-NOAA Apr 22, 2025
2597f9f
Merge pull request #1135 from scrasmussen/hotfix/bump-ci-ubuntu-version
scrasmussen Apr 22, 2025
1b6dfb5
Merge branch 'main' into ufs-dev-PR259-CMake-changes
scrasmussen Apr 22, 2025
28016dd
Merge branch 'main' into ufs-dev-PR260-memcheck-fixes
scrasmussen Apr 22, 2025
64b3241
Checking to define macro CCPP only if it is not defined reduces macro…
scrasmussen Jan 13, 2024
98a8043
Fixing 'Warning: Deleted feature: Start expression in DO loop at (1) …
scrasmussen Jan 17, 2024
7d9bbbb
Fixed GNU warning 'Warning: Missing '&' in continued character consta…
scrasmussen Jan 15, 2024
cecbb86
Fixed GNU warnings 'Warning: Nonconforming tab character at (1) [-Wta…
scrasmussen Jan 14, 2024
7e71479
Fixed GNU 'Warning: Line truncated at (1) [-Wline-truncation]' warnings
scrasmussen Jan 14, 2024
733f66e
Fix 'Warning: CHARACTER expression will be truncated in assignment'
scrasmussen Jan 14, 2024
148b322
Fix GNU warning "Warning: Return value err_message of function declar…
scrasmussen Jan 17, 2024
dec7ce4
Merge pull request #1105 from scrasmussen/gnu-wall-warning-reduction-…
scrasmussen Apr 23, 2025
5ace315
Moving pull_request_template up a directory so it will be used
scrasmussen Apr 23, 2025
96faa93
PR and issue reference simplified and whitespace cleanup
scrasmussen Apr 23, 2025
7124268
add a doc section in ecmwf_ngw_emc
BoYang-NOAA Apr 29, 2025
777b73e
Restrict Github actions CI mainly to NCAR's upstream and ufs-communit…
scrasmussen Apr 30, 2025
66dd7f8
Merge pull request #1133 from scrasmussen/ufs-dev-PR260-memcheck-fixes
scrasmussen May 1, 2025
a6e2581
Merge branch 'main' into ufs-dev-PR259-CMake-changes
grantfirl May 1, 2025
47657f4
Merge pull request #1134 from scrasmussen/ufs-dev-PR259-CMake-changes
grantfirl May 1, 2025
00582b8
Merge branch 'main' into enhancement/restrict-ci-mainly-to-upstream
grantfirl May 1, 2025
98fbceb
revert scientific documentation
BoYang-NOAA May 5, 2025
726586e
add copyright/Apache licence header
BoYang-NOAA May 5, 2025
4d1c5ce
Optional argument cleanup: Radiation
dustinswales Nov 18, 2024
78f884c
Optional argument cleanup: Convection
dustinswales Nov 18, 2024
283f8ac
Optional argument cleanup: GWD
dustinswales Nov 19, 2024
3397441
Optional argument cleanup: MP
dustinswales Nov 19, 2024
a9c60ce
Optional argument cleanup: PBL
dustinswales Nov 19, 2024
7debd5a
Optional argument cleanup: Surface Layer
dustinswales Nov 19, 2024
6bd111f
Optional argument cleanup: Surface Models
dustinswales Dec 13, 2024
bd1c5fa
Optional argument cleanup: CICE and Smoke
dustinswales Dec 13, 2024
f6b287a
Optional argument cleanup: Some interstitials
dustinswales Dec 13, 2024
da90012
Revert removal of optional arguments in Interstitial schemes.
dustinswales Dec 17, 2024
69a37c2
REvert one more change
dustinswales Dec 18, 2024
ed249cc
Bug
dustinswales Jan 27, 2025
7acd9b0
Anothe bug
dustinswales Jan 27, 2025
b8ad3ed
SOme more changes from RTs
dustinswales Feb 12, 2025
e2fa468
Revert some changes
dustinswales Feb 19, 2025
21752aa
Revert merge conflict
dustinswales Feb 19, 2025
b5864ed
Merge pull request #1138 from scrasmussen/enhancement/restrict-ci-mai…
scrasmussen May 6, 2025
706cf9f
revert accidental changes
hertneky May 6, 2025
8b51428
another thing missed
hertneky May 6, 2025
c3f9a68
bug fix to maxMF check: only access when do_mynnedmf=.true.
SamuelTrahanNOAA May 13, 2025
b39a054
Merge pull request #1139 from hertneky/ufs-dev-248
grantfirl May 16, 2025
b9dd14b
Merge pull request #1137 from scrasmussen/enhancement/pr-template
scrasmussen May 20, 2025
f22ac1c
Merge branch 'nssl3m-update2025a' into ufs-dev-PR254
hertneky May 27, 2025
ffb2069
Change indices i3 and j3 in routine aer_property in radiation_aerosol…
climbfuji Jun 4, 2025
a0935cf
nrest=n+4 in mersenne_twister
NickSzapiro-NOAA Jun 10, 2025
53d32fa
fix issue with namelist for NSSL MP
grantfirl Jun 13, 2025
e27736c
update NSSL MP to use internal namelist like other physics in UFS
grantfirl Jun 17, 2025
04cb62d
add iostat to internal namelist read to capture read error for NSSL M…
grantfirl Jun 17, 2025
1666136
Merge branch 'lakefrac_ice_sfcr' into ufs-dev-PR281
grantfirl Jun 18, 2025
15e19ee
Merge branch 'canopywater_glacier' into ufs-dev-PR278
grantfirl Jun 18, 2025
d2c4e0f
Merge pull request #1142 from grantfirl/ufs-dev-PR254
grantfirl Jun 20, 2025
d93dbbb
Merge branch 'main' into ufs-dev-PR281
grantfirl Jun 20, 2025
cfcaf63
Merge branch 'main' into ufs-dev-PR278
grantfirl Jun 20, 2025
db40996
Merge branch 'gcycleupdate' into ufs-dev-PR278
grantfirl Jun 20, 2025
c3160d4
Merge pull request #1143 from grantfirl/ufs-dev-PR281
grantfirl Jun 20, 2025
ff1f277
Merge branch 'main' into ufs-dev-PR278
grantfirl Jun 20, 2025
7f7a407
Merge pull request #1144 from grantfirl/ufs-dev-PR278
grantfirl Jun 23, 2025
0182088
update CMakeLists.txt to use FMS for FV3 only
grantfirl Jun 23, 2025
423c290
Merge branch 'main' into combo_20250625
grantfirl Jun 25, 2025
110761c
Merge branch 'ufs/dev' into combo_20250625
grantfirl Jun 26, 2025
e8133cc
Merge branch 'ecmwf' into combo_20250625
grantfirl Jun 27, 2025
d287d74
Merge branch 'bugfix/maxmf-check' into combo_20250625
grantfirl Jun 27, 2025
477b6a2
Merge branch 'bugfix/radiation_aerosols_restart_reproducibility_neptu…
grantfirl Jun 27, 2025
59b9bc1
Merge branch 'mersenne_nrest' into combo_20250625
grantfirl Jun 27, 2025
b20022b
tlim_okw instead of tlim_fgf in cires_ugwpv1_triggers.F90
NickSzapiro-NOAA Jun 30, 2025
21bce1e
Initialize intent(out) zlwb in cires_ugwpv1_oro.F90
NickSzapiro-NOAA Jun 30, 2025
1694611
Set jj if dlat > 0.0, dlon <= 0.0 in sfcsub.F
NickSzapiro-NOAA Jun 30, 2025
2a26a8c
Merge branch 'ufs/dev' into combo_20250625
grantfirl Jul 8, 2025
ef272c1
Merge remote-tracking branch 'nick-fork/warning_explicit_gwd' into co…
grantfirl Jul 8, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
## Description of Changes:
## Description of Changes:
One or more paragraphs describing the problem, solution, and required changes.

## Tests Conducted:
Explicitly state what tests were run on these changes, or if any are still pending (for README or other text-only changes, just put "None required". Make note of the compilers used, the platform/machine, and other relevant details as necessary. For more complicated changes, or those resulting in scientific changes, please be explicit!
**OR** Add any links to tests conducted. For example, "See ufs-community/ufs-weather-model/pull/<pr_number>"
## Tests Conducted:
Explicitly state what tests were run on these changes, or if any are still pending (for README or other text-only changes, just put "None required". Make note of the compilers used, the platform/machine, and other relevant details as necessary. For more complicated changes, or those resulting in scientific changes, please be explicit!
**OR** Add any links to tests conducted. For example, "See ufs-community/ufs-weather-model#<pr_number>"

## Dependencies:
Add any links to parent PRs (e.g. SCM and/or UFS PRs) or submodules (e.g. rte-rrtmgp). For example:
- NCAR/ccpp-framework/pull/<pr_number>
- NOAA-EMC/fv3atm/pull/<pr_number>
- ufs-community/ufs-weather-model/pull/<pr_number>
- NCAR/ccpp-framework#<pr_number>
- NOAA-EMC/fv3atm#<pr_number>
- ufs-community/ufs-weather-model/#<pr_number>

## Documentation:
Does this PR add new capabilities that need to be documented or require modifications to the existing documentation? If so, brief supporting material can be provided here. Contact the CODEOWNERS if your PR requires extensive updates to the documentation. See https://github.com/NCAR/ccpp-doc for Technical Documentation or https://dtcenter.org/community-code/common-community-physics-package-ccpp/documentation for the latest Scientific Documentation.

## Issue (optional):
If this PR is resolving or referencing one or more issues, in this repository or elewhere, list them here. For example, "Fixes issue mentioned in #123" or "Related to bug in https://github.com/NCAR/other_repository/pull/63"
## Issue (optional):
If this PR is resolving or referencing one or more issues, in this repository or elewhere, list them here. For example, "Fixes issue mentioned in #123" or "Related to bug in NCAR/other_repository#123"

## Contributors (optional):
## Contributors (optional):
If others have contributed to this work aside from the PR author, list them here

1 change: 1 addition & 0 deletions .github/workflows/basic_checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on: [push, pull_request]

jobs:
build:
if: github.repository == 'NCAR/ccpp-physics' || github.repository == 'ufs-community/ccpp-physics'

runs-on: macos-latest

Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/ci_fv3_ccpp_prebuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ on: [push, pull_request]

jobs:
ccpp-prebuild-FV3:
if: github.repository == 'NCAR/ccpp-physics' || github.repository == 'ufs-community/ccpp-physics'

# The type of runner that the job will run on
runs-on: ubuntu-20.04
runs-on: ubuntu-latest

steps:
- name: Checkout current ccpp-physics code
Expand Down Expand Up @@ -38,11 +39,11 @@ jobs:
git remote add remote_local $GIT_REMOTE_URL
git fetch remote_local $GIT_REMOTE_BRANCH
git checkout remote_local/$GIT_REMOTE_BRANCH
- name: Set up Python 3.8.5

- name: Set up Python 3.10.13
uses: actions/setup-python@v3
with:
python-version: 3.8.5
python-version: 3.10.13

- name: Add conda to system path
run: |
Expand All @@ -53,4 +54,4 @@ jobs:
run: |
cd /home/runner/work/ccpp-physics/ccpp-physics/fv3atm/ccpp/
mkdir -p /home/runner/work/ccpp-physics/ccpp-physics/fv3atm/bin/ccpp/physics/physics/
./framework/scripts/ccpp_prebuild.py --config config/ccpp_prebuild_config.py
./framework/scripts/ccpp_prebuild.py --config config/ccpp_prebuild_config.py
11 changes: 6 additions & 5 deletions .github/workflows/ci_scm_ccpp_prebuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ on: [push, pull_request]

jobs:
ccpp-prebuild-SCM:
if: github.repository == 'NCAR/ccpp-physics' || github.repository == 'ufs-community/ccpp-physics'

# The type of runner that the job will run on
runs-on: ubuntu-20.04
runs-on: ubuntu-latest

steps:

Expand Down Expand Up @@ -42,11 +43,11 @@ jobs:
git remote add remote_local $GIT_REMOTE_URL
git fetch remote_local $GIT_REMOTE_BRANCH
git checkout remote_local/$GIT_REMOTE_BRANCH
- name: Set up Python 3.8.5

- name: Set up Python 3.10.13
uses: actions/setup-python@v3
with:
python-version: 3.8.5
python-version: 3.10.13

- name: Add conda to system path
run: |
Expand All @@ -58,4 +59,4 @@ jobs:
cd /home/runner/work/ccpp-physics/ccpp-physics/ccpp-scm/
git status
mkdir -p /home/runner/work/ccpp-physics/ccpp-physics/ccpp-scm/scm/bin/ccpp/physics/physics/
./ccpp/framework/scripts/ccpp_prebuild.py --config ccpp/config/ccpp_prebuild_config.py
./ccpp/framework/scripts/ccpp_prebuild.py --config ccpp/config/ccpp_prebuild_config.py
7 changes: 6 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,12 @@ target_include_directories(ccpp_physics PUBLIC
target_link_libraries(ccpp_physics PRIVATE MPI::MPI_Fortran)
target_link_libraries(ccpp_physics PUBLIC w3emc::w3emc_d
sp::sp_d
NetCDF::NetCDF_Fortran)
NetCDF::NetCDF_Fortran
)
#add FMS for FV3 only
if(FV3)
target_link_libraries(ccpp_physics PUBLIC fms)
endif()

# Define where to install the library
install(TARGETS ccpp_physics
Expand Down
1 change: 0 additions & 1 deletion CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ physics/GWD/ugwpv1_gsldrag_post.* @md
physics/GWD/unified_ugwp* @mdtoyNOAA @grantfirl @rhaesung @Qingfu-Liu @dustinswales
physics/MP/Ferrier_Aligo/module_MP_FER_HIRES.* @ericaligo-NOAA @grantfirl @rhaesung @Qingfu-Liu @dustinswales
physics/MP/Ferrier_Aligo/mp_fer_hires.* @ericaligo-NOAA @grantfirl @rhaesung @Qingfu-Liu @dustinswales
physics/MP/GFDL/GFDL_parse_tracers.F90 @grantfirl @rhaesung @Qingfu-Liu @dustinswales
physics/MP/GFDL/gfdl_cloud_microphys.* @RuiyuSun @grantfirl @rhaesung @Qingfu-Liu @dustinswales
physics/MP/GFDL/module_gfdl_cloud_microphys.* @RuiyuSun @grantfirl @rhaesung @Qingfu-Liu @dustinswales
physics/MP/GFDL/fv_sat_adj.* @RuiyuSun @grantfirl @rhaesung @Qingfu-Liu @dustinswales
Expand Down
4 changes: 3 additions & 1 deletion physics/CONV/C3/cu_c3_driver.F90
Original file line number Diff line number Diff line change
Expand Up @@ -657,7 +657,9 @@ subroutine cu_c3_driver_run(ntracer,garea,im,km,dt,flag_init,flag_restart,&
enddo
do i = its,itf
if(mconv(i).lt.0.)mconv(i)=0.
if((dx(i)<6500.).and.do_mynnedmf.and.(maxMF(i).gt.0.))ierr(i)=555
if(do_mynnedmf) then
if((dx(i)<6500.).and.(maxMF(i).gt.0.))ierr(i)=555
endif
enddo
!$acc end kernels
if (dx(its)<6500.) then
Expand Down
2 changes: 1 addition & 1 deletion physics/CONV/Grell_Freitas/cu_gf_deep.F90
Original file line number Diff line number Diff line change
Expand Up @@ -5496,7 +5496,7 @@ subroutine get_partition_liq_ice(ierr,tn,po_cup, p_liq_ice,melting_layer
,itf,ktf,its,ite, kts,kte, cumulus )
implicit none
character *(*), intent (in) :: cumulus
integer ,intent (in ) :: itf,ktf, its,ite, kts,kte
integer ,intent (in ) :: itf,ktf, its,ite, kts,kte
real(kind=kind_phys), intent (in ), dimension(its:ite,kts:kte) :: tn,po_cup
real(kind=kind_phys), intent (inout), dimension(its:ite,kts:kte) :: p_liq_ice,melting_layer
!$acc declare copyin(tn,po_cup) copy(p_liq_ice,melting_layer)
Expand Down
76 changes: 38 additions & 38 deletions physics/GWD/cires_tauamf_data.F90
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ subroutine read_tau_amf(me, master, errmsg, errflg)
if(iernc.ne.0) then
write(errmsg,'(*(a))') "read_tau_amf: cannot open file_limb_tab data-file ", &
trim(ugwp_taufile)
print *, 'cannot open ugwp-v1 tau-file=',trim(ugwp_taufile)
print *, 'cannot open ugwp-v1 tau-file=',trim(ugwp_taufile)
errflg = 1
return
else
Expand All @@ -51,26 +51,26 @@ subroutine read_tau_amf(me, master, errmsg, errflg)
status = nf90_inquire_dimension(ncid, DimID, len =ntau_d2t )

if (me == master) print *, ntau_d1y, ntau_d2t, ' dimd of tau_ngw ugwp-v1 '
if (ntau_d2t .le. 0 .or. ntau_d1y .le. 0) then
print *, 'ugwp-v1 tau-file=', trim(ugwp_taufile)
print *, ' ugwp-v1: ', 'ntau_d2t=',ntau_d2t, 'ntau_d2t=',ntau_d1y
stop
endif
if (ntau_d2t .le. 0 .or. ntau_d1y .le. 0) then
print *, 'ugwp-v1 tau-file=', trim(ugwp_taufile)
print *, ' ugwp-v1: ', 'ntau_d2t=',ntau_d2t, 'ntau_d2t=',ntau_d1y
stop
endif

if (.not.allocated(ugwp_taulat)) allocate (ugwp_taulat(ntau_d1y ))
if (.not.allocated(days_limb)) allocate (days_limb(ntau_d2t))
if (.not.allocated(tau_limb)) allocate (tau_limb(ntau_d1y, ntau_d2t ))
if (.not.allocated(tau_limb)) allocate (tau_limb(ntau_d1y, ntau_d2t ))

iernc=nf90_inq_varid( ncid, 'DAYS', vid )
iernc=nf90_inq_varid( ncid, 'DAYS', vid )
iernc= nf90_get_var( ncid, vid, days_limb)
iernc=nf90_inq_varid( ncid, 'LATS', vid )
iernc=nf90_inq_varid( ncid, 'LATS', vid )
iernc= nf90_get_var( ncid, vid, ugwp_taulat)
iernc=nf90_inq_varid( ncid, 'ABSMF', vid )
iernc=nf90_inq_varid( ncid, 'ABSMF', vid )
iernc= nf90_get_var( ncid, vid, tau_limb)

iernc=nf90_close(ncid)
iernc=nf90_close(ncid)

endif
endif

end subroutine read_tau_amf

Expand Down Expand Up @@ -102,22 +102,22 @@ subroutine cires_indx_ugwp (npts, me, master, dlat,j1_tau,j2_tau, w1_j1tau, w2_j


j2_tau(j) = min(j2_tau(j),ntau_d1y)
j1_tau(j) = max(j2_tau(j)-1,1)
j1_tau(j) = max(j2_tau(j)-1,1)

if (j1_tau(j) /= j2_tau(j) ) then
w2_j2tau(j) = (dlat(j) - ugwp_taulat(j1_tau(j))) &
/ (ugwp_taulat(j2_tau(j))-ugwp_taulat(j1_tau(j)))
/ (ugwp_taulat(j2_tau(j))-ugwp_taulat(j1_tau(j)))
else
w2_j2tau(j) = 1.0
endif
w1_j1tau(j) = 1.0 - w2_j2tau(j)
w1_j1tau(j) = 1.0 - w2_j2tau(j)
enddo
return
end subroutine cires_indx_ugwp

!>
subroutine tau_amf_interp(me, master, im, idate, fhour, j1_tau,j2_tau, ddy_j1, ddy_j2, tau_ddd)
use machine, only: kind_phys
use machine, only: kind_phys
implicit none

!input
Expand All @@ -141,38 +141,38 @@ subroutine tau_amf_interp(me, master, im, idate, fhour, j1_tau,j2_tau, ddy_j1, d

it1 = 2
do iday=1, ntau_d2t
if (fddd .lt. days_limb(iday) ) then
it2 = iday
exit
endif
enddo
if (fddd .lt. days_limb(iday) ) then
it2 = iday
exit
endif
enddo

it2 = min(it2,ntau_d2t)
it1 = max(it2-1,1)
if (it2 > ntau_d2t ) then
print *, ' Error in time-interpolation for tau_amf_interp '
print *, ' it1, it2, ntau_d2t ', it1, it2, ntau_d2t
print *, ' Error in time-interpolation see cires_tauamf_data.F90 '
stop
endif
it2 = min(it2,ntau_d2t)
it1 = max(it2-1,1)
if (it2 > ntau_d2t ) then
print *, ' Error in time-interpolation for tau_amf_interp '
print *, ' it1, it2, ntau_d2t ', it1, it2, ntau_d2t
print *, ' Error in time-interpolation see cires_tauamf_data.F90 '
stop
endif

w2 = (fddd-days_limb(it1))/(days_limb(it2)-days_limb(it1))
w1 = 1.0-w2
w2 = (fddd-days_limb(it1))/(days_limb(it2)-days_limb(it1))
w1 = 1.0-w2

do i=1, im
j1 = j1_tau(i)
j2 = j2_tau(i)
tx1 = tau_limb(j1, it1)*ddy_j1(i)+tau_limb(j2, it1)*ddy_j2(i)
tx2 = tau_limb(j1, it2)*ddy_j1(i)+tau_limb(j2, it2)*ddy_j2(i)
tau_ddd(i) = tx1*w1 + w2*tx2
do i=1, im
j1 = j1_tau(i)
j2 = j2_tau(i)
tx1 = tau_limb(j1, it1)*ddy_j1(i)+tau_limb(j2, it1)*ddy_j2(i)
tx2 = tau_limb(j1, it2)*ddy_j1(i)+tau_limb(j2, it2)*ddy_j2(i)
tau_ddd(i) = tx1*w1 + w2*tx2
enddo

end subroutine tau_amf_interp

!>
subroutine gfs_idate_calendar(idate, fhour, ddd, fddd)

use machine, only: kind_phys
use machine, only: kind_phys
implicit none
! input
integer, intent(in) :: idate(4)
Expand Down
3 changes: 2 additions & 1 deletion physics/GWD/cires_ugwpv1_oro.F90
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,8 @@ subroutine orogw_v1 (im, km, imx, me, master, dtp, kdt, do_tofd, &
dusfc(i) = 0.0
dvsfc(i) = 0.0
ipt(i) = 0
enddo
enddo
zlwb(:) = 0.0

! ---- for lm and gwd calculation points
!cires_ugwp_initialize.F90: real, parameter :: hpmax=2400.0, hpmin=25.0
Expand Down
2 changes: 1 addition & 1 deletion physics/GWD/cires_ugwpv1_triggers.F90
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ subroutine get_spectra_tau_okw(nw, im, levs, trig_okw, xlatd, sinlat, coslat, t
if (dmax >= tlim_okw) kex = kex+1
do k=klow+1, ktop
dtot = abs(trig_okw(i,k))
if (dtot >= tlim_fgf ) kex = kex+1
if (dtot >= tlim_okw ) kex = kex+1
if ( dtot > dmax) then
klev(i) = k
dmax = dtot
Expand Down
Loading