NCEPLIBS-bufr
11.6.0
|
Go to the source code of this file.
Functions/Subroutines | |
subroutine | ufbin3 (LUNIT, USR, I1, I2, I3, IRET, JRET, STR) |
THIS SUBROUTINE READS SPECIFIED VALUES FROM THE CURRENT BUFR DATA SUBSET WITHIN INTERNAL ARRAYS. More... | |
Definition in file ufbin3.f.
subroutine ufbin3 | ( | LUNIT, | |
real*8, dimension(i1,i2,i3) | USR, | ||
I1, | |||
I2, | |||
I3, | |||
IRET, | |||
JRET, | |||
character*(*) | STR | ||
) |
THIS SUBROUTINE READS SPECIFIED VALUES FROM THE CURRENT BUFR DATA SUBSET WITHIN INTERNAL ARRAYS.
THE DATA VALUES CORRESPOND TO MNEMONICS WHICH ARE PART OF A MULTIPLE-REPLICATION SEQUENCE WITHIN ANOTHER MULTIPLE-REPLICATION SEQUENCE. THE INNER SEQUENCE IS USUALLY ASSOCIATED WITH DATA "LEVELS" AND THE OUTER SEQUENCE WITH DATA "EVENTS". THE BUFR FILE IN LOGICAL UNIT LUNIT MUST HAVE BEEN OPENED FOR INPUT VIA A PREVIOUS CALL TO BUFR ARCHIVE LIBRARY SUBROUTINE OPENBF. IN ADDITION, THE DATA SUBSET MUST HAVE SUBSEQUENTLY BEEN READ INTO THE INTERNAL BUFR ARCHIVE LIBRARY ARRAYS VIA CALLS TO BUFR ARCHIVE LIBRARY SUBROUTINE READMG OR READERME FOLLOWED BY A CALL TO BUFR ARCHIVE LIBRARY SUBROUTINE READSB (OR VIA A SINGLE CALL TO BUFR ARCHIVE LIBRARY SUBROUTINE READNS). THIS SUBROUTINE IS DESIGNED TO READ EVENT INFORMATION FROM "PREPFITS" TYPE BUFR FILES (BUT NOT FROM "PREPBUFR" TYPE FILES!!). PREPFITS FILES HAVE THE FOLLOWING BUFR TABLE EVENT STRUCTURE (NOTE SIXTEEN CHARACTERS HAVE BEEN REMOVED FROM THE LAST COLUMN TO ALLOW THE TABLE TO FIT IN THIS DOCBLOCK):
ADPUPA | HEADR {PLEVL} |
---|---|
HEADR | SID XOB YOB DHR ELV TYP T29 ITP |
PLEVL | CAT PRC PQM QQM TQM ZQM WQM CDTP_QM [OBLVL] |
OBLVL | SRC FHR <PEVN> <QEVN> <TEVN> <ZEVN> <WEVN> <CEVN> |
OBLVL | <CTPEVN> |
PEVN | POB PMO |
QEVN | QOB |
TEVN | TOB |
ZEVN | ZOB |
WEVN | UOB VOB |
CEVN | CAPE CINH LI |
CTPEVN | CDTP GCDTT TOCC |
NOTE THAT THE ONE-BIT DELAYED REPLICATED SEQUENCES "<xxxx>" ARE NESTED INSIDE THE EIGHT-BIT DELAYED REPLIATION EVENT SEQUENCES "[yyyy]". THE ANALOGOUS BUFR ARCHIVE LIBRARY SUBROUTINE UFBEVN DOES NOT WORK PROPERLY ON THIS TYPE OF EVENT STRUCTURE. IT WORKS ONLY ON THE EVENT STRUCTURE FOUND IN "PREPBUFR" TYPE BUFR FILES (SEE UFBEVN FOR MORE DETAILS). IN TURN, UFBIN3 DOES NOT WORK PROPERLY ON THE EVENT STRUCTURE FOUND IN PREPBUFR FILES (ALWAYS USE UFBEVN IN THIS CASE). ONE OTHER DIFFERENCE BETWEEN UFBIN3 AND UFBEVN IS THAT UFBIN3 RETURNS THE MAXIMUM NUMBER OF EVENTS FOUND FOR ALL DATA VALUES SPECIFIED AS AN OUTPUT ARGUMENT (JRET). UFBEVN DOES NOT DO THIS, BUT RATHER IT STORES THIS VALUE INTERNALLY IN COMMON BLOCK /UFBN3C/.
PROGRAM HISTORY LOG: 2003-11-04 J. WOOLLEN – ORIGINAL AUTHOR (WAS IN VERIFICATION VERSION) 2003-11-04 D. KEYSER – UNIFIED/PORTABLE FOR WRF; ADDED DOCUMENTATION; OUTPUTS MORE COMPLETE DIAGNOSTIC INFO WHEN ROUTINE TERMINATES ABNORMALLY OR UNUSUAL THINGS HAPPEN 2009-04-21 J. ATOR – USE ERRWRT 2014-12-10 J. ATOR – USE MODULES INSTEAD OF COMMON BLOCKS
USAGE: CALL UFBIN3 (LUNIT, USR, I1, I2, I3, IRET, JRET, STR) INPUT ARGUMENT LIST: LUNIT - INTEGER: FORTRAN LOGICAL UNIT NUMBER FOR BUFR FILE I1 - INTEGER: LENGTH OF FIRST DIMENSION OF USR (MUST BE AT LEAST AS LARGE AS THE NUMBER OF BLANK-SEPARATED MNEMONICS IN STR) I2 - INTEGER: LENGTH OF SECOND DIMENSION OF USR I3 - INTEGER: LENGTH OF THIRD DIMENSION OF USR (MAXIMUM VALUE IS 255) STR - CHARACTER*(*): STRING OF BLANK-SEPARATED TABLE B MNEMONICS IN ONE-TO-ONE CORRESPONDENCE WITH FIRST DIMENSION OF USR
OUTPUT ARGUMENT LIST: USR - REAL*8: (I1,I2,I3) STARTING ADDRESS OF DATA VALUES READ FROM DATA SUBSET IRET - INTEGER: NUMBER OF "LEVELS" OF DATA VALUES READ FROM DATA SUBSET (MUST BE NO LARGER THAN I2) JRET - INTEGER: MAXIMUM NUMBER OF "EVENTS" FOUND FOR ALL DATA VALUES SPECIFIED AMONGST ALL LEVELS READ FROM DATA SUBSET (MUST BE NO LARGER THAN I3)
REMARKS: IMPORTANT: THIS ROUTINE SHOULD ONLY BE CALLED BY THE VERIFICATION APPLICATION PROGRAM "GRIDTOBS", WHERE IT WAS PREVIOUSLY AN IN-LINE SUBROUTINE. IN GENERAL, UFBIN3 DOES NOT WORK PROPERLY IN OTHER APPLICATION PROGRAMS (I.E, THOSE THAT ARE READING PREPBUFR FILES) AT THIS TIME. ALWAYS USE UFBEVN INSTEAD!!
THIS ROUTINE CALLS: BORT CONWIN ERRWRT GETWIN NEVN NXTWIN STATUS STRING THIS ROUTINE IS CALLED BY: None SHOULD NOT BE CALLED BY ANY APPLICATION PROGRAMS EXCEPT GRIDTOBS!!
Definition at line 105 of file ufbin3.f.
References bort(), conwin(), errwrt(), getwin(), nevn(), nxtwin(), status(), and string().