Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doxygen in CALPBL.f CALPBLREGIME.f CALPOT.f CALPW.f. #466

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
43 changes: 13 additions & 30 deletions sorc/ncep_post.fd/CALPBL.f
Original file line number Diff line number Diff line change
@@ -1,34 +1,17 @@
!> @file
!
!> SUBPROGRAM: CALPBL COMPUTES PBL HEIGHT BASED ON BULK RCH NUMBER
!!
!! ABSTRACT:
!! THIS ROUTINE COMPUTES THE BULK RICHARDSON NUMBER
!! AND PBL HEIGHT ABOVE SURFACE
!!
!! PROGRAM HISTORY LOG:
!! 06-05-04 M TSIDULKO
!!
!! USAGE: CALL CALPBL(PBLRI)
!! INPUT ARGUMENT LIST:
!!
!! OUTPUT ARGUMENT LIST:
!! PBLRI - PBL HEIGHT ABOVE GROUND
!!
!! OUTPUT FILES:
!! NONE
!!
!! SUBPROGRAMS CALLED:
!! UTILITIES:
!! NONE
!! LIBRARY:
!! COMMON -
!! CTLBLK
!!
!! ATTRIBUTES:
!! LANGUAGE: FORTRAN
!! MACHINE :
!!
!> @brief Subroutine that computes PBL height based on bulk RCH number.
!>
!> This routine computes the bulk Richardson number
!> and PBL height above surface.
!>
!> @param[out] PBLRI PBL height above ground.
!>
!> ### Program history log:
!> Date | Programmer | Comments
!> -----|------------|---------
!> 2006-05-04 | M Tsidulko | Initial
!>
!> @author M Tsidulko @date 2006-05-04
SUBROUTINE CALPBL(PBLRI)

!
Expand Down
68 changes: 25 additions & 43 deletions sorc/ncep_post.fd/CALPBLREGIME.f
Original file line number Diff line number Diff line change
@@ -1,47 +1,29 @@
!> @file
! . . .
!> SUBPROGRAM: CALPBL COMPUTES PBL HEIGHT BASED ON BULK RCH NUMBER
!!
!! ABSTRACT:
!! THIS ROUTINE COMPUTES THE BULK RICHARDSON NUMBER BASED ON ALGORITHMS
!! FROM WRF SURFACE LAYER AND THEN DERIVE PBL REGIME AS FOLLOWS:
!! 1. BR >= 0.2;
!! REPRESENTS NIGHTTIME STABLE CONDITIONS (REGIME=1),
!!
!! 2. BR < 0.2 .AND. BR > 0.0;
!! REPRESENTS DAMPED MECHANICAL TURBULENT CONDITIONS
!! (REGIME=2),
!!
!! 3. BR == 0.0
!! REPRESENTS FORCED CONVECTION CONDITIONS (REGIME=3),
!!
!! 4. BR < 0.0
!! REPRESENTS FREE CONVECTION CONDITIONS (REGIME=4).
!! .
!!
!! PROGRAM HISTORY LOG:
!! 07-04-27 H CHUANG
!!
!! USAGE: CALL CALPBLREGIME(PBLREGIME)
!! INPUT ARGUMENT LIST:
!!
!! OUTPUT ARGUMENT LIST:
!! PBLRI - PBL HEIGHT ABOVE GROUND
!!
!! OUTPUT FILES:
!! NONE
!!
!! SUBPROGRAMS CALLED:
!! UTILITIES:
!! NONE
!! LIBRARY:
!! COMMON -
!! CTLBLK
!!
!! ATTRIBUTES:
!! LANGUAGE: FORTRAN
!! MACHINE :
!!
!> @brief Subroutine that computes PBL height based on bulk RCH number.
!>
!> This routine computes the bulk Richardson number based on algorithms
!> from WRF surface layer and then derive PBL regime as follows:
!> 1. BR >= 0.2;
!> Represents nighttime stable conditions (Regime=1),
!>
!> 2. BR < 0.2 .AND. BR > 0.0;
!> Represents damped mechanical turbulent conditions
!> (Regime=2),
!>
!> 3. BR == 0.0
!> Represents forced convection conditions (Regime=3),
!>
!> 4. BR < 0.0
!> Represnets free convection conditions (Regime=4).
!>
!> @param[out] PBLRI PBL Height above ground.
!>
!> ### Program history log:
!> Date | Programmer | Comments
!> -----|------------|---------
!> 2007-04-27 | H Chuang | Initial
!>
!> @author H Chuang @date 2007-04-27
SUBROUTINE CALPBLREGIME(PBLREGIME)

