|
EpetraExt
Development
|
00001 subroutine prtivs ( title, n, x, output ) 00002 00003 c ================================================================== 00004 c ==== bcs sparse matrix package, release 0 ==== 00005 c ================================================================== 00006 c ================================================================== 00007 c ==== prtivs -- print integer vector in table (short format) ==== 00008 c ================================================================== 00009 c ================================================================== 00010 c 00011 c prtivs prints out the integer vector x of length n to logical 00012 c unit output in a short format. the character string in title is 00013 c printed as a title for the table 00014 c 00015 c last modified --- july 10, 1989 -- jgl -- 00016 c 00017 c -------------- 00018 c ... parameters 00019 c -------------- 00020 00021 character * (*) title 00022 00023 integer n, output 00024 00025 integer x(n) 00026 00027 c ------------------- 00028 c ... local variables 00029 c ------------------- 00030 00031 integer i, l 00032 00033 character * 75 line 00034 00035 c ================================================================== 00036 00037 c --------------- 00038 c ... write title 00039 c --------------- 00040 00041 l = min ( len (title), 75 ) 00042 00043 do 100 i = 1, l 00044 line(i:i) = '-' 00045 100 continue 00046 00047 do 200 i = l+1, 75 00048 line(i:i) = ' ' 00049 200 continue 00050 00051 write ( output, 2000 ) title (1:l), line (1:l) 00052 00053 c ------------------------ 00054 c ... write out the vector 00055 c ------------------------ 00056 00057 write ( output, 2100 ) x 00058 00059 return 00060 00061 c ----------- 00062 c ... formats 00063 c ----------- 00064 00065 2000 format ( /5x, a /5x, a / ) 00066 00067 2100 format ( (10x, 10 (1x, i5)) ) 00068 00069 end
1.7.6.1