20 use modv_vars,
only: maxcd, maxjl, maxmem, maxmsg, maxss, maxtba, maxtbb, maxtbd, mxbtm, mxbtmse, &
21 mxcdv, mxcsb, mxdxts, mxlcc, mxmsgl, mxmsgld4, mxmtbb, mxmtbd, mxnrv, mxrst, &
22 mxs01v, mxtamc, mxtco, mxh4wlc, nfiles, mxcnem, maxnc, maxrcr, iprt
69 call errwrt (
'++++++++++++++BUFR ARCHIVE LIBRARY+++++++++++++++++')
70 call errwrt (
'BUFRLIB: ARRAYS WILL BE DYNAMICALLY ALLOCATED USING THE FOLLOWING VALUES:')
71 write ( errstr,
'(a,i7)' )
' MAXSS = ', maxss
73 write ( errstr,
'(a,i4)' )
' NFILES = ', nfiles
75 write ( errstr,
'(a,i7)' )
' MXMSGL = ', mxmsgl
77 write ( errstr,
'(a,i5)' )
' MXDXTS = ', mxdxts
79 write ( errstr,
'(a,i7)' )
' MAXMSG = ', maxmsg
81 write ( errstr,
'(a,i9)' )
' MAXMEM = ', maxmem
83 write ( errstr,
'(a,i5)' )
' MAXTBA = ', maxtba
85 write ( errstr,
'(a,i5)' )
' MAXTBB = ', maxtbb
87 write ( errstr,
'(a,i5)' )
' MAXTBD = ', maxtbd
89 write ( errstr,
'(a,i7)' )
' MAXJL = ', maxjl
91 write ( errstr,
'(a,i6)' )
' MXCDV = ', mxcdv
93 write ( errstr,
'(a,i4)' )
' MXLCC = ', mxlcc
95 write ( errstr,
'(a,i6)' )
' MXCSB = ', mxcsb
97 write ( errstr,
'(a,i5)' )
' MXMTBB = ', mxmtbb
99 write ( errstr,
'(a,i5)' )
' MXMTBD = ', mxmtbd
101 write ( errstr,
'(a,i4)' )
' MAXCD = ', maxcd
103 write ( errstr,
'(a,i4)' )
' MXNRV = ', mxnrv
105 write ( errstr,
'(a,i4)' )
' MXS01V = ', mxs01v
107 write ( errstr,
'(a,i4)' )
' MXTAMC = ', mxtamc
109 write ( errstr,
'(a,i4)' )
' MXTCO = ', mxtco
111 write ( errstr,
'(a,i4)' )
' MXBTM = ', mxbtm
113 write ( errstr,
'(a,i4)' )
' MXBTMSE = ', mxbtmse
115 write ( errstr,
'(a,i4)' )
' MXH4WLC = ', mxh4wlc
117 write ( errstr,
'(a,i4)' )
' MXRST = ', mxrst
119 write ( errstr,
'(a,i4)' )
' MXCNEM = ', mxcnem
121 write ( errstr,
'(a,i4)' )
' MAXNC = ', maxnc
123 call errwrt (
'++++++++++++++BUFR ARCHIVE LIBRARY+++++++++++++++++')
126 brtstr =
'BUFRLIB: ARALLOCF FAILED ALLOCATING '
130 allocate(
nval(nfiles), stat=iost )
131 if ( iost /= 0 )
call bort( brtstr //
'NVAL' )
133 allocate(
inv(maxss,nfiles), stat=iost )
134 if ( iost /= 0 )
call bort( brtstr //
'INV' )
136 allocate(
nrfelm(maxss,nfiles), stat=iost )
137 if ( iost /= 0 )
call bort( brtstr //
'NRFELM' )
139 allocate(
val(maxss,nfiles), stat=iost )
140 if ( iost /= 0 )
call bort( brtstr //
'VAL' )
144 allocate(
nbit(maxss), stat=iost )
145 if ( iost /= 0 )
call bort( brtstr //
'NBIT' )
147 allocate(
mbit(maxss), stat=iost )
148 if ( iost /= 0 )
call bort( brtstr //
'MBIT' )
152 allocate(
ival(maxss), stat=iost )
153 if ( iost /= 0 )
call bort( brtstr //
'IVAL' )
157 allocate(
nmsg(nfiles), stat=iost )
158 if ( iost /= 0 )
call bort( brtstr //
'NMSG' )
160 allocate(
nsub(nfiles), stat=iost )
161 if ( iost /= 0 )
call bort( brtstr //
'NSUB' )
163 allocate(
msub(nfiles), stat=iost )
164 if ( iost /= 0 )
call bort( brtstr //
'MSUB' )
166 allocate(
inode(nfiles), stat=iost )
167 if ( iost /= 0 )
call bort( brtstr //
'INODE' )
169 allocate(
idate(nfiles), stat=iost )
170 if ( iost /= 0 )
call bort( brtstr //
'IDATE' )
174 allocate(
iolun(nfiles), stat=iost )
175 if ( iost /= 0 )
call bort( brtstr //
'IOLUN' )
177 allocate(
iomsg(nfiles), stat=iost )
178 if ( iost /= 0 )
call bort( brtstr //
'IOMSG' )
182 allocate(
luncpy(nfiles), stat=iost )
183 if ( iost /= 0 )
call bort( brtstr //
'LUNCPY' )
187 allocate(
isc3(nfiles), stat=iost )
188 if ( iost /= 0 )
call bort( brtstr //
'ISC3' )
190 allocate(
tamnem(nfiles), stat=iost )
191 if ( iost /= 0 )
call bort( brtstr //
'TAMNEM' )
195 allocate(
msgunp(nfiles), stat=iost )
196 if ( iost /= 0 )
call bort( brtstr //
'MSGUNP' )
200 allocate(
lus(nfiles), stat=iost )
201 if ( iost /= 0 )
call bort( brtstr //
'LUS' )
205 allocate(
null(nfiles), stat=iost )
206 if ( iost /= 0 )
call bort( brtstr //
'NULL' )
210 allocate(
iscodes(nfiles), stat=iost )
211 if ( iost /= 0 )
call bort( brtstr //
'ISCODES' )
215 allocate(
idrdm(nfiles), stat=iost )
216 if ( iost /= 0 )
call bort( brtstr //
'IDRDM' )
220 allocate(
xtab(nfiles), stat=iost )
221 if ( iost /= 0 )
call bort( brtstr //
'XTAB' )
225 allocate(
msglim(nfiles), stat=iost )
226 if ( iost /= 0 )
call bort( brtstr //
'MSGLIM' )
230 if ( mod(mxmsgl,4) == 0 )
then
233 mxmsgld4 = mxmsgl/4 + 1
238 allocate(
ibay(mxmsgld4), stat=iost )
239 if ( iost /= 0 )
call bort( brtstr //
'IBAY' )
241 allocate(
mbyt(nfiles), stat=iost )
242 if ( iost /= 0 )
call bort( brtstr //
'MBYT' )
244 allocate(
mbay(mxmsgld4,nfiles), stat=iost )
245 if ( iost /= 0 )
call bort( brtstr //
'MBAY' )
249 allocate(
mgwa(mxmsgld4), stat=iost )
250 if ( iost /= 0 )
call bort( brtstr //
'MGWA' )
254 allocate(
mgwb(mxmsgld4), stat=iost )
255 if ( iost /= 0 )
call bort( brtstr //
'MGWB' )
259 allocate(
msglen(nfiles), stat=iost )
260 if ( iost /= 0 )
call bort( brtstr //
'MSGLEN' )
261 allocate(
msgtxt(mxmsgld4,nfiles), stat=iost )
262 if ( iost /= 0 )
call bort( brtstr //
'MSGTXT' )
266 allocate(
jsr(nfiles), stat=iost )
267 if ( iost /= 0 )
call bort( brtstr //
'JSR' )
269 allocate(
jbay(mxmsgld4), stat=iost )
270 if ( iost /= 0 )
call bort( brtstr //
'JBAY' )
279 allocate(
msgp(0:maxmsg), stat=iost )
280 if ( iost /= 0 )
call bort( brtstr //
'MSGP' )
282 allocate(
msgs(maxmem), stat=iost )
283 if ( iost /= 0 )
call bort( brtstr //
'MSGS' )
286 if ( iost /= 0 )
call bort( brtstr //
'MDX' )
289 if ( iost /= 0 )
call bort( brtstr //
'IPDXM' )
291 allocate(
ifdxts(mxdxts), stat=iost )
292 if ( iost /= 0 )
call bort( brtstr //
'ifDXTS' )
294 allocate(
icdxts(mxdxts), stat=iost )
295 if ( iost /= 0 )
call bort( brtstr //
'ICDXTS' )
297 allocate(
ipmsgs(mxdxts), stat=iost )
298 if ( iost /= 0 )
call bort( brtstr //
'IPMSGS' )
302 allocate(
ntba(0:nfiles), stat=iost )
303 if ( iost /= 0 )
call bort( brtstr //
'NTBA' )
305 allocate(
ntbb(0:nfiles), stat=iost )
306 if ( iost /= 0 )
call bort( brtstr //
'NTBB' )
308 allocate(
ntbd(0:nfiles), stat=iost )
309 if ( iost /= 0 )
call bort( brtstr //
'NTBD' )
311 allocate(
mtab(maxtba,nfiles), stat=iost )
312 if ( iost /= 0 )
call bort( brtstr //
'MTAB' )
314 allocate(
idna(maxtba,nfiles,2), stat=iost )
315 if ( iost /= 0 )
call bort( brtstr //
'IDNA' )
317 allocate(
idnb(maxtbb,nfiles), stat=iost )
318 if ( iost /= 0 )
call bort( brtstr //
'IDNB' )
320 allocate(
idnd(maxtbd,nfiles), stat=iost )
321 if ( iost /= 0 )
call bort( brtstr //
'IDND' )
323 allocate(
taba(maxtba,nfiles), stat=iost )
324 if ( iost /= 0 )
call bort( brtstr //
'TABA' )
326 allocate(
tabb(maxtbb,nfiles), stat=iost )
327 if ( iost /= 0 )
call bort( brtstr //
'TABB' )
329 allocate(
tabd(maxtbd,nfiles), stat=iost )
330 if ( iost /= 0 )
call bort( brtstr //
'TABD' )
334 allocate(
tag(maxjl), stat=iost )
335 if ( iost /= 0 )
call bort( brtstr //
'TAG' )
337 allocate(
typ(maxjl), stat=iost )
338 if ( iost /= 0 )
call bort( brtstr //
'TYP' )
340 allocate(
knt(maxjl), stat=iost )
341 if ( iost /= 0 )
call bort( brtstr //
'KNT' )
343 allocate(
jump(maxjl), stat=iost )
344 if ( iost /= 0 )
call bort( brtstr //
'JUMP' )
346 allocate(
link(maxjl), stat=iost )
347 if ( iost /= 0 )
call bort( brtstr //
'LINK' )
349 allocate(
jmpb(maxjl), stat=iost )
350 if ( iost /= 0 )
call bort( brtstr //
'JMPB' )
352 allocate(
ibt(maxjl), stat=iost )
353 if ( iost /= 0 )
call bort( brtstr //
'IBT' )
355 allocate(
irf(maxjl), stat=iost )
356 if ( iost /= 0 )
call bort( brtstr //
'IRF' )
358 allocate(
isc(maxjl), stat=iost )
359 if ( iost /= 0 )
call bort( brtstr //
'ISC' )
361 allocate(
itp(maxjl), stat=iost )
362 if ( iost /= 0 )
call bort( brtstr //
'ITP' )
364 allocate(
vali(maxjl), stat=iost )
365 if ( iost /= 0 )
call bort( brtstr //
'VALI' )
367 allocate(
knti(maxjl), stat=iost )
368 if ( iost /= 0 )
call bort( brtstr //
'KNTI' )
370 allocate(
iseq(maxjl,2), stat=iost )
371 if ( iost /= 0 )
call bort( brtstr //
'ISEQ' )
373 allocate(
jseq(maxjl), stat=iost )
374 if ( iost /= 0 )
call bort( brtstr //
'JSEQ' )
378 allocate(
iutmp(maxjl,maxrcr), stat=iost )
379 if ( iost /= 0 )
call bort( brtstr //
'IUTMP' )
381 allocate(
vutmp(maxjl,maxrcr), stat=iost )
382 if ( iost /= 0 )
call bort( brtstr //
'VUTMP' )
386 allocate(
ttmp(maxjl), stat=iost )
387 if ( iost /= 0 )
call bort( brtstr //
'TTMP' )
389 allocate(
itmp(maxjl), stat=iost )
390 if ( iost /= 0 )
call bort( brtstr //
'ITMP' )
392 allocate(
vtmp(maxjl), stat=iost )
393 if ( iost /= 0 )
call bort( brtstr //
'VTMP' )
397 allocate(
kmin(mxcdv), stat=iost )
398 if ( iost /= 0 )
call bort( brtstr //
'KMIN' )
400 allocate(
kmax(mxcdv), stat=iost )
401 if ( iost /= 0 )
call bort( brtstr //
'KMAX' )
403 allocate(
kmis(mxcdv), stat=iost )
404 if ( iost /= 0 )
call bort( brtstr //
'KMIS' )
406 allocate(
kbit(mxcdv), stat=iost )
407 if ( iost /= 0 )
call bort( brtstr //
'KBIT' )
409 allocate(
ityp(mxcdv), stat=iost )
410 if ( iost /= 0 )
call bort( brtstr //
'ITYP' )
412 allocate(
iwid(mxcdv), stat=iost )
413 if ( iost /= 0 )
call bort( brtstr //
'IWID' )
415 allocate(
character*(mxlcc) :: cstr(mxcdv), stat=iost )
416 if ( iost /= 0 )
call bort( brtstr //
'CSTR' )
418 allocate(
jlnode(mxcdv), stat=iost )
419 if ( iost /= 0 )
call bort( brtstr //
'JLNODE' )
423 allocate(
matx(mxcdv,mxcsb), stat=iost )
424 if ( iost /= 0 )
call bort( brtstr //
'MATX' )
426 allocate(
character*(mxlcc) :: catx(mxcdv,mxcsb), stat=iost )
427 if ( iost /= 0 )
call bort( brtstr //
'CATX' )
431 allocate(
ibfxyn(mxmtbb), stat=iost )
432 if ( iost /= 0 )
call bort( brtstr //
'IBFXYN' )
434 allocate(
cbscl(4,mxmtbb), stat=iost )
435 if ( iost /= 0 )
call bort( brtstr //
'CBSCL' )
437 allocate(
cbsref(12,mxmtbb), stat=iost )
438 if ( iost /= 0 )
call bort( brtstr //
'CBSREF' )
440 allocate(
cbbw(4,mxmtbb), stat=iost )
441 if ( iost /= 0 )
call bort( brtstr //
'CBBW' )
443 allocate(
cbunit(24,mxmtbb), stat=iost )
444 if ( iost /= 0 )
call bort( brtstr //
'CBUNIT' )
446 allocate(
cbmnem(8,mxmtbb), stat=iost )
447 if ( iost /= 0 )
call bort( brtstr //
'CBMNEM' )
449 allocate(
cbelem(120,mxmtbb), stat=iost )
450 if ( iost /= 0 )
call bort( brtstr //
'CBELEM' )
452 allocate(
idfxyn(mxmtbd), stat=iost )
453 if ( iost /= 0 )
call bort( brtstr //
'IDFXYN' )
455 allocate(
cdseq(120,mxmtbd), stat=iost )
456 if ( iost /= 0 )
call bort( brtstr //
'CDSEQ' )
458 allocate(
cdmnem(8,mxmtbd), stat=iost )
459 if ( iost /= 0 )
call bort( brtstr //
'CDMNEM' )
461 allocate(
ndelem(mxmtbd), stat=iost )
462 if ( iost /= 0 )
call bort( brtstr //
'NDELEM' )
464 allocate(
idefxy(mxmtbd*maxcd), stat=iost )
465 if ( iost /= 0 )
call bort( brtstr //
'IDEFXY' )
469 allocate(
iefxyn(mxmtbd,maxcd), stat=iost )
470 if ( iost /= 0 )
call bort( brtstr //
'IEFXYN' )
472 allocate(
cmdscb(mxmtbb), stat=iost )
473 if ( iost /= 0 )
call bort( brtstr //
'CMDSCB' )
475 allocate(
cmdscd(mxmtbd), stat=iost )
476 if ( iost /= 0 )
call bort( brtstr //
'CMDSCD' )
478 allocate(
ceelem(mxmtbd,maxcd), stat=iost )
479 if ( iost /= 0 )
call bort( brtstr //
'CEELEM' )
483 allocate(
nem(maxcd,10), stat=iost )
484 if ( iost /= 0 )
call bort( brtstr //
'NEM' )
486 allocate(
irp(maxcd,10), stat=iost )
487 if ( iost /= 0 )
call bort( brtstr //
'IRP' )
489 allocate(
krp(maxcd,10), stat=iost )
490 if ( iost /= 0 )
call bort( brtstr //
'KRP' )
494 allocate(
ivmnem(mxs01v), stat=iost )
495 if ( iost /= 0 )
call bort( brtstr //
'IVMNEM' )
497 allocate(
cmnem(mxs01v), stat=iost )
498 if ( iost /= 0 )
call bort( brtstr //
'CMNEM' )
502 allocate(
inodtamc(mxtamc), stat=iost )
503 if ( iost /= 0 )
call bort( brtstr //
'INODTAMC' )
505 allocate(
ntco(mxtamc), stat=iost )
506 if ( iost /= 0 )
call bort( brtstr //
'NTCO' )
508 allocate(
ctco(mxtamc,mxtco), stat=iost )
509 if ( iost /= 0 )
call bort( brtstr //
'CTCO' )
511 allocate(
inodtco(mxtamc,mxtco), stat=iost )
512 if ( iost /= 0 )
call bort( brtstr //
'INODTCO' )
514 allocate(
nbtmse(mxbtm), stat=iost )
515 if ( iost /= 0 )
call bort( brtstr //
'NBTMSE' )
517 allocate(
istbtm(mxbtm), stat=iost )
518 if ( iost /= 0 )
call bort( brtstr //
'ISTBTM' )
520 allocate(
iszbtm(mxbtm), stat=iost )
521 if ( iost /= 0 )
call bort( brtstr //
'ISZBTM' )
523 allocate(
ibtmse(mxbtm,mxbtmse), stat=iost )
524 if ( iost /= 0 )
call bort( brtstr //
'IBTMSE' )
528 allocate(
tagnrv(mxnrv), stat=iost )
529 if ( iost /= 0 )
call bort( brtstr //
'TAGNRV' )
531 allocate(
inodnrv(mxnrv), stat=iost )
532 if ( iost /= 0 )
call bort( brtstr //
'INODNRV' )
534 allocate(
nrv(mxnrv), stat=iost )
535 if ( iost /= 0 )
call bort( brtstr //
'NRV' )
537 allocate(
isnrv(mxnrv), stat=iost )
538 if ( iost /= 0 )
call bort( brtstr //
'ISNRV' )
540 allocate(
ienrv(mxnrv), stat=iost )
541 if ( iost /= 0 )
call bort( brtstr //
'IENRV' )
545 allocate(
irnch(mxrst), stat=iost )
546 if ( iost /= 0 )
call bort( brtstr //
'IRNCH' )
548 allocate(
irbit(mxrst), stat=iost )
549 if ( iost /= 0 )
call bort( brtstr //
'IRBIT' )
551 allocate(
crtag(mxrst), stat=iost )
552 if ( iost /= 0 )
call bort( brtstr //
'CRTAG' )
556 allocate(
luh4wlc(mxh4wlc), stat=iost )
557 if ( iost /= 0 )
call bort( brtstr //
'LUH4WLC' )
559 allocate(
sth4wlc(mxh4wlc), stat=iost )
560 if ( iost /= 0 )
call bort( brtstr //
'STH4WLC' )
562 allocate(
chh4wlc(mxh4wlc), stat=iost )
563 if ( iost /= 0 )
call bort( brtstr //
'CHH4WLC' )
567 allocate(
cnem(mxcnem), stat=iost )
568 if ( iost /= 0 )
call bort( brtstr //
'CNEM' )
570 allocate(
ndc(mxcnem), stat=iost )
571 if ( iost /= 0 )
call bort( brtstr //
'NDC' )
573 allocate(
idcach(mxcnem,maxnc), stat=iost )
574 if ( iost /= 0 )
call bort( brtstr //
'IDCACH' )
578 allocate(
ids3(maxnc), stat=iost )
579 if ( iost /= 0 )
call bort( brtstr //
'IDS3' )
581 allocate(
cds3(maxnc), stat=iost )
582 if ( iost /= 0 )
call bort( brtstr //
'CDS3' )
902 use modv_vars,
only: ifopbf, nfiles
974 recursive integer function isetprm ( cprmnm, ipval )
result ( iret )
976 use modv_vars,
only: mxmsgl, maxss, nfiles, mxdxts, maxmsg, maxmem, maxtba, maxtbb, maxtbd, maxjl, &
977 mxcdv, mxlcc, mxcsb, mxmtbb, mxmtbd, mxmtbf, maxcd, mxs01v, mxbtm, mxbtmse, &
978 mxtamc, mxtco, mxnrv, mxrst, mxh4wlc, im8b, mxcnem, maxnc, mxnaf
982 character*(*),
intent(in) :: cprmnm
984 integer,
intent(in) :: ipval
995 call x84 ( ipval, my_ipval, 1 )
996 iret =
isetprm( cprmnm, my_ipval )
1003 if ( cprmnm ==
'MAXSS' )
then
1005 else if ( cprmnm ==
'NFILES' )
then
1007 else if ( cprmnm ==
'MXMSGL' )
then
1009 else if ( cprmnm ==
'MXDXTS' )
then
1011 else if ( cprmnm ==
'MAXMSG' )
then
1013 else if ( cprmnm ==
'MAXMEM' )
then
1015 else if ( cprmnm ==
'MAXTBA' )
then
1017 else if ( cprmnm ==
'MAXTBB' )
then
1019 else if ( cprmnm ==
'MAXTBD' )
then
1021 else if ( cprmnm ==
'MAXJL' )
then
1023 else if ( cprmnm ==
'MXCDV' )
then
1025 else if ( cprmnm ==
'MXLCC' )
then
1027 else if ( cprmnm ==
'MXCSB' )
then
1029 else if ( cprmnm ==
'MXMTBB' )
then
1031 else if ( cprmnm ==
'MXMTBD' )
then
1033 else if ( cprmnm ==
'MXMTBF' )
then
1035 else if ( cprmnm ==
'MAXCD' )
then
1037 else if ( cprmnm ==
'MXS01V' )
then
1039 else if ( cprmnm ==
'MXBTM' )
then
1041 else if ( cprmnm ==
'MXBTMSE' )
then
1043 else if ( cprmnm ==
'MXTAMC' )
then
1045 else if ( cprmnm ==
'MXTCO' )
then
1047 else if ( cprmnm ==
'MXNRV' )
then
1049 else if ( cprmnm ==
'MXRST' )
then
1051 else if ( cprmnm ==
'MXH4WLC' )
then
1053 else if ( cprmnm ==
'MXCNEM' )
then
1055 else if ( cprmnm ==
'MAXNC' )
then
1057 else if ( cprmnm ==
'MXNAF' )
then
1061 call errwrt(
'++++++++++++++++++WARNING+++++++++++++++++++')
1062 errstr =
'BUFRLIB: ISETPRM - UNKNOWN INPUT PARAMETER '// cprmnm //
' -- NO ACTION WAS TAKEN'
1064 call errwrt(
'++++++++++++++++++WARNING+++++++++++++++++++')
1108 integer function igetprm ( cprmnm )
result ( iret )
1110 use modv_vars,
only: mxmsgl, maxss, nfiles, mxdxts, maxmsg, maxmem, maxtba, maxtbb, maxtbd, maxjl, &
1111 mxcdv, mxlcc, mxcsb, mxmtbb, mxmtbd, mxmtbf, maxcd, mxs01v, mxbtm, mxbtmse, &
1112 mxtamc, mxtco, mxnrv, mxrst, mxh4wlc, mxcnem, maxnc, mxnaf
1116 character*(*),
intent(in) :: cprmnm
1120 if ( cprmnm ==
'MAXSS' )
then
1122 else if ( cprmnm ==
'NFILES' )
then
1124 else if ( cprmnm ==
'MXMSGL' )
then
1126 else if ( cprmnm ==
'MXDXTS' )
then
1128 else if ( cprmnm ==
'MAXMSG' )
then
1130 else if ( cprmnm ==
'MAXMEM' )
then
1132 else if ( cprmnm ==
'MAXTBA' )
then
1134 else if ( cprmnm ==
'MAXTBB' )
then
1136 else if ( cprmnm ==
'MAXTBD' )
then
1138 else if ( cprmnm ==
'MAXJL' )
then
1140 else if ( cprmnm ==
'MXCDV' )
then
1142 else if ( cprmnm ==
'MXLCC' )
then
1144 else if ( cprmnm ==
'MXCSB' )
then
1146 else if ( cprmnm ==
'MXMTBB' )
then
1148 else if ( cprmnm ==
'MXMTBD' )
then
1150 else if ( cprmnm ==
'MXMTBF' )
then
1152 else if ( cprmnm ==
'MAXCD' )
then
1154 else if ( cprmnm ==
'MXS01V' )
then
1156 else if ( cprmnm ==
'MXBTM' )
then
1158 else if ( cprmnm ==
'MXBTMSE' )
then
1160 else if ( cprmnm ==
'MXTAMC' )
then
1162 else if ( cprmnm ==
'MXTCO' )
then
1164 else if ( cprmnm ==
'MXNRV' )
then
1166 else if ( cprmnm ==
'MXRST' )
then
1168 else if ( cprmnm ==
'MXH4WLC' )
then
1170 else if ( cprmnm ==
'MXCNEM' )
then
1172 else if ( cprmnm ==
'MAXNC' )
then
1174 else if ( cprmnm ==
'MXNAF' )
then
1178 call errwrt(
'++++++++++++++++++WARNING+++++++++++++++++++')
1179 errstr =
'BUFRLIB: IGETPRM - UNKNOWN INPUT PARAMETER '// cprmnm
1181 call errwrt(
'++++++++++++++++++WARNING+++++++++++++++++++')
integer function igetprm(cprmnm)
Return the current value of a parameter used for allocating one or more internal arrays within the NC...
subroutine arallocf
Dynamically allocate Fortran language arrays.
subroutine exitbufr
Free all dynamically-allocated memory, close all logical units that are open within the NCEPLIBS-bufr...
recursive integer function isetprm(cprmnm, ipval)
Set a specified parameter to a specified value for use in dynamically allocating one or more internal...
subroutine ardllocf
Free all memory that was dynamically allocated during a previous call to subroutine arallocf().
subroutine bort(str)
Log an error message, then abort the application program.
subroutine errwrt(str)
Specify a custom location for the logging of error and diagnostic messages generated by the NCEPLIBS-...
Wrap C NCEPLIBS-bufr functions so they can be called from within the Fortran part of the library.
Declare arrays and variables used to store BUFR messages internally for multiple file IDs.
integer, dimension(:), allocatable ibay
Current data subset.
integer, dimension(:,:), allocatable mbay
Current BUFR message for each file ID.
integer, dimension(:), allocatable mbyt
Length (in bytes) of current BUFR message for each file ID.
Declare arrays and variables used to store bitmaps internally within a data subset definition.
integer, dimension(:), allocatable iszbtm
Size of bitmap (total number of entries, whether "set" (set to a value of 0) or not).
integer, dimension(:,:), allocatable inodtco
Entries within jump/link table which contain Table C operators.
integer, dimension(:), allocatable istbtm
Ordinal position in data subset definition corresponding to the first entry of the bitmap.
integer, dimension(:), allocatable inodtamc
Entries within jump/link table which contain Table A mnemonics.
integer, dimension(:,:), allocatable ibtmse
Ordinal positions in bitmap of bits that were "set" (set to a value of 0); these ordinal positions ca...
integer, dimension(:), allocatable nbtmse
Number of "set" entries (set to a value of 0) in the bitmap.
character *6, dimension(:,:), allocatable ctco
Table C operators corresponding to inodtco.
integer, dimension(:), allocatable ntco
Number of Table C operators (with an XX value of 21 or greater) within the data subset definition of ...
Declare arrays used to store, for each output file ID, a copy of the BUFR message that was most recen...
integer, dimension(:), allocatable msglen
Length (in integers) of BUFR message most recently written to each output file ID.
integer, dimension(:,:), allocatable msgtxt
BUFR message most recently written to each output file ID.
Declare arrays and variables needed to store the current position within a BUFR file.
integer, dimension(:), allocatable jsr
Indicator of stack status when entering subroutine rewnbf().
integer, dimension(:), allocatable jbay
BUFR message.
Declare arrays and variables needed for the storage of data values needed when writing compressed dat...
character *(:), dimension(:,:), allocatable catx
Character data values for all data subsets in message.
integer *8, dimension(:,:), allocatable matx
Non-character data values for all data subsets in message.
Declare arrays and variable needed for the storage of data values needed when writing compressed data...
character *(:), dimension(:), allocatable cstr
Character data value, if corresponding ityp value is set to 3.
integer *8, dimension(:), allocatable kmax
Maximum of each data value across all data subsets in message.
integer, dimension(:), allocatable jlnode
Jump/link table node corresponding to each data value.
integer, dimension(:), allocatable ityp
Type of each data value:
integer, dimension(:), allocatable iwid
Bit width of underlying data descriptor as defined within Table B for each data value.
integer, dimension(:), allocatable kbit
Number of bits needed to hold the increments for this data value within each data subset of the messa...
logical, dimension(:), allocatable kmis
"Missing" values flag.
integer *8, dimension(:), allocatable kmin
Minimum of each data value across all data subsets in message.
Declare arrays and variables for the internal Table A mnemonic cache that is used for Section 3 decod...
character *8, dimension(:), allocatable cnem
Table A mnemonics.
integer, dimension(:,:), allocatable idcach
WMO bit-wise representations of the child descriptors for the corresponding Table A mnemonic in cnem.
integer, dimension(:), allocatable ndc
Number of child descriptors for the corresponding Table A mnemonic in cnem.
Declare arrays and variables needed to store long character strings (greater than 8 bytes) via subrou...
character *14, dimension(:), allocatable sth4wlc
Table B mnemonics associated with long character strings.
integer, dimension(:), allocatable luh4wlc
File ID for associated output file.
character *120, dimension(:), allocatable chh4wlc
Long character strings.
Declare an array used by subroutine readerme() to read in a new DX dictionary table as a consecutive ...
integer, dimension(:), allocatable idrdm
DX BUFR tables message count for each file ID.
Declare an array used to pack or unpack all of the values of a BUFR data subset.
integer *8, dimension(:), allocatable ival
BUFR data subset values.
Declare arrays which provide working space in several subprograms (usrtpl() and ufbcup()) which manip...
character *10, dimension(:), allocatable ttmp
tag array elements for new sections of a growing subset buffer.
real *8, dimension(:), allocatable vtmp
val array elements for new sections of a growing subset buffer.
integer, dimension(:), allocatable itmp
inv array elements for new sections of a growing subset buffer.
Declare an array used by subroutine makestab() to keep track of which logical units share DX BUFR tab...
integer, dimension(:), allocatable lus
Tracking index for each file ID.
Declare an array used by various subroutines and functions to hold a temporary working copy of a BUFR...
integer, dimension(:), allocatable mgwa
Temporary working copy of BUFR message.
Declare an array used by various subroutines and functions to hold a temporary working copy of a BUFR...
integer, dimension(:), allocatable mgwb
Temporary working copy of BUFR message.
Declare arrays used to store information about the current BUFR message that is in the process of bei...
integer, dimension(:), allocatable inode
Table A mnemonic for type of BUFR message.
integer, dimension(:), allocatable idate
Section 1 date-time of message.
integer, dimension(:), allocatable nmsg
Current message pointer within logical unit.
integer, dimension(:), allocatable msub
Total number of data subsets in message.
integer, dimension(:), allocatable nsub
Current subset pointer within message.
Declare an array used to keep track of which logical units should not have any empty (zero data subse...
integer, dimension(:), allocatable msglim
Tracking index for each file ID.
Declare arrays and variables used to store the contents of one or more BUFR files within internal mem...
integer, dimension(:), allocatable msgp
Pointers to the beginning of each message within msgs (up to a maximum of maxmsg, and where array ele...
integer, dimension(:), allocatable ipmsgs
Pointers to first message within msgs for which each DX BUFR table applies.
integer, dimension(:), allocatable msgs
BUFR messages read from one or more BUFR files.
integer, dimension(:), allocatable icdxts
Number of consecutive messages within mdx which constitute each DX BUFR table, beginning with the cor...
integer mxdxm
Maximum number of DX BUFR table messages that can be stored within mdx.
integer, dimension(:), allocatable ifdxts
Pointers to the beginning of each DX BUFR table within mdx.
integer, dimension(:), allocatable mdx
DX BUFR table messages read from one or more BUFR files, for use in decoding the messages in msgs.
integer mxdxw
Maximum number of entries that can be stored within mdx.
integer, dimension(:), allocatable ipdxm
Pointers to the beginning of each message within mdx.
Declare arrays and variables used to store master Table B and Table D entries within internal memory.
integer, dimension(:), allocatable idfxyn
WMO bit-wise representations of FXY numbers for master Table D.
character, dimension(:,:), allocatable cbunit
Units corresponding to ibfxyn.
character, dimension(:,:), allocatable cbbw
Bit widths corresponding to ibfxyn.
character, dimension(:,:), allocatable cdseq
Sequence names corresponding to idfxyn.
character, dimension(:,:), allocatable cbmnem
Mnemonics corresponding to ibfxyn.
integer, dimension(:), allocatable ndelem
Numbers of child descriptors corresponding to idfxyn.
character, dimension(:,:), allocatable cbelem
Element names corresponding to ibfxyn.
character, dimension(:,:), allocatable cbscl
Scale factors corresponding to ibfxyn.
character, dimension(:,:), allocatable cdmnem
Mnemonics corresponding to idfxyn.
character, dimension(:,:), allocatable cbsref
Reference values corresponding to ibfxyn.
integer, dimension(:), allocatable idefxy
WMO bit-wise representations of child descriptors corresponding to idfxyn.
integer, dimension(:), allocatable ibfxyn
WMO bit-wise representations of FXY numbers for master Table B.
Declare arrays used by various subroutines to hold information about Table D sequences.
integer, dimension(:,:), allocatable krp
Replication counts corresponding to nem:
integer, dimension(:,:), allocatable irp
Replication indicators corresponding to nem:
character *8, dimension(:,:), allocatable nem
Child mnemonics within Table D sequences.
Declare arrays and variables for use with any 2-03-YYY (change reference value) operators present wit...
integer, dimension(:), allocatable ienrv
End of entry range in jump/link table, within which the corresponding new reference value in nrv will...
character *8, dimension(:), allocatable tagnrv
Table B mnemonic to which the corresponding new reference value in nrv applies.
integer, dimension(:), allocatable isnrv
Start of entry range in jump/link table, within which the corresponding new reference value in nrv wi...
integer *8, dimension(:), allocatable nrv
New reference values corresponding to inodnrv.
integer, dimension(:), allocatable inodnrv
Entries within jump/link table which contain new reference values.
Declare an array used to store a switch for each file ID, indicating whether any BUFR messages should...
integer, dimension(:), allocatable null
Output switch for each file ID:
Declare arrays and variables used to store master Table B and Table D entries within internal memory.
character *120, dimension(:,:), allocatable ceelem
Element names corresponding to iefxyn.
character *4, dimension(:), allocatable cmdscb
Descriptor codes for Table B elements.
integer, dimension(:,:), allocatable iefxyn
WMO bit-wise representations of child descriptors of Table D sequences.
character *4, dimension(:), allocatable cmdscd
Descriptor codes for Table D sequences.
Declare arrays and variables needed to store information about long character strings (greater than 8...
integer, dimension(:), allocatable irnch
Lengths (in bytes) of long character strings.
integer, dimension(:), allocatable irbit
Pointers in data subset to first bits of long character strings.
character *10, dimension(:), allocatable crtag
Table B mnemonics associated with long character strings.
Declare arrays and variables used to store custom values for certain mnemonics within Sections 0 and ...
integer, dimension(:), allocatable ivmnem
Custom values for use within Sections 0 and 1 of all future output BUFR messages written to all Fortr...
integer ns01v
Number of custom values stored.
character *8, dimension(:), allocatable cmnem
Section 0 and 1 mnemonics corresponding to ivmnem.
Declare arrays used by various subroutines and functions to hold a temporary working copy of a Sectio...
integer, dimension(:), allocatable ids3
Temporary working copy of Section 3 descriptor list in integer form.
character *6, dimension(:), allocatable cds3
Temporary working copy of Section 3 descriptor list in character form.
Declare an array used to store a switch for each file ID, indicating whether BUFR messages read from ...
character *8, dimension(:), allocatable tamnem
Table A mnemonic most recently read from each file ID, if isc3 = 1 for that stream.
integer, dimension(:), allocatable isc3
Section 3 switch for each file ID:
Declare arrays used to store file and message status indicators for all logical units that have been ...
integer, dimension(:), allocatable iolun
File status indicators.
integer, dimension(:), allocatable iomsg
Message status indicator corresponding to iolun, denoting whether a BUFR message is currently open wi...
Declare an array used to store a status code for each file ID if an error or other abnormal result oc...
integer, dimension(:), allocatable iscodes
Abnormal status codes.
Declare arrays and variables used to store DX BUFR tables internally for multiple file IDs.
integer, dimension(:), allocatable ntba
Number of Table A entries for each file ID (up to a maximum of maxtba, whose value is stored in array...
character *600, dimension(:,:), allocatable tabd
Table D entries for each file ID.
character *128, dimension(:,:), allocatable taba
Table A entries for each file ID.
integer, dimension(:,:), allocatable mtab
Entries within jump/link table corresponding to taba.
integer, dimension(:,:,:), allocatable idna
Message types (in array element 1) and subtypes (in array element 2) corresponding to taba.
integer, dimension(:), allocatable ntbd
Number of Table D entries for each file ID (up to a maximum of maxtbd, whose value is stored in array...
integer, dimension(:), allocatable ntbb
Number of Table B entries for each file ID (up to a maximum of maxtbb, whose value is stored in array...
integer, dimension(:,:), allocatable idnd
WMO bit-wise representations of the FXY values corresponding to tabd.
integer, dimension(:,:), allocatable idnb
WMO bit-wise representations of the FXY values corresponding to tabb.
character *128, dimension(:,:), allocatable tabb
Table B entries for each file ID.
Declare arrays and variables used to store the internal jump/link table.
integer, dimension(:), allocatable jseq
Temporary storage used in expanding sequences.
integer, dimension(:), allocatable irf
Reference values corresponding to tag and typ:
integer, dimension(:,:), allocatable iseq
Temporary storage used in expanding sequences.
integer, dimension(:), allocatable isc
Scale factors corresponding to tag and typ:
integer, dimension(:), allocatable ibt
Bit widths corresponding to tag and typ:
integer, dimension(:), allocatable knt
Temporary storage used in calculating delayed replication counts.
real *8, dimension(:), allocatable vali
Initialized data values corresponding to typ:
character *3, dimension(:), allocatable typ
Type indicators corresponding to tag:
integer, dimension(:), allocatable jmpb
Jump backward indices corresponding to tag and typ:
character *10, dimension(:), allocatable tag
Mnemonics in the jump/link table.
integer, dimension(:), allocatable jump
Jump forward indices corresponding to tag and typ:
integer, dimension(:), allocatable itp
Integer type values corresponding to typ:
integer, dimension(:), allocatable link
Link indices corresponding to tag, typ and jmpb:
integer, dimension(:), allocatable knti
Initialized replication counts corresponding to typ and jump:
Declare an array used to store, for each file ID, the logical unit number corresponding to a separate...
integer, dimension(:), allocatable luncpy
Logical unit numbers used to copy long character strings between BUFR data subsets.
Declare an array used to store, for each file ID from which a BUFR message is currently being read as...
integer, dimension(:), allocatable msgunp
Flag indicating how to unpack data subsets from BUFR message:
Declare arrays for internal storage of pointers to BUFR data subset values.
integer, dimension(:), allocatable nbit
Length (in bits) of each packed data value in data subset.
integer, dimension(:), allocatable mbit
Pointer in data subset to first bit of each packed data value.
Declare arrays used to store data values and associated metadata for the current BUFR data subset in ...
integer, dimension(:), allocatable nval
Number of data values in BUFR data subset.
real *8, dimension(:,:), allocatable, target val
Data values.
integer, dimension(:,:), allocatable, target inv
Inventory pointer which links each data value to its corresponding node in the internal jump/link tab...
integer, dimension(:,:), allocatable nrfelm
Referenced data value, for data values which refer to a previous data value in the BUFR data subset v...
Declare arrays used in subroutine rcstpl() to store subset segments that are being copied from a subs...
integer, dimension(:,:), allocatable iutmp
inv array elements for new sections of a growing subset buffer.
real *8, dimension(:,:), allocatable vutmp
val array elements for new sections of a growing subset buffer.
Declare an array used to track, for each file ID, whether the DX BUFR table associated with the corre...
logical, dimension(:), allocatable xtab
Tracking index for each file ID.
recursive subroutine closbf(lunit)
Close the connection between logical unit lunit and the NCEPLIBS-bufr software.
subroutine x84(iin8, iout4, nval)
Encode one or more 8-byte integer values as 4-byte integer values.