private void Check(SparseStatus status) { if (status != SparseStatus.Success) { throw new CuSparseException(status); } }
/// <summary> /// Initializes a new instance of the <see cref="ExtendedEigensolverResult{T}"/> class. /// </summary> /// <param name="info">The status returned by MKL extended eigensolver.</param> /// <param name="size">The matrix size.</param> /// <param name="k">The number of eigenvalues found (k < k0).</param> /// <param name="e">Array of length k0. The first k entries of e are eigenvalues found in the interval.</param> /// <param name="x">Matrix with k0 columns containing the orthonormal eigenvectors corresponding to the /// computed eigenvalues e, with the i-th column of x holding the eigenvector associated with e[i].</param> /// <param name="r">Array of length k0 containing the relative residual vector (in the first k components).</param> public ExtendedEigensolverResult(SparseStatus info, int size, int k, double[] e, Matrix <T> x, double[] r) { this.size = size; Status = info; ConvergedEigenValues = k; Residuals = r; }
/// <summary> /// Initializes a new instance of the <see cref="CuSparseException"/> class. /// </summary> /// <param name="status"></param> public CuSparseException(SparseStatus status) { Status = status; }
/// <inheritdoc /> public ExtendedEigensolverResult(SparseStatus info, int size, int k, double[] e, Matrix <double> x, double[] r) : base(info, size, k, e, x, r) { eigenvalues = e; eigenvectors = x; }