| 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 NUM2IX (NSETS, NINSET, IXSET) |
| 9 |
C======================================================================= |
| 10 |
|
| 11 |
C --*** NUM2IX *** (ETCLIB) Change number-in-set to set indices |
| 12 |
C -- Written by Amy Gilkey - revised 10/23/87 |
| 13 |
C -- |
| 14 |
C --NUM2IX creates the set indices given the number in each set. |
| 15 |
C -- |
| 16 |
C --Parameters: |
| 17 |
C -- NSETS - IN - the number of sets |
| 18 |
C -- NINSET - IN - the number in each set |
| 19 |
C -- IXSET - OUT - the set indices; set i = IXSET(i-1)+1 .. IXSET(i) |
| 20 |
|
| 21 |
INTEGER NINSET(*) |
| 22 |
INTEGER IXSET(0:*) |
| 23 |
|
| 24 |
IXSET(0) = 0 |
| 25 |
DO 10 I = 1, NSETS |
| 26 |
IXSET(I) = IXSET(I-1) + NINSET(I) |
| 27 |
10 CONTINUE |
| 28 |
|
| 29 |
RETURN |
| 30 |
END |