Library/ManagedCuda/CudaBlas/CudaBlasHandler.cs
/// <summary>
/// This function performs the matrix-vector multiplication y = alpha * Op(A) * x + beta * y where A is a m*n matrix stored in column-major format, 
/// x and y are vectors, and alpha and beta are scalars.
/// </summary>
/// <param name="trans">operation op(A) that is non- or (conj.) transpose.</param>
/// <param name="m">number of rows of matrix A.</param>
/// <param name="n">number of columns of matrix A.</param>
/// <param name="alpha">scalar used for multiplication.</param>
/// <param name="A">array of dimensions lda * n, with lda >= max(1,n).</param>
/// <param name="lda">leading dimension of two-dimensional array used to store matrix A.</param>
/// <param name="x">vector with n elements.</param>
/// <param name="incx">stride between consecutive elements of x.</param>
/// <param name="beta">scalar used for multiplication, if beta==0 then y does not have to be a valid input.</param>
/// <param name="y">vector with n elements.</param>
/// <param name="incy">stride between consecutive elements of y.</param>
This function performs the matrix-vector multiplication y = alpha * Op(A) * x + beta * y where A is a m*n matrix stored in column-major format,
x and y are vectors, and alpha and beta are scalars.
This function performs the matrix - vector multiplication y = alpha * Op ( A ) * x + beta * y where A is a m * n matrix stored in column - major format x and y are vectors and alpha and beta are scalars .
public void Gemv(Operation trans, int m, int n, CudaDeviceVariable<cuDoubleComplex> alpha, CudaDeviceVariable<cuDoubleComplex> A, int lda, CudaDeviceVariable<cuDoubleComplex> x, int incx, CudaDeviceVariable<cuDoubleComplex> beta, CudaDeviceVariable<cuDoubleComplex> y, int incy)
		{
			_status = CudaBlasNativeMethods.cublasZgemv_v2(_blasHandle, trans, m, n, alpha.DevicePointer, A.DevicePointer, lda, x.DevicePointer, incx, beta.DevicePointer, y.DevicePointer, incy);
			Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "cublasZgemv_v2", _status));
			if (_status != CublasStatus.Success) throw new CudaBlasException(_status);
		}
public void Gemv ( Operation trans , int m , int n , CudaDeviceVariable < cuDoubleComplex > alpha , CudaDeviceVariable < cuDoubleComplex > A , int lda , CudaDeviceVariable < cuDoubleComplex > x , int incx , CudaDeviceVariable < cuDoubleComplex > beta , CudaDeviceVariable < cuDoubleComplex > y , int incy ) { _status = CudaBlasNativeMethods . cublasZgemv_v2 ( _blasHandle , trans , m , n , alpha . DevicePointer , A . DevicePointer , lda , x . DevicePointer , incx , beta . DevicePointer , y . DevicePointer , incy ) ; Debug . WriteLine ( String . Format ( " " , DateTime . Now , " " , _status ) ) ; if ( _status != CublasStatus . Success ) throw new CudaBlasException ( _status ) ; }
This function performs the matrix-vector multiplication y = alpha * Op(A) * x + beta * y where A is a m*n matrix stored in column-major format,
x and y are vectors, and alpha and beta are scalars.
This function performs the matrix - vector multiplication y = alpha * Op ( A ) * x + beta * y where A is a m * n matrix stored in column - major format x and y are vectors and alpha and beta are scalars .
trans
Operation
operation op(A) that is non- or (conj.) transpose.
operation op ( A ) that is non - or ( conj . ) transpose .
m
int
number of rows of matrix A.
number of rows of matrix A .
n
int
number of columns of matrix A.
number of columns of matrix A .
alpha
CudaDeviceVariable<cuDoubleComplex>
scalar used for multiplication.
scalar used for multiplication .
A
CudaDeviceVariable<cuDoubleComplex>
array of dimensions lda * n, with lda >= max(1,n).
array of dimensions lda * n with lda > = max ( 1 n ) .
lda
int
leading dimension of two-dimensional array used to store matrix A.
leading dimension of two - dimensional array used to store matrix A .
x
CudaDeviceVariable<cuDoubleComplex>
vector with n elements.
vector with n elements .
incx
int
stride between consecutive elements of x.
stride between consecutive elements of x .
beta
CudaDeviceVariable<cuDoubleComplex>
scalar used for multiplication, if beta==0 then y does not have to be a valid input.
scalar used for multiplication if beta == 0 then y does not have to be a valid input .
y
CudaDeviceVariable<cuDoubleComplex>
vector with n elements.
vector with n elements .
incy
int
stride between consecutive elements of y.
stride between consecutive elements of y .