Skip to content

Commit

Permalink
PDAF: change dim_obs_p to dim_obs in add_obs_error_pdaf (LEnKF) (
Browse files Browse the repository at this point in the history
…#246)

* rename `dim_obs_p` to `dim_obs` in `add_obs_error_pdaf`

Former `dim_obs_p` in `add_obs_error_pdaf` was actually the size of the full observation vector and is therefore better called `dim_obs`.

The suffix `_p` is used in TSMP-PDAF for PE-local variables.
  • Loading branch information
jjokella authored Nov 6, 2024
1 parent 637cfc7 commit 0450e32
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions bldsva/intf_DA/pdaf/framework/add_obs_error_pdaf.F90
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
! !ROUTINE: add_obs_error_pdaf --- Add observation error covariance matrix
!
! !INTERFACE:
SUBROUTINE add_obs_error_pdaf(step, dim_obs_p, C_p)
SUBROUTINE add_obs_error_pdaf(step, dim_obs, C_p)

! !DESCRIPTION:
! User-supplied routine for PDAF.
Expand Down Expand Up @@ -60,8 +60,8 @@ SUBROUTINE add_obs_error_pdaf(step, dim_obs_p, C_p)

! !ARGUMENTS:
INTEGER, INTENT(in) :: step ! Current time step
INTEGER, INTENT(in) :: dim_obs_p ! Dimension of observation vector
REAL, INTENT(inout) :: C_p(dim_obs_p,dim_obs_p) ! Matrix to that
INTEGER, INTENT(in) :: dim_obs ! Dimension of observation vector
REAL, INTENT(inout) :: C_p(dim_obs,dim_obs) ! Matrix to that
! observation covariance R is added

! !CALLING SEQUENCE:
Expand Down Expand Up @@ -90,7 +90,7 @@ SUBROUTINE add_obs_error_pdaf(step, dim_obs_p, C_p)
! *************************************

if(multierr.ne.1) then
DO i = 1, dim_obs_p
DO i = 1, dim_obs
C_p(i, i) = C_p(i, i) + variance_obs
ENDDO
endif
Expand All @@ -104,7 +104,7 @@ SUBROUTINE add_obs_error_pdaf(step, dim_obs_p, C_p)
call abort_parallel()
end if

do i=1,dim_obs_p
do i=1,dim_obs
#if defined CLMSA
C_p(i,i) = C_p(i,i) + clm_obserr(obs_nc2pdaf(i))*clm_obserr(obs_nc2pdaf(i))
#else
Expand Down

0 comments on commit 0450e32

Please sign in to comment.