lebedov / scikit-cuda

Python interface to GPU-powered libraries
http://scikit-cuda.readthedocs.org/
Other
986 stars 179 forks source link

skcuda.linalg.eig - return eigenvector, index issue ? #317

Open perdigao1 opened 3 years ago

perdigao1 commented 3 years ago

Problem

I am trying to solve the 2D schrodinger equation using the eigenvector and eigenvalue solver skcuda.linalg.eig

In the instructions here

it says that

vr_gpu (pycuda.gpuarray.GPUArray) – The normalized (Euclidean norm equal to 1) right eigenvectors, such that the column vr[:,i] is the eigenvector corresponding to the eigenvalue w[i].

However, I am only getting sensible results if I extract the eigenvectors if I assume them to be vr[i,:].

It may be a simply that the help assumes column-major order, but in practise, user should get the vectors by doing vr[i,:] , which can be confusing.

Environment