Пример #1
0
        internal spectra_spmat GetMatrix(CompressedColumnStorage <T> matrix, List <GCHandle> handles)
        {
            spectra_spmat a = default(spectra_spmat);

            a.n   = size;
            a.p   = InteropHelper.Pin(matrix.ColumnPointers, handles);
            a.i   = InteropHelper.Pin(matrix.RowIndices, handles);
            a.x   = InteropHelper.Pin(matrix.Values, handles);
            a.nnz = matrix.NonZerosCount;

            return(a);
        }
Пример #2
0
 public static extern int spectra_di_sg_shift(int which, char mode, int k, int ncv, int maxit, double tol, double sigma,
                                              ref spectra_spmat A, ref spectra_spmat B, ref spectra_result eigs);
Пример #3
0
 public static extern int spectra_di_sg(int which, int k, int ncv, int maxit, double tol,
                                        ref spectra_spmat A, ref spectra_spmat B, ref spectra_result eigs);