14 integer,
pointer :: ia(:)
15 integer,
pointer :: ja(:)
16 real(8),
pointer :: val(:,:)
20 subroutine reserv(i,j,jstat,irpt,irowno,k)
24 integer,
dimension(:) :: irpt
25 integer,
dimension(:) :: irowno
26 integer,
dimension(:) :: jstat
27 integer i,j,k,l, locr, loc
32 if(irowno(loc).eq.i)
then
34 elseif(irowno(loc).gt.i)
then
65 type (ccls_matrix) :: c
69 else if (0 >= c%ndeg)
then
71 else if (0 >= c%nttbr)
then
75 allocate(c%ia(c%ncol+1))
76 allocate(c%ja(c%nttbr))
77 allocate(c%val(c%ndeg*c%ndeg,c%nttbr))
82 subroutine stiajac(c,jstat,irpt,irowno)
85 type (ccls_matrix) :: c
87 integer,
dimension(:) :: jstat
88 integer,
dimension(:) :: irpt
89 integer,
dimension(:) :: irowno
90 integer i,j,k,l, ii, loc, idbg
92 if (0 >= c%neqns)
then
94 else if (0 >= c%ncol)
then
96 else if (0 >= c%nttbr)
then
98 else if (.false. ==
associated(c%ia))
then
100 else if (.false. ==
associated(c%ja))
then
102 else if (c%ncol+1 /=
size(c%ia))
then
104 else if (c%nttbr /=
size(c%ja))
then
106 else if ((c%ndeg*c%ndeg /=
size(c%val, dim=1)) .or. (c%nttbr /=
size(c%val, dim=2)))
then
116 if(loc.eq.0)
goto 120
126 write(20,60) (c%ia(i),i=1,c%ncol+1)
128 write(20,60) (c%ja(i),i=1,c%ja(c%ncol+1))
134 subroutine stval(c,i,j,val,itrans)
138 type (ccls_matrix) :: c
139 real(8),
dimension(c%ndeg*c%ndeg) :: val
145 do k=c%ia(j),c%ia(j+1)-1
146 if(i.eq.c%ja(k))
then
152 c%val(m + (n-1)*ndeg,k)=val((m-1)*ndeg + n)
159 write(6,*)
"something wrong"
166 type (ccls_matrix),
intent(in) :: c
167 integer,
intent(in) :: k
169 real(8),
dimension(:),
intent(out) :: v
171 integer ndeg, nndeg, i, idx, jcol, iofset
176 jcol = (k+ndeg-1) / ndeg
177 iofset = mod(k+ndeg-1, ndeg)
179 do i=c%ia(jcol),c%ia(jcol+1)-1
181 v(ndeg*(idx-1)+1:ndeg*(idx-1)+ndeg) &
182 & =c%val(ndeg*iofset + 1 : ndeg*iofset + ndeg ,i)
190 write(*,*)
'Error in m_cclsmatrix: ', mes