NCEPLIBS-bufr  12.1.0
arallocf.F90
Go to the documentation of this file.
1 
5 
18 subroutine arallocf
19 
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
23 
24  use moda_usrint
25  use moda_usrbit
26  use moda_ival
27  use moda_msgcwd
28  use moda_stbfr
29  use moda_ufbcpl
30  use moda_sc3bfr
31  use moda_unptyp
32  use moda_lushr
33  use moda_nulbfr
34  use moda_stcode
35  use moda_idrdm
36  use moda_xtab
37  use moda_msglim
38  use moda_bitbuf
39  use moda_mgwa
40  use moda_mgwb
41  use moda_bufrmg
42  use moda_bufrsr
43  use moda_msgmem
44  use moda_tababd
45  use moda_tables
46  use moda_usrtmp
47  use moda_ivttmp
48  use moda_comprx
49  use moda_comprs
50  use moda_mstabs
51  use moda_rdmtb
52  use moda_nmikrp
53  use moda_s01cm
54  use moda_bitmaps
55  use moda_nrv203
56  use moda_rlccmn
57  use moda_h4wlc
58  use moda_dscach
59  use moda_s3list
60 
61  implicit none
62 
63  character*80 errstr
64  character*36 brtstr
65 
66  integer iost, iprt
67 
68  common /quiet/ iprt
69 
70  if ( iprt >= 1 ) then
71  call errwrt ('++++++++++++++BUFR ARCHIVE LIBRARY+++++++++++++++++')
72  call errwrt ('BUFRLIB: ARRAYS WILL BE DYNAMICALLY ALLOCATED USING THE FOLLOWING VALUES:')
73  write ( errstr, '(a,i7)' ) ' MAXSS = ', maxss
74  call errwrt (errstr)
75  write ( errstr, '(a,i4)' ) ' NFILES = ', nfiles
76  call errwrt (errstr)
77  write ( errstr, '(a,i7)' ) ' MXMSGL = ', mxmsgl
78  call errwrt (errstr)
79  write ( errstr, '(a,i5)' ) ' MXDXTS = ', mxdxts
80  call errwrt (errstr)
81  write ( errstr, '(a,i7)' ) ' MAXMSG = ', maxmsg
82  call errwrt (errstr)
83  write ( errstr, '(a,i9)' ) ' MAXMEM = ', maxmem
84  call errwrt (errstr)
85  write ( errstr, '(a,i5)' ) ' MAXTBA = ', maxtba
86  call errwrt (errstr)
87  write ( errstr, '(a,i5)' ) ' MAXTBB = ', maxtbb
88  call errwrt (errstr)
89  write ( errstr, '(a,i5)' ) ' MAXTBD = ', maxtbd
90  call errwrt (errstr)
91  write ( errstr, '(a,i7)' ) ' MAXJL = ', maxjl
92  call errwrt (errstr)
93  write ( errstr, '(a,i6)' ) ' MXCDV = ', mxcdv
94  call errwrt (errstr)
95  write ( errstr, '(a,i4)' ) ' MXLCC = ', mxlcc
96  call errwrt (errstr)
97  write ( errstr, '(a,i6)' ) ' MXCSB = ', mxcsb
98  call errwrt (errstr)
99  write ( errstr, '(a,i5)' ) ' MXMTBB = ', mxmtbb
100  call errwrt (errstr)
101  write ( errstr, '(a,i5)' ) ' MXMTBD = ', mxmtbd
102  call errwrt (errstr)
103  write ( errstr, '(a,i4)' ) ' MAXCD = ', maxcd
104  call errwrt (errstr)
105  write ( errstr, '(a,i4)' ) ' MXNRV = ', mxnrv
106  call errwrt (errstr)
107  write ( errstr, '(a,i4)' ) ' MXS01V = ', mxs01v
108  call errwrt (errstr)
109  write ( errstr, '(a,i4)' ) ' MXTAMC = ', mxtamc
110  call errwrt (errstr)
111  write ( errstr, '(a,i4)' ) ' MXTCO = ', mxtco
112  call errwrt (errstr)
113  write ( errstr, '(a,i4)' ) ' MXBTM = ', mxbtm
114  call errwrt (errstr)
115  write ( errstr, '(a,i4)' ) ' MXBTMSE = ', mxbtmse
116  call errwrt (errstr)
117  write ( errstr, '(a,i4)' ) ' MXH4WLC = ', mxh4wlc
118  call errwrt (errstr)
119  write ( errstr, '(a,i4)' ) ' MXRST = ', mxrst
120  call errwrt (errstr)
121  write ( errstr, '(a,i4)' ) ' MXCNEM = ', mxcnem
122  call errwrt (errstr)
123  write ( errstr, '(a,i4)' ) ' MAXNC = ', maxnc
124  call errwrt (errstr)
125  call errwrt ('++++++++++++++BUFR ARCHIVE LIBRARY+++++++++++++++++')
126  end if
127 
128  brtstr = 'BUFRLIB: ARALLOCF FAILED ALLOCATING '
129 
130  ! moda_usrint arrays.
131 
132  allocate( nval(nfiles), stat=iost )
133  if ( iost /= 0 ) call bort( brtstr // 'NVAL' )
134 
135  allocate( inv(maxss,nfiles), stat=iost )
136  if ( iost /= 0 ) call bort( brtstr // 'INV' )
137 
138  allocate( nrfelm(maxss,nfiles), stat=iost )
139  if ( iost /= 0 ) call bort( brtstr // 'NRFELM' )
140 
141  allocate( val(maxss,nfiles), stat=iost )
142  if ( iost /= 0 ) call bort( brtstr // 'VAL' )
143 
144  ! moda_usrbit arrays.
145 
146  allocate( nbit(maxss), stat=iost )
147  if ( iost /= 0 ) call bort( brtstr // 'NBIT' )
148 
149  allocate( mbit(maxss), stat=iost )
150  if ( iost /= 0 ) call bort( brtstr // 'MBIT' )
151 
152  ! moda_ival arrays.
153 
154  allocate( ival(maxss), stat=iost )
155  if ( iost /= 0 ) call bort( brtstr // 'IVAL' )
156 
157  ! moda_msgcwd arrays.
158 
159  allocate( nmsg(nfiles), stat=iost )
160  if ( iost /= 0 ) call bort( brtstr // 'NMSG' )
161 
162  allocate( nsub(nfiles), stat=iost )
163  if ( iost /= 0 ) call bort( brtstr // 'NSUB' )
164 
165  allocate( msub(nfiles), stat=iost )
166  if ( iost /= 0 ) call bort( brtstr // 'MSUB' )
167 
168  allocate( inode(nfiles), stat=iost )
169  if ( iost /= 0 ) call bort( brtstr // 'INODE' )
170 
171  allocate( idate(nfiles), stat=iost )
172  if ( iost /= 0 ) call bort( brtstr // 'IDATE' )
173 
174  ! moda_stbfr arrays.
175 
176  allocate( iolun(nfiles), stat=iost )
177  if ( iost /= 0 ) call bort( brtstr // 'IOLUN' )
178 
179  allocate( iomsg(nfiles), stat=iost )
180  if ( iost /= 0 ) call bort( brtstr // 'IOMSG' )
181 
182  ! moda_ufbcpl arrays.
183 
184  allocate( luncpy(nfiles), stat=iost )
185  if ( iost /= 0 ) call bort( brtstr // 'LUNCPY' )
186 
187  ! moda_sc3bfr arrays.
188 
189  allocate( isc3(nfiles), stat=iost )
190  if ( iost /= 0 ) call bort( brtstr // 'ISC3' )
191 
192  allocate( tamnem(nfiles), stat=iost )
193  if ( iost /= 0 ) call bort( brtstr // 'TAMNEM' )
194 
195  ! moda_unptyp arrays.
196 
197  allocate( msgunp(nfiles), stat=iost )
198  if ( iost /= 0 ) call bort( brtstr // 'MSGUNP' )
199 
200  ! moda_lushr arrays.
201 
202  allocate( lus(nfiles), stat=iost )
203  if ( iost /= 0 ) call bort( brtstr // 'LUS' )
204 
205  ! moda_nulbfr arrays.
206 
207  allocate( null(nfiles), stat=iost )
208  if ( iost /= 0 ) call bort( brtstr // 'NULL' )
209 
210  ! moda_stcode arrays.
211 
212  allocate( iscodes(nfiles), stat=iost )
213  if ( iost /= 0 ) call bort( brtstr // 'ISCODES' )
214 
215  ! moda_idrdm arrays.
216 
217  allocate( idrdm(nfiles), stat=iost )
218  if ( iost /= 0 ) call bort( brtstr // 'IDRDM' )
219 
220  ! moda_xtab arrays.
221 
222  allocate( xtab(nfiles), stat=iost )
223  if ( iost /= 0 ) call bort( brtstr // 'XTAB' )
224 
225  ! moda_msglim arrays.
226 
227  allocate( msglim(nfiles), stat=iost )
228  if ( iost /= 0 ) call bort( brtstr // 'MSGLIM' )
229 
230  ! Calculate mxmsgld4 from mxmsgl.
231 
232  if ( mod(mxmsgl,4) == 0 ) then
233  mxmsgld4 = mxmsgl/4
234  else
235  mxmsgld4 = mxmsgl/4 + 1
236  end if
237 
238  ! moda_bitbuf arrays.
239 
240  allocate( ibay(mxmsgld4), stat=iost )
241  if ( iost /= 0 ) call bort( brtstr // 'IBAY' )
242 
243  allocate( mbyt(nfiles), stat=iost )
244  if ( iost /= 0 ) call bort( brtstr // 'MBYT' )
245 
246  allocate( mbay(mxmsgld4,nfiles), stat=iost )
247  if ( iost /= 0 ) call bort( brtstr // 'MBAY' )
248 
249  ! moda_mgwa arrays.
250 
251  allocate( mgwa(mxmsgld4), stat=iost )
252  if ( iost /= 0 ) call bort( brtstr // 'MGWA' )
253 
254  ! moda_mgwb arrays.
255 
256  allocate( mgwb(mxmsgld4), stat=iost )
257  if ( iost /= 0 ) call bort( brtstr // 'MGWB' )
258 
259  ! moda_bufrmg arrays.
260 
261  allocate( msglen(nfiles), stat=iost )
262  if ( iost /= 0 ) call bort( brtstr // 'MSGLEN' )
263  allocate( msgtxt(mxmsgld4,nfiles), stat=iost )
264  if ( iost /= 0 ) call bort( brtstr // 'MSGTXT' )
265 
266  ! moda_bufrsr arrays.
267 
268  allocate( jsr(nfiles), stat=iost )
269  if ( iost /= 0 ) call bort( brtstr // 'JSR' )
270 
271  allocate( jbay(mxmsgld4), stat=iost )
272  if ( iost /= 0 ) call bort( brtstr // 'JBAY' )
273 
274  ! Calculate mxdxm and mxdxw from mxdxts and mxmsgld4.
275 
276  mxdxm = mxdxts*3
277  mxdxw = mxdxm*mxmsgld4
278 
279  ! moda_msgmem arrays.
280 
281  allocate( msgp(0:maxmsg), stat=iost )
282  if ( iost /= 0 ) call bort( brtstr // 'MSGP' )
283 
284  allocate( msgs(maxmem), stat=iost )
285  if ( iost /= 0 ) call bort( brtstr // 'MSGS' )
286 
287  allocate( mdx(mxdxw), stat=iost )
288  if ( iost /= 0 ) call bort( brtstr // 'MDX' )
289 
290  allocate( ipdxm(mxdxm), stat=iost )
291  if ( iost /= 0 ) call bort( brtstr // 'IPDXM' )
292 
293  allocate( ifdxts(mxdxts), stat=iost )
294  if ( iost /= 0 ) call bort( brtstr // 'ifDXTS' )
295 
296  allocate( icdxts(mxdxts), stat=iost )
297  if ( iost /= 0 ) call bort( brtstr // 'ICDXTS' )
298 
299  allocate( ipmsgs(mxdxts), stat=iost )
300  if ( iost /= 0 ) call bort( brtstr // 'IPMSGS' )
301 
302  ! moda_tababd arrays.
303 
304  allocate( ntba(0:nfiles), stat=iost )
305  if ( iost /= 0 ) call bort( brtstr // 'NTBA' )
306 
307  allocate( ntbb(0:nfiles), stat=iost )
308  if ( iost /= 0 ) call bort( brtstr // 'NTBB' )
309 
310  allocate( ntbd(0:nfiles), stat=iost )
311  if ( iost /= 0 ) call bort( brtstr // 'NTBD' )
312 
313  allocate( mtab(maxtba,nfiles), stat=iost )
314  if ( iost /= 0 ) call bort( brtstr // 'MTAB' )
315 
316  allocate( idna(maxtba,nfiles,2), stat=iost )
317  if ( iost /= 0 ) call bort( brtstr // 'IDNA' )
318 
319  allocate( idnb(maxtbb,nfiles), stat=iost )
320  if ( iost /= 0 ) call bort( brtstr // 'IDNB' )
321 
322  allocate( idnd(maxtbd,nfiles), stat=iost )
323  if ( iost /= 0 ) call bort( brtstr // 'IDND' )
324 
325  allocate( taba(maxtba,nfiles), stat=iost )
326  if ( iost /= 0 ) call bort( brtstr // 'TABA' )
327 
328  allocate( tabb(maxtbb,nfiles), stat=iost )
329  if ( iost /= 0 ) call bort( brtstr // 'TABB' )
330 
331  allocate( tabd(maxtbd,nfiles), stat=iost )
332  if ( iost /= 0 ) call bort( brtstr // 'TABD' )
333 
334  ! moda_tables arrays.
335 
336  allocate( tag(maxjl), stat=iost )
337  if ( iost /= 0 ) call bort( brtstr // 'TAG' )
338 
339  allocate( typ(maxjl), stat=iost )
340  if ( iost /= 0 ) call bort( brtstr // 'TYP' )
341 
342  allocate( knt(maxjl), stat=iost )
343  if ( iost /= 0 ) call bort( brtstr // 'KNT' )
344 
345  allocate( jump(maxjl), stat=iost )
346  if ( iost /= 0 ) call bort( brtstr // 'JUMP' )
347 
348  allocate( link(maxjl), stat=iost )
349  if ( iost /= 0 ) call bort( brtstr // 'LINK' )
350 
351  allocate( jmpb(maxjl), stat=iost )
352  if ( iost /= 0 ) call bort( brtstr // 'JMPB' )
353 
354  allocate( ibt(maxjl), stat=iost )
355  if ( iost /= 0 ) call bort( brtstr // 'IBT' )
356 
357  allocate( irf(maxjl), stat=iost )
358  if ( iost /= 0 ) call bort( brtstr // 'IRF' )
359 
360  allocate( isc(maxjl), stat=iost )
361  if ( iost /= 0 ) call bort( brtstr // 'ISC' )
362 
363  allocate( itp(maxjl), stat=iost )
364  if ( iost /= 0 ) call bort( brtstr // 'ITP' )
365 
366  allocate( vali(maxjl), stat=iost )
367  if ( iost /= 0 ) call bort( brtstr // 'VALI' )
368 
369  allocate( knti(maxjl), stat=iost )
370  if ( iost /= 0 ) call bort( brtstr // 'KNTI' )
371 
372  allocate( iseq(maxjl,2), stat=iost )
373  if ( iost /= 0 ) call bort( brtstr // 'ISEQ' )
374 
375  allocate( jseq(maxjl), stat=iost )
376  if ( iost /= 0 ) call bort( brtstr // 'JSEQ' )
377 
378  ! moda_usrtmp arrays.
379 
380  allocate( iutmp(maxjl,maxrcr), stat=iost )
381  if ( iost /= 0 ) call bort( brtstr // 'IUTMP' )
382 
383  allocate( vutmp(maxjl,maxrcr), stat=iost )
384  if ( iost /= 0 ) call bort( brtstr // 'VUTMP' )
385 
386  ! moda_ivttmp arrays.
387 
388  allocate( ttmp(maxjl), stat=iost )
389  if ( iost /= 0 ) call bort( brtstr // 'TTMP' )
390 
391  allocate( itmp(maxjl), stat=iost )
392  if ( iost /= 0 ) call bort( brtstr // 'ITMP' )
393 
394  allocate( vtmp(maxjl), stat=iost )
395  if ( iost /= 0 ) call bort( brtstr // 'VTMP' )
396 
397  ! moda_comprx arrays.
398 
399  allocate( kmin(mxcdv), stat=iost )
400  if ( iost /= 0 ) call bort( brtstr // 'KMIN' )
401 
402  allocate( kmax(mxcdv), stat=iost )
403  if ( iost /= 0 ) call bort( brtstr // 'KMAX' )
404 
405  allocate( kmis(mxcdv), stat=iost )
406  if ( iost /= 0 ) call bort( brtstr // 'KMIS' )
407 
408  allocate( kbit(mxcdv), stat=iost )
409  if ( iost /= 0 ) call bort( brtstr // 'KBIT' )
410 
411  allocate( ityp(mxcdv), stat=iost )
412  if ( iost /= 0 ) call bort( brtstr // 'ITYP' )
413 
414  allocate( iwid(mxcdv), stat=iost )
415  if ( iost /= 0 ) call bort( brtstr // 'IWID' )
416 
417  allocate( character*(mxlcc) :: cstr(mxcdv), stat=iost )
418  if ( iost /= 0 ) call bort( brtstr // 'CSTR' )
419 
420  allocate( jlnode(mxcdv), stat=iost )
421  if ( iost /= 0 ) call bort( brtstr // 'JLNODE' )
422 
423  ! moda_comprs arrays.
424 
425  allocate( matx(mxcdv,mxcsb), stat=iost )
426  if ( iost /= 0 ) call bort( brtstr // 'MATX' )
427 
428  allocate( character*(mxlcc) :: catx(mxcdv,mxcsb), stat=iost )
429  if ( iost /= 0 ) call bort( brtstr // 'CATX' )
430 
431  ! moda_mstabs arrays.
432 
433  allocate( ibfxyn(mxmtbb), stat=iost )
434  if ( iost /= 0 ) call bort( brtstr // 'IBFXYN' )
435 
436  allocate( cbscl(4,mxmtbb), stat=iost )
437  if ( iost /= 0 ) call bort( brtstr // 'CBSCL' )
438 
439  allocate( cbsref(12,mxmtbb), stat=iost )
440  if ( iost /= 0 ) call bort( brtstr // 'CBSREF' )
441 
442  allocate( cbbw(4,mxmtbb), stat=iost )
443  if ( iost /= 0 ) call bort( brtstr // 'CBBW' )
444 
445  allocate( cbunit(24,mxmtbb), stat=iost )
446  if ( iost /= 0 ) call bort( brtstr // 'CBUNIT' )
447 
448  allocate( cbmnem(8,mxmtbb), stat=iost )
449  if ( iost /= 0 ) call bort( brtstr // 'CBMNEM' )
450 
451  allocate( cbelem(120,mxmtbb), stat=iost )
452  if ( iost /= 0 ) call bort( brtstr // 'CBELEM' )
453 
454  allocate( idfxyn(mxmtbd), stat=iost )
455  if ( iost /= 0 ) call bort( brtstr // 'IDFXYN' )
456 
457  allocate( cdseq(120,mxmtbd), stat=iost )
458  if ( iost /= 0 ) call bort( brtstr // 'CDSEQ' )
459 
460  allocate( cdmnem(8,mxmtbd), stat=iost )
461  if ( iost /= 0 ) call bort( brtstr // 'CDMNEM' )
462 
463  allocate( ndelem(mxmtbd), stat=iost )
464  if ( iost /= 0 ) call bort( brtstr // 'NDELEM' )
465 
466  allocate( idefxy(mxmtbd*maxcd), stat=iost )
467  if ( iost /= 0 ) call bort( brtstr // 'IDEFXY' )
468 
469  ! moda_rdmtb arrays.
470 
471  allocate( iefxyn(mxmtbd,maxcd), stat=iost )
472  if ( iost /= 0 ) call bort( brtstr // 'IEFXYN' )
473 
474  allocate( cmdscb(mxmtbb), stat=iost )
475  if ( iost /= 0 ) call bort( brtstr // 'CMDSCB' )
476 
477  allocate( cmdscd(mxmtbd), stat=iost )
478  if ( iost /= 0 ) call bort( brtstr // 'CMDSCD' )
479 
480  allocate( ceelem(mxmtbd,maxcd), stat=iost )
481  if ( iost /= 0 ) call bort( brtstr // 'CEELEM' )
482 
483  ! moda_nmikrp arrays.
484 
485  allocate( nem(maxcd,10), stat=iost )
486  if ( iost /= 0 ) call bort( brtstr // 'NEM' )
487 
488  allocate( irp(maxcd,10), stat=iost )
489  if ( iost /= 0 ) call bort( brtstr // 'IRP' )
490 
491  allocate( krp(maxcd,10), stat=iost )
492  if ( iost /= 0 ) call bort( brtstr // 'KRP' )
493 
494  ! moda_s01cm arrays.
495 
496  allocate( ivmnem(mxs01v), stat=iost )
497  if ( iost /= 0 ) call bort( brtstr // 'IVMNEM' )
498 
499  allocate( cmnem(mxs01v), stat=iost )
500  if ( iost /= 0 ) call bort( brtstr // 'CMNEM' )
501 
502  ! moda_bitmaps arrays.
503 
504  allocate( inodtamc(mxtamc), stat=iost )
505  if ( iost /= 0 ) call bort( brtstr // 'INODTAMC' )
506 
507  allocate( ntco(mxtamc), stat=iost )
508  if ( iost /= 0 ) call bort( brtstr // 'NTCO' )
509 
510  allocate( ctco(mxtamc,mxtco), stat=iost )
511  if ( iost /= 0 ) call bort( brtstr // 'CTCO' )
512 
513  allocate( inodtco(mxtamc,mxtco), stat=iost )
514  if ( iost /= 0 ) call bort( brtstr // 'INODTCO' )
515 
516  allocate( nbtmse(mxbtm), stat=iost )
517  if ( iost /= 0 ) call bort( brtstr // 'NBTMSE' )
518 
519  allocate( istbtm(mxbtm), stat=iost )
520  if ( iost /= 0 ) call bort( brtstr // 'ISTBTM' )
521 
522  allocate( iszbtm(mxbtm), stat=iost )
523  if ( iost /= 0 ) call bort( brtstr // 'ISZBTM' )
524 
525  allocate( ibtmse(mxbtm,mxbtmse), stat=iost )
526  if ( iost /= 0 ) call bort( brtstr // 'IBTMSE' )
527 
528  ! moda_nrv203 arrays.
529 
530  allocate( tagnrv(mxnrv), stat=iost )
531  if ( iost /= 0 ) call bort( brtstr // 'TAGNRV' )
532 
533  allocate( inodnrv(mxnrv), stat=iost )
534  if ( iost /= 0 ) call bort( brtstr // 'INODNRV' )
535 
536  allocate( nrv(mxnrv), stat=iost )
537  if ( iost /= 0 ) call bort( brtstr // 'NRV' )
538 
539  allocate( isnrv(mxnrv), stat=iost )
540  if ( iost /= 0 ) call bort( brtstr // 'ISNRV' )
541 
542  allocate( ienrv(mxnrv), stat=iost )
543  if ( iost /= 0 ) call bort( brtstr // 'IENRV' )
544 
545  ! moda_rlccmn arrays.
546 
547  allocate( irnch(mxrst), stat=iost )
548  if ( iost /= 0 ) call bort( brtstr // 'IRNCH' )
549 
550  allocate( irbit(mxrst), stat=iost )
551  if ( iost /= 0 ) call bort( brtstr // 'IRBIT' )
552 
553  allocate( crtag(mxrst), stat=iost )
554  if ( iost /= 0 ) call bort( brtstr // 'CRTAG' )
555 
556  ! moda_h4wlc arrays.
557 
558  allocate( luh4wlc(mxh4wlc), stat=iost )
559  if ( iost /= 0 ) call bort( brtstr // 'LUH4WLC' )
560 
561  allocate( sth4wlc(mxh4wlc), stat=iost )
562  if ( iost /= 0 ) call bort( brtstr // 'STH4WLC' )
563 
564  allocate( chh4wlc(mxh4wlc), stat=iost )
565  if ( iost /= 0 ) call bort( brtstr // 'CHH4WLC' )
566 
567  ! moda_dscach arrays.
568 
569  allocate( cnem(mxcnem), stat=iost )
570  if ( iost /= 0 ) call bort( brtstr // 'CNEM' )
571 
572  allocate( ndc(mxcnem), stat=iost )
573  if ( iost /= 0 ) call bort( brtstr // 'NDC' )
574 
575  allocate( idcach(mxcnem,maxnc), stat=iost )
576  if ( iost /= 0 ) call bort( brtstr // 'IDCACH' )
577 
578  ! moda_s3list arrays.
579 
580  allocate( ids3(maxnc), stat=iost )
581  if ( iost /= 0 ) call bort( brtstr // 'IDS3' )
582 
583  allocate( cds3(maxnc), stat=iost )
584  if ( iost /= 0 ) call bort( brtstr // 'CDS3' )
585 
586  return
587 end subroutine arallocf
588 
592 subroutine ardllocf
593 
594  use bufrlib
595 
596  use moda_usrint
597  use moda_usrbit
598  use moda_ival
599  use moda_msgcwd
600  use moda_stbfr
601  use moda_ufbcpl
602  use moda_sc3bfr
603  use moda_unptyp
604  use moda_lushr
605  use moda_nulbfr
606  use moda_stcode
607  use moda_idrdm
608  use moda_xtab
609  use moda_msglim
610  use moda_bitbuf
611  use moda_mgwa
612  use moda_mgwb
613  use moda_bufrmg
614  use moda_bufrsr
615  use moda_msgmem
616  use moda_tababd
617  use moda_tables
618  use moda_usrtmp
619  use moda_ivttmp
620  use moda_comprx
621  use moda_comprs
622  use moda_mstabs
623  use moda_rdmtb
624  use moda_nmikrp
625  use moda_s01cm
626  use moda_bitmaps
627  use moda_nrv203
628  use moda_rlccmn
629  use moda_h4wlc
630  use moda_dscach
631  use moda_s3list
632 
633  implicit none
634 
635  ! moda_usrint arrays.
636 
637  deallocate( nval )
638  deallocate( inv )
639  deallocate( nrfelm )
640  deallocate( val )
641 
642  ! moda_usrbit arrays.
643 
644  deallocate( nbit )
645  deallocate( mbit )
646 
647  ! moda_ival arrays.
648 
649  deallocate( ival )
650 
651  ! moda_msgcwd arrays.
652 
653  deallocate( nmsg )
654  deallocate( nsub )
655  deallocate( msub )
656  deallocate( inode )
657  deallocate( idate )
658 
659  ! moda_stbfr arrays.
660 
661  deallocate( iolun )
662  deallocate( iomsg )
663 
664  ! moda_ufbcpl arrays.
665 
666  deallocate( luncpy )
667 
668  ! moda_sc3bfr arrays.
669 
670  deallocate( isc3 )
671  deallocate( tamnem )
672 
673  ! moda_unptyp arrays.
674 
675  deallocate( msgunp )
676 
677  ! moda_lushr arrays.
678 
679  deallocate( lus )
680 
681  ! moda_nulbfr arrays.
682 
683  deallocate( null )
684 
685  ! moda_stcode arrays.
686 
687  deallocate( iscodes )
688 
689  ! moda_idrdm arrays.
690 
691  deallocate( idrdm )
692 
693  ! moda_xtab arrays.
694 
695  deallocate( xtab )
696 
697  ! moda_msglim arrays.
698 
699  deallocate( msglim )
700 
701  ! moda_bitbuf arrays.
702 
703  deallocate( ibay )
704  deallocate( mbyt )
705  deallocate( mbay )
706 
707  ! moda_mgwa arrays.
708 
709  deallocate( mgwa )
710 
711  ! moda_mgwb arrays.
712 
713  deallocate( mgwb )
714 
715  ! moda_bufrmg arrays.
716 
717  deallocate( msglen )
718  deallocate( msgtxt )
719 
720  ! moda_bufrsr arrays.
721 
722  deallocate( jsr )
723  deallocate( jbay )
724 
725  ! moda_msgmem arrays.
726 
727  deallocate( msgp )
728  deallocate( msgs )
729  deallocate( mdx )
730  deallocate( ipdxm )
731  deallocate( ifdxts )
732  deallocate( icdxts )
733  deallocate( ipmsgs )
734 
735  ! moda_tababd arrays.
736 
737  deallocate( ntba )
738  deallocate( ntbb )
739  deallocate( ntbd )
740  deallocate( mtab )
741  deallocate( idna )
742  deallocate( idnb )
743  deallocate( idnd )
744  deallocate( taba )
745  deallocate( tabb )
746  deallocate( tabd )
747 
748  ! moda_tables arrays.
749 
750  deallocate( tag )
751  deallocate( typ )
752  deallocate( knt )
753  deallocate( jump )
754  deallocate( link )
755  deallocate( jmpb )
756  deallocate( ibt )
757  deallocate( irf )
758  deallocate( isc )
759  deallocate( itp )
760  deallocate( vali )
761  deallocate( knti )
762  deallocate( iseq )
763  deallocate( jseq )
764 
765  ! moda_usrtmp arrays.
766 
767  deallocate( iutmp )
768  deallocate( vutmp )
769 
770  ! moda_ivttmp arrays.
771 
772  deallocate( ttmp )
773  deallocate( itmp )
774  deallocate( vtmp )
775 
776  ! moda_comprx arrays.
777 
778  deallocate( kmin )
779  deallocate( kmax )
780  deallocate( kmis )
781  deallocate( kbit )
782  deallocate( ityp )
783  deallocate( iwid )
784  deallocate( cstr )
785  deallocate( jlnode )
786 
787  ! moda_comprs arrays.
788 
789  deallocate( matx )
790  deallocate( catx )
791 
792  ! moda_mstabs arrays.
793 
794  deallocate( ibfxyn )
795  deallocate( cbscl )
796  deallocate( cbsref )
797  deallocate( cbbw )
798  deallocate( cbunit )
799  deallocate( cbmnem )
800  deallocate( cbelem )
801  deallocate( idfxyn )
802  deallocate( cdseq )
803  deallocate( cdmnem )
804  deallocate( ndelem )
805  deallocate( idefxy )
806 
807  ! moda_rdmtb arrays.
808 
809  deallocate( iefxyn )
810  deallocate( cmdscb )
811  deallocate( cmdscd )
812  deallocate( ceelem )
813 
814  ! moda_nmikrp arrays.
815 
816  deallocate( nem )
817  deallocate( irp )
818  deallocate( krp )
819 
820  ! moda_s01cm arrays.
821 
822  deallocate( ivmnem )
823  deallocate( cmnem )
824 
825  ! moda_bitmaps arrays.
826 
827  deallocate( inodtamc )
828  deallocate( ntco )
829  deallocate( ctco )
830  deallocate( inodtco )
831  deallocate( nbtmse )
832  deallocate( istbtm )
833  deallocate( iszbtm )
834  deallocate( ibtmse )
835 
836  ! moda_nrv203 arrays.
837 
838  deallocate( tagnrv )
839  deallocate( inodnrv )
840  deallocate( nrv )
841  deallocate( isnrv )
842  deallocate( ienrv )
843 
844  ! moda_rlccmn arrays.
845 
846  deallocate( irnch )
847  deallocate( irbit )
848  deallocate( crtag )
849 
850  ! moda_h4wlc arrays.
851 
852  deallocate( luh4wlc )
853  deallocate( sth4wlc )
854  deallocate( chh4wlc )
855 
856  ! moda_dscach arrays.
857 
858  deallocate( cnem )
859  deallocate( ndc )
860  deallocate( idcach )
861 
862  ! moda_s3list arrays.
863 
864  deallocate( ids3 )
865  deallocate( cds3 )
866 
867  ! C language arrays.
868 
869  call ardllocc_c
870 
871  return
872 end subroutine ardllocf
873 
900 subroutine exitbufr
901 
902  use bufrlib
903 
904  use modv_vars, only: ifopbf, nfiles
905 
906  use moda_stbfr
907  use moda_s01cm
908  use moda_tablef
909 
910  ! Close any logical units that are open to the library.
911 
912  do jj = 1, nfiles
913  if ( iolun(jj) /= 0 ) call closbf( abs(iolun(jj)) )
914  end do
915 
916  ! Deallocate all allocated memory.
917 
918  call ardllocf
919 
920  if ( cdmf == 'Y' ) call dlloctbf_c
921 
922  ! Reset the library.
923 
924  ns01v = 0
925  ifopbf = 0
926 
927  return
928 end subroutine exitbufr
929 
979 recursive integer function isetprm ( cprmnm, ipval ) result ( iret )
980 
981  use modv_vars, only: mxmsgl, maxss, nfiles, mxdxts, maxmsg, maxmem, maxtba, maxtbb, maxtbd, maxjl, &
982  mxcdv, mxlcc, mxcsb, mxmtbb, mxmtbd, mxmtbf, maxcd, mxs01v, mxbtm, mxbtmse, &
983  mxtamc, mxtco, mxnrv, mxrst, mxh4wlc, im8b, mxcnem, maxnc, mxnaf
984 
985  implicit none
986 
987  character*(*), intent(in) :: cprmnm
988 
989  integer, intent(in) :: ipval
990 
991  integer my_ipval
992 
993  character*128 errstr
994 
995  ! Check for I8 integers.
996 
997  if ( im8b ) then
998  im8b = .false.
999 
1000  call x84 ( ipval, my_ipval, 1 )
1001  iret = isetprm( cprmnm, my_ipval )
1002 
1003  im8b = .true.
1004  return
1005  endif
1006 
1007  iret = 0
1008  if ( cprmnm == 'MAXSS' ) then
1009  maxss = ipval
1010  else if ( cprmnm == 'NFILES' ) then
1011  nfiles = ipval
1012  else if ( cprmnm == 'MXMSGL' ) then
1013  mxmsgl = ipval
1014  else if ( cprmnm == 'MXDXTS' ) then
1015  mxdxts = ipval
1016  else if ( cprmnm == 'MAXMSG' ) then
1017  maxmsg = ipval
1018  else if ( cprmnm == 'MAXMEM' ) then
1019  maxmem = ipval
1020  else if ( cprmnm == 'MAXTBA' ) then
1021  maxtba = ipval
1022  else if ( cprmnm == 'MAXTBB' ) then
1023  maxtbb = ipval
1024  else if ( cprmnm == 'MAXTBD' ) then
1025  maxtbd = ipval
1026  else if ( cprmnm == 'MAXJL' ) then
1027  maxjl = ipval
1028  else if ( cprmnm == 'MXCDV' ) then
1029  mxcdv = ipval
1030  else if ( cprmnm == 'MXLCC' ) then
1031  mxlcc = ipval
1032  else if ( cprmnm == 'MXCSB' ) then
1033  mxcsb = ipval
1034  else if ( cprmnm == 'MXMTBB' ) then
1035  mxmtbb = ipval
1036  else if ( cprmnm == 'MXMTBD' ) then
1037  mxmtbd = ipval
1038  else if ( cprmnm == 'MXMTBF' ) then
1039  mxmtbf = ipval
1040  else if ( cprmnm == 'MAXCD' ) then
1041  maxcd = ipval
1042  else if ( cprmnm == 'MXS01V' ) then
1043  mxs01v = ipval
1044  else if ( cprmnm == 'MXBTM' ) then
1045  mxbtm = ipval
1046  else if ( cprmnm == 'MXBTMSE' ) then
1047  mxbtmse = ipval
1048  else if ( cprmnm == 'MXTAMC' ) then
1049  mxtamc = ipval
1050  else if ( cprmnm == 'MXTCO' ) then
1051  mxtco = ipval
1052  else if ( cprmnm == 'MXNRV' ) then
1053  mxnrv = ipval
1054  else if ( cprmnm == 'MXRST' ) then
1055  mxrst = ipval
1056  else if ( cprmnm == 'MXH4WLC' ) then
1057  mxh4wlc = ipval
1058  else if ( cprmnm == 'MXCNEM' ) then
1059  mxcnem = ipval
1060  else if ( cprmnm == 'MAXNC' ) then
1061  maxnc = ipval
1062  else if ( cprmnm == 'MXNAF' ) then
1063  mxnaf = ipval
1064  else
1065  iret = -1
1066  call errwrt('++++++++++++++++++WARNING+++++++++++++++++++')
1067  errstr = 'BUFRLIB: ISETPRM - UNKNOWN INPUT PARAMETER '// cprmnm // ' -- NO ACTION WAS TAKEN'
1068  call errwrt(errstr)
1069  call errwrt('++++++++++++++++++WARNING+++++++++++++++++++')
1070  endif
1071 
1072  return
1073 end function isetprm
1074 
1113 integer function igetprm ( cprmnm ) result ( iret )
1114 
1115  use modv_vars, only: mxmsgl, maxss, nfiles, mxdxts, maxmsg, maxmem, maxtba, maxtbb, maxtbd, maxjl, &
1116  mxcdv, mxlcc, mxcsb, mxmtbb, mxmtbd, mxmtbf, maxcd, mxs01v, mxbtm, mxbtmse, &
1117  mxtamc, mxtco, mxnrv, mxrst, mxh4wlc, mxcnem, maxnc, mxnaf
1118 
1119  implicit none
1120 
1121  character*(*), intent(in) :: cprmnm
1122 
1123  character*64 errstr
1124 
1125  if ( cprmnm == 'MAXSS' ) then
1126  iret = maxss
1127  else if ( cprmnm == 'NFILES' ) then
1128  iret = nfiles
1129  else if ( cprmnm == 'MXMSGL' ) then
1130  iret = mxmsgl
1131  else if ( cprmnm == 'MXDXTS' ) then
1132  iret = mxdxts
1133  else if ( cprmnm == 'MAXMSG' ) then
1134  iret = maxmsg
1135  else if ( cprmnm == 'MAXMEM' ) then
1136  iret = maxmem
1137  else if ( cprmnm == 'MAXTBA' ) then
1138  iret = maxtba
1139  else if ( cprmnm == 'MAXTBB' ) then
1140  iret = maxtbb
1141  else if ( cprmnm == 'MAXTBD' ) then
1142  iret = maxtbd
1143  else if ( cprmnm == 'MAXJL' ) then
1144  iret = maxjl
1145  else if ( cprmnm == 'MXCDV' ) then
1146  iret = mxcdv
1147  else if ( cprmnm == 'MXLCC' ) then
1148  iret = mxlcc
1149  else if ( cprmnm == 'MXCSB' ) then
1150  iret = mxcsb
1151  else if ( cprmnm == 'MXMTBB' ) then
1152  iret = mxmtbb
1153  else if ( cprmnm == 'MXMTBD' ) then
1154  iret = mxmtbd
1155  else if ( cprmnm == 'MXMTBF' ) then
1156  iret = mxmtbf
1157  else if ( cprmnm == 'MAXCD' ) then
1158  iret = maxcd
1159  else if ( cprmnm == 'MXS01V' ) then
1160  iret = mxs01v
1161  else if ( cprmnm == 'MXBTM' ) then
1162  iret = mxbtm
1163  else if ( cprmnm == 'MXBTMSE' ) then
1164  iret = mxbtmse
1165  else if ( cprmnm == 'MXTAMC' ) then
1166  iret = mxtamc
1167  else if ( cprmnm == 'MXTCO' ) then
1168  iret = mxtco
1169  else if ( cprmnm == 'MXNRV' ) then
1170  iret = mxnrv
1171  else if ( cprmnm == 'MXRST' ) then
1172  iret = mxrst
1173  else if ( cprmnm == 'MXH4WLC' ) then
1174  iret = mxh4wlc
1175  else if ( cprmnm == 'MXCNEM' ) then
1176  iret = mxcnem
1177  else if ( cprmnm == 'MAXNC' ) then
1178  iret = maxnc
1179  else if ( cprmnm == 'MXNAF' ) then
1180  iret = mxnaf
1181  else
1182  iret = -1
1183  call errwrt('++++++++++++++++++WARNING+++++++++++++++++++')
1184  errstr = 'BUFRLIB: IGETPRM - UNKNOWN INPUT PARAMETER '// cprmnm
1185  call errwrt(errstr)
1186  call errwrt('++++++++++++++++++WARNING+++++++++++++++++++')
1187  endif
1188 
1189  return
1190 end function igetprm
integer function igetprm(cprmnm)
Return the current value of a parameter used for allocating one or more internal arrays within the NC...
Definition: arallocf.F90:1114
subroutine arallocf
Dynamically allocate Fortran language arrays.
Definition: arallocf.F90:19
subroutine exitbufr
Free all dynamically-allocated memory, close all logical units that are open within the NCEPLIBS-bufr...
Definition: arallocf.F90:901
recursive integer function isetprm(cprmnm, ipval)
Set a specified parameter to a specified value for use in dynamically allocating one or more internal...
Definition: arallocf.F90:980
subroutine ardllocf
Free all memory that was dynamically allocated during a previous call to subroutine arallocf().
Definition: arallocf.F90:593
subroutine bort(str)
Log an error message, then abort the application program.
Definition: borts.F90:15
subroutine errwrt(str)
Specify a custom location for the logging of error and diagnostic messages generated by the NCEPLIBS-...
Definition: errwrt.F90:32
Wrap C NCEPLIBS-bufr functions so they can be called from within the Fortran part of the library.
Definition: bufrlib.F90:11
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 a variable used to indicate whether master code and flag tables should be read.
character cdmf
Flag indicating whether to include code and flag table information during reads of master BUFR tables...
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.
Definition: x4884.F90:65