!
Expand Down
53 changes: 18 additions & 35 deletions sorc/ncep_post.fd/CALPOT.f
Original file line number Diff line number Diff line change
@@ -1,39 +1,22 @@
!> @file
!
!> SUBPROGRAM: CALPOT COMPUTES POTENTIAL TEMPERATURE
!! PRGRMMR: TREADON ORG: W/NP2 DATE: 92-12-24
!!
!! ABSTRACT:
!! GIVEN PRESSURE AND TEMPERATURE THIS ROUTINE RETURNS
!! THE POTENTIAL TEMPERATURE.
!!
!! PROGRAM HISTORY LOG:
!! 92-12-24 RUSS TREADON
!! 98-06-15 T BLACK - CONVERSION FROM 1-D TO 2-D
!! 00-01-04 JIM TUCCILLO - MPI VERSION
!! 02-04-24 MIKE BALDWIN - WRF VERSION
!!
!! USAGE: CALL CALPOT(P1D,T1D,THETA)
!! INPUT ARGUMENT LIST:
!! P1D - PRESSURE (PA)
!! T1D - TEMPERATURE (K)
!!
!! OUTPUT ARGUMENT LIST:
!! THETA - POTENTIAL TEMPERATURE (K)
!!
!! OUTPUT FILES:
!! NONE
!!
!! SUBPROGRAMS CALLED:
!! UTILITIES:
!! NONE
!! LIBRARY:
!! NONE
!!
!! ATTRIBUTES:
!! LANGUAGE: FORTRAN 90
!! MACHINE : CRAY C-90
!!
!> @brief Subroutine that computes potential temperature.
!>
!> Given pressure and temperature this routine returns
!> the potential temperature.
!>
!> @param[in] P1D pressures (Pa).
!> @param[in] T1D temperatures (K).
!> @param[out] THETA potential temperatures (K).
!>
!> ### Program history log:
!> Date | Programmer | Comments
!> -----|------------|---------
!> 1992-12-24 | Russ Treadon | Initial
!> 1998-06-15 | T Black | Convesion from 1-D to 2-D
!> 2000-01-04 | Jim Tuccillo | MPI Version
!> 2002-04-24 | Mike Baldwin | WRF Version
!>
!> @author Russ Treadon W/NP2 @date 1992-12-24
SUBROUTINE CALPOT(P1D,T1D,THETA)

!
Expand Down
95 changes: 38 additions & 57 deletions sorc/ncep_post.fd/CALPW.f
Original file line number Diff line number Diff line change
@@ -1,61 +1,42 @@
!> @file
! . . .
!> SUBPROGRAM: CALPW COMPUTES
!! PRGRMMR: TREADON ORG: W/NP2 DATE: 92-12-24
!!
!! ABSTRACT:
!! THIS ROUTINE COMPUTES PRECIPITABLE WATER IN A COLUMN
!! EXTENDING FROM THE FIRST ATMOSPHERIC ETA LAYER TO THE
!! MODEL TOP. THE DEFINITION USED IS
!! TOP
!! PRECIPITABLE WATER = SUM (Q+CLDW) DP*HTM/G
!! BOT
!! WHERE,
!! BOT IS THE FIRST ETA LAYER,
!! TOP IS THE MODEL TOP,
!! Q IS THE SPECIFIC HUMIDITY (KG/KG) IN THE LAYER
!! CLDW IS THE CLOUD WATER (KG/KG) IN THE LAYER
!! DP (Pa) IS THE LAYER THICKNESS.
!! HTM IS THE HEIGHT MASK AT THAT LAYER (=0 IF BELOW GROUND)
!! G IS THE GRAVITATIONAL CONSTANT
!!
!! PROGRAM HISTORY LOG:
!! 92-12-24 RUSS TREADON
!! 96-03-04 MIKE BALDWIN - ADD CLOUD WATER AND SPEED UP CODE
!! 98-06-15 T BLACK - CONVERSION FROM 1-D TO 2-D
!! 00-01-04 JIM TUCCILLO - MPI VERSION
!! 02-06-19 MIKE BALDWIN - WRF VERSION
!! 04-12-30 H CHUANG - UPDATE TO CALCULATE TOTAL COLUMN FOR OTHER
!! HYDROMETEORS
!! 14-11-12 SARAH LU - UPDATE TO CALCULATE AEROSOL OPTICAL DEPTH
!! 15-07-02 SARAH LU - UPDATE TO CALCULATE SCATTERING AEROSOL
!! OPTICAL DEPTH (18)
!! 15-07-04 SARAH LU - CORRECT PW INTEGRATION FOR AOD (17)
!! 15-07-10 SARAH LU - UPDATE TO CALCULATE ASYMETRY PARAMETER
!! 19-07-25 Li(Kate) Zhang - MERGE SARHA LU's update for FV3-Chem
!! 20-11-10 JESSE MENG - USE UPP_PHYSICS MODULE
!!
!! USAGE: CALL CALPW(PW)
!! INPUT ARGUMENT LIST:
!! PW - ARRAY OF PRECIPITABLE WATER.
!!
!! OUTPUT ARGUMENT LIST:
!! NONE
!!
!! OUTPUT FILES:
!! NONE
!!
!! SUBPROGRAMS CALLED:
!! UTILITIES:
!! NONE
!! LIBRARY:
!! COMMON - LOOPS
!! MASKS
!!
!! ATTRIBUTES:
!! LANGUAGE: FORTRAN
!! MACHINE : CRAY C-90
!!
!> @brief Subroutine that computes precipitable water.
!>
!><pre>
!> This routine computes precipitable water in a column
!> extending from the first atmospheric ETA layer to the
!> model top. The definition used is
!> TOP
!> precipitable water = sum (Q+CLDW) DP*HTM/G
!> BOT
!> where,
!> BOT is the first ETA layer,
!> TOP is the model top,
!> Q is the specific humidity (kg/kg) in the layer
!> CLDW is the cloud water (kg/kg) in the layer
!> DP (Pa) is the layer thickness.
!> HTM is the height mask at that layer (=0 if below ground)
!> G is the gravitational constant.
!></pre>
!>
!> @param[in] PW Array of precipitable water.
!>
!> ### Program history log:
!> Date | Programmer | Comments
!> -----|------------|---------
!> 1992-12-24 | Russ Treadon | Initial
!> 1996-03-04 | Mike Baldwin | Add cloud water and speed up code
!> 1998-06-15 | T Black | Convesion from 1-D to 2-D
!> 2000-01-04 | Jim Tuccillo | MPI Version
!> 2002-06-19 | Mike Baldwin | WRF Version
!> 2004-12-30 | H Chuang | Update to calculate total column for other hydrometeors
!> 2014-11-12 | Sarah Lu | Update tp calculate aerosol optical depth
!> 2015-07-02 | Sarah Lu | Update to calculate scattering aerosal optical depth (18)
!> 2015-07-04 | Sarah Lu | Correct PW integration for AOD (17)
!> 2015-07-10 | Sarah Lu | Update to calculate asymetry parameter
!> 2019-07-25 | Li(Kate) Zhang | Merge Sarah Lu's update for FV3-Chem
!> 2020-11-10 | Jesse Meng | Use UPP_PHYSICS Module
!>
!> @author Russ Treadon W/NP2 @date 1992-12-24
SUBROUTINE CALPW(PW,IDECID)

!
Expand Down