JCSDA / CRTMv3

CRTMv3 repository for coordinated development and releases. Code history is not carried in this repository prior to v3, to reduce the cloning overhead. For v2.x history leading up to v3, see JCSDA/crtm repository.
Other
6 stars 6 forks source link

stream selection update in v2.4.1 #121

Closed chengdang closed 5 months ago

chengdang commented 6 months ago

The stream calculation updates made in v2.4.1 were lost during git repo migration. Creating a new PR to address this issue.

https://github.com/JCSDA-internal/crtm/issues/243 https://github.com/JCSDA-internal/crtm/pull/333

chengdang commented 5 months ago

Updates, an issue has been discovered by Ben with the v2.4.1 implementation. For details see PR https://github.com/JCSDA/CRTMv3/pull/122

chengdang commented 5 months ago

To fix this issue, code updates have been pushed to branch feature/cd_num_pcoeff.

In particular, the following conditional statements need to be updated in major CRTM modules (forward, tl, ad, kmatrix) https://github.com/JCSDA/CRTMv3/blob/43305279317ff3c9f63758ec09a97b03e902f8a5/src/CRTM_Forward_Module.f90#L904

This is because:

With the original IF statement in dev branch: https://github.com/JCSDA/CRTMv3/blob/262599de6f191e0bec460c6f9fbad8b2c3ac732c/src/CRTM_Forward_Module.f90#L900 It contains two cases:

  1. AtmOptics(nt)%n_Legendre_Terms == 0, clear sky, molecular Rayleigh scattering
  2. AtmOptics(nt)%n_Legendre_Terms == 2, aerosol/cloud sky and MieParameter < 0.01_fp

The equivalent if statement is now IF( AtmOptics(nt)%n_Legendre_Terms <= 4 ) with the updated function https://github.com/JCSDA/CRTMv3/blob/43305279317ff3c9f63758ec09a97b03e902f8a5/src/RTSolution/CRTM_RTSolution.f90#L1245