( 0.20-0.11i -0.93-0.32i -0.80-0.92i )
A = ( -0.93-0.32i 0.81+0.37i -0.29+0.86i )
( -0.80-0.92i -0.29+0.86i 0.64+0.51i )
Sub Ex_Zsptri()
Const N = 3
Dim Ap(N * (N + 1) / 2) As Complex, IPiv(N - 1) As Long, Info As Long
Ap(0) = Cmplx(0.2, -0.11)
Ap(1) = Cmplx(-0.93, -0.32): Ap(3) = Cmplx(0.81, 0.37)
Ap(2) = Cmplx(-0.8, -0.92): Ap(4) = Cmplx(-0.29, 0.86): Ap(5) = Cmplx(0.64, 0.51)
Call Zsptrf("L", N, Ap(), IPiv(), Info)
If Info = 0 Then Call Zsptri("L", N, Ap(), IPiv(), Info)
Debug.Print "Inv(A) ="
Debug.Print Creal(Ap(0)), Cimag(Ap(0))
Debug.Print Creal(Ap(1)), Cimag(Ap(1)), Creal(Ap(3)), Cimag(Ap(3))
Debug.Print Creal(Ap(2)), Cimag(Ap(2)), Creal(Ap(4)), Cimag(Ap(4))
Debug.Print Creal(Ap(5)), Cimag(Ap(5))
Debug.Print "Info =", Info
End Sub