Library/ManagedCuda/CudaSolve/Refactorization.cs
/// <summary>
/// This routine allows direct access to the lower L and upper U triangular factors stored in
/// the cuSolverRF library handle. The factors are compressed into a single matrix M=(LI)+
/// U, where the unitary diagonal of L is not stored. It is assumed that a prior call to the
/// cusolverRfRefactor() was done in order to generate these triangular factors.
/// </summary>
/// <param name="nnzM">the number of non-zero elements of matrix M.</param>
/// <param name="Mp">the array of offsets corresponding to the start of each row in the arrays Mi and Mx.
/// This array has also an extra entry at the end that stores the number of non-zero elements in the matrix $M$. The array size is n+1.</param>
/// <param name="Mi">the array of column indices corresponding to the non-zero elements in the matrix M. It is assumed that this array is sorted by row and by column within each row. The array size is nnzM.</param>
/// <param name="Mx">the array of values corresponding to the non-zero elements in the matrix M. It is assumed that this array is sorted by row and by column within each row. The array size is nnzM.</param>
This routine allows direct access to the lower L and upper U triangular factors stored in
the cuSolverRF library handle. The factors are compressed into a single matrix M=(LI)+
U, where the unitary diagonal of L is not stored. It is assumed that a prior call to the
cusolverRfRefactor() was done in order to generate these triangular factors.
This routine allows direct access to the lower L and upper U triangular factors stored in the cuSolverRF library handle . The factors are compressed into a single matrix M = ( LI ) + U where the unitary diagonal of L is not stored . It is assumed that a prior call to the cusolverRfRefactor () was done in order to generate these triangular factors .
public void AccessBundledFactorsDevice(out int nnzM, out CudaDeviceVariable<int> Mp, out CudaDeviceVariable<int> Mi, out CudaDeviceVariable<double> Mx)
		{
			CUdeviceptr d_mp = new CUdeviceptr();
			CUdeviceptr d_mi = new CUdeviceptr();
			CUdeviceptr d_mx = new CUdeviceptr();
			nnzM = 0;
			res = CudaSolveNativeMethods.Refactorization.cusolverRfAccessBundledFactorsDevice(_handle, ref nnzM, ref d_mp, ref d_mi, ref d_mx);
			Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "cusolverRfAccessBundledFactorsDevice", res));
			if (res != cusolverStatus.Success) throw new CudaSolveException(res);
			Mp = new CudaDeviceVariable<int>(d_mp);
			Mi = new CudaDeviceVariable<int>(d_mi);
			Mx = new CudaDeviceVariable<double>(d_mx);
		}
public void AccessBundledFactorsDevice ( out int nnzM , out CudaDeviceVariable < int > Mp , out CudaDeviceVariable < int > Mi , out CudaDeviceVariable < double > Mx ) { CUdeviceptr d_mp = new CUdeviceptr ( ) ; CUdeviceptr d_mi = new CUdeviceptr ( ) ; CUdeviceptr d_mx = new CUdeviceptr ( ) ; nnzM = 0 ; res = CudaSolveNativeMethods . Refactorization . cusolverRfAccessBundledFactorsDevice ( _handle , ref nnzM , ref d_mp , ref d_mi , ref d_mx ) ; Debug . WriteLine ( String . Format ( " " , DateTime . Now , " " , res ) ) ; if ( res != cusolverStatus . Success ) throw new CudaSolveException ( res ) ; Mp = new CudaDeviceVariable < int > ( d_mp ) ; Mi = new CudaDeviceVariable < int > ( d_mi ) ; Mx = new CudaDeviceVariable < double > ( d_mx ) ; }
This routine allows direct access to the lower L and upper U triangular factors stored in
the cuSolverRF library handle.
This routine allows direct access to the lower L and upper U triangular factors stored in the cuSolverRF library handle .
int
out
CudaDeviceVariable<int>
out
CudaDeviceVariable<double>
out
nnzM
the number of non-zero elements of matrix M.
the number of non - zero elements of matrix M .
Mp
the array of offsets corresponding to the start of each row in the arrays Mi and Mx.
This array has also an extra entry at the end that stores the number of non-zero elements in the matrix $M$. The array size is n+1.
the array of offsets corresponding to the start of each row in the arrays Mi and Mx . This array has also an extra entry at the end that stores the number of non - zero elements in the matrix $M$ . The array size is n + 1 .
Mi
the array of column indices corresponding to the non-zero elements in the matrix M. It is assumed that this array is sorted by row and by column within each row. The array size is nnzM.
the array of column indices corresponding to the non - zero elements in the matrix M . It is assumed that this array is sorted by row and by column within each row . The array size is nnzM .
Mx
the array of values corresponding to the non-zero elements in the matrix M. It is assumed that this array is sorted by row and by column within each row. The array size is nnzM.
the array of values corresponding to the non - zero elements in the matrix M . It is assumed that this array is sorted by row and by column within each row . The array size is nnzM .