Rev 6098 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed
cc zsisl solves the double complex symmetric systemc a * x = bc using the factors computed by zsifa.cc on entrycc a double complex(lda,n)c the output from zsifa.cc lda integerc the leading dimension of the array a .cc n integerc the order of the matrix a .cc kpvt integer(n)c the pivot vector from zsifa.cc b double complex(n)c the right hand side vector.cc on returncc b the solution vector x .cc error conditioncc a division by zero may occur if zsico has set rcond .eq. 0.0c or zsifa has set info .ne. 0 .cc to compute inverse(a) * c where c is a matrixc with p columnsc call zsifa(a,lda,n,kpvt,info)c if (info .ne. 0) go to ...c do 10 j = 1, pc call zsisl(a,lda,n,kpvt,c(1,j))c 10 continuecc linpack. this version dated 08/14/78 .c james bunch, univ. calif. san diego, argonne nat. lab.cc subroutines and functionscc blas zaxpy,zdotuc fortran iabscsubroutine zsisl(a,lda,n,kpvt,b)integer lda,n,kpvt(*)double complex a(lda,*),b(*)cc internal variables.cdouble complex ak,akm1,bk,bkm1,zdotu,denom,tempinteger k,kpcc loop backward applying the transformations andc d inverse to b.ck = n10 if (k .eq. 0) go to 80if (kpvt(k) .lt. 0) go to 40cc 1 x 1 pivot block.cif (k .eq. 1) go to 30kp = kpvt(k)if (kp .eq. k) go to 20cc interchange.ctemp = b(k)b(k) = b(kp)b(kp) = temp20 continuecc apply the transformation.ccall zaxpy(k-1,b(k),a(1,k),1,b(1),1)30 continuecc apply d inverse.cb(k) = b(k)/a(k,k)k = k - 1go to 7040 continuecc 2 x 2 pivot block.cif (k .eq. 2) go to 60kp = iabs(kpvt(k))if (kp .eq. k - 1) go to 50cc interchange.ctemp = b(k-1)b(k-1) = b(kp)b(kp) = temp50 continuecc apply the transformation.ccall zaxpy(k-2,b(k),a(1,k),1,b(1),1)call zaxpy(k-2,b(k-1),a(1,k-1),1,b(1),1)60 continuecc apply d inverse.cak = a(k,k)/a(k-1,k)akm1 = a(k-1,k-1)/a(k-1,k)bk = b(k)/a(k-1,k)bkm1 = b(k-1)/a(k-1,k)denom = ak*akm1 - 1.0d0b(k) = (akm1*bk - bkm1)/denomb(k-1) = (ak*bkm1 - bk)/denomk = k - 270 continuego to 1080 continuecc loop forward applying the transformations.ck = 190 if (k .gt. n) go to 160if (kpvt(k) .lt. 0) go to 120cc 1 x 1 pivot block.cif (k .eq. 1) go to 110cc apply the transformation.cb(k) = b(k) + zdotu(k-1,a(1,k),1,b(1),1)kp = kpvt(k)if (kp .eq. k) go to 100cc interchange.ctemp = b(k)b(k) = b(kp)b(kp) = temp100 continue110 continuek = k + 1go to 150120 continuecc 2 x 2 pivot block.cif (k .eq. 1) go to 140cc apply the transformation.cb(k) = b(k) + zdotu(k-1,a(1,k),1,b(1),1)b(k+1) = b(k+1) + zdotu(k-1,a(1,k+1),1,b(1),1)kp = iabs(kpvt(k))if (kp .eq. k) go to 130cc interchange.ctemp = b(k)b(k) = b(kp)b(kp) = temp130 continue140 continuek = k + 2150 continuego to 90160 continuereturnend