Debian Codegraph @

packages/seacas/applications/txtexo/rdnm1.f

raw
1 C Copyright(C) 1999-2020 National Technology & Engineering Solutions
2 C of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with
3 C NTESS, the U.S. Government retains certain rights in this software.
4 C
5 C See packages/seacas/LICENSE for details
6
7 C=======================================================================
8 SUBROUTINE RDNM1 (NTXT, NDB, NELBLK, NVAREL, ISEVOK, LSEVOK, *)
9 C=======================================================================
10
11 C --*** RDNM1 *** (TXTEXO) Internal to RDNAME
12 C -- Written by Amy Gilkey - revised 02/22/88
13 C --
14 C --RDNM1 reads the element block variable truth table.
15 C --
16 C --Parameters:
17 C -- NTXT - IN - the text file
18 C -- NELBLK - IN - the number of element blocks
19 C -- NVAREL - IN - the number of element variables
20 C -- ISEVOK - OUT - the element block variable truth table;
21 C -- variable i of block j exists iff ISEVOK(j,i)
22 C -- * - return statement if error encountered, including end-of-file;
23 C -- NO message is printed
24 C --
25 C --Database must be positioned in front of truth table upon entry;
26 C --upon exit positioned after table.
27
28 INTEGER ISEVOK(NVAREL,*)
29 LOGICAL LSEVOK(NVAREL,*)
30
31 CHARACTER*32 STRA
32
33 C ... Nothing to read if NVAREL == 0
34 if (nvarel .eq. 0) return
35
36 IELB = 0
37 READ (NTXT, *, END=110, ERR=110)
38 DO 100 IELB = 1, NELBLK
39 READ (NTXT, *, END=110, ERR=110) (LSEVOK(I,IELB), I=1,NVAREL)
40 DO 90 I = 1, NVAREL
41 if (lsevok(i,ielb)) then
42 isevok(i,ielb) = 1
43 else
44 isevok(i,ielb) = 0
45 end if
46 90 continue
47 100 CONTINUE
48
49 call expvtt(ndb, nelblk, nvarel, isevok, ierr)
50
51 RETURN
52
53 110 CONTINUE
54 CALL INTSTR (1, 0, IELB, STRA, LSTRA)
55 CALL PRTERR ('FATAL',
56 & 'Reading ELEMENT BLOCK VARIABLE TRUTH TABLE for block '
57 & // STRA(:LSTRA))
58 GOTO 120
59 120 CONTINUE
60 RETURN 1
61 END