CFMIP / COSPv2.0

COSP - The CFMIP (Cloud Feedbacks Model Intercomparison Project) Observation Simulator Package
41 stars 38 forks source link

Inconsistent unit labels for hgt_matrix #94

Open brhillman opened 1 month ago

brhillman commented 1 month ago

It looks like the units for hgt_matrix and hgt_matrix_half are labeled incorrectly in the definition of cosp_column_inputs. The comment associated with the declaration says these should be in km, but throughout the code it looks like they are treated as being in units of m. For example, line 661 in cosp.F90 sets misrIN%zfull = cospgridIN%hgt_matrix directly, and the MISR simulator seems to treat zfull as having units of m, since the cloud top height bins (which are in km) are multiplied by 1000 when comparing to zfull (line 273 in MISR_simulator.F90). Likewise, line 716 in cosp.F90 sets cloudsatIN%hgt_matrix = cospgridIN%hgt_matrix, but in the call to quickbeam_subcolumn at line 897, hgt_matrix is divided by 1000 to get units in km, which quickbeam expects. It looks like at least units are handled consistently in the component simulators, but it would be helpful to the user of the top-level comment for hgt_matrix were consistent with the usage in the simulators. It would also be helpful to state the expected units of zfull in the MISR simulator.