Hello. I've written a sage program which produces a complex matrix. I
want to find the eigenvalues and associated eigenvectors. I also want
to use arbitrary precision. I don't care about speed. I've read old
posts to this group on this topic, but am unsure how to proceed.
Currently I'm using the following method and using sage 4.6.1

precision_digits=30
nop=5 # rank of matrix
MS_nop_comp=MatrixSpace(ComplexField(precision_digits),nop,nop)
tmat=MS_nop_comp(0) # zero-ize the values
ttdag=MS_nop_comp(0)

# I realize there are more efficient methods of getting a random
matrix, but this is explicit
for a in range(nop):
  for b in range(nop):
    tmat[a,b]=random()+I*random()

ttdag=tmat*tmat.conjugate().transpose() # get a Hermitian matrix
print 'ttdag is'
print ttdag
print 'eigenvalues of ttdag are '
print ttdag.eigenvalues() # eigenvalues of Hermitian matrix should be
real. Imaginary component is due to finite precision.
# I can get better precision here by increasing precision_digits

#print ttdag.eigenmatrix_right()
# IndexError: list index out of range

print ttdag.eigenvectors_right()
# this is not returning the eigenvectors, even when precision is
increased to 500

How can I find the eigenvectors of a complex Hermitian matrix with
arbitrary precision?

Thanks,

-- 
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to