BLAS Reference
| Framework | Accelerate/Accelerate.h |
| Declared in | cblas.h |
Overview
The vecLib framework contains nine C header files (not counting vecLib.h which merely includes the others).
This document describes the functions declared in the header files cblas.h and vblas.h, which contain the interfaces for Apple’s implementation of the Basic Linear Algebra Subprograms (BLAS) API.
For More Information
Documentation on the BLAS standard, including reference implementations, can be found on the web starting from the BLAS FAQ page at these URLs (verified live as of July 2005): http://www.netlib.org/blas/faq.html and http://www.netlib.org/blas/blast-forum/blast-forum.html
Functions by Task
General Functions
-
ATLU_DestroyThreadMemory -
SetBLASParamErrorProc -
cblas_errprn -
cblas_xerbla -
cblas_icamax -
cblas_idamax -
cblas_isamax -
cblas_izamax
CATLAS and CBLAS Vector Functions
-
catlas_caxpby -
catlas_cset -
catlas_daxpby -
catlas_dset -
catlas_saxpby -
catlas_sset -
catlas_zaxpby -
catlas_zset -
cblas_sdot -
cblas_sdsdot -
cblas_cdotc_sub -
cblas_cdotu_sub -
cblas_ddot -
cblas_dsdot -
cblas_zdotc_sub -
cblas_zdotu_sub
Single-Precision Float Matrix Functions
-
cblas_sasum -
cblas_saxpy -
cblas_scopy -
cblas_sgbmv -
cblas_sgemm -
cblas_sgemv -
cblas_sger -
cblas_snrm2 -
cblas_srot -
cblas_srotg -
cblas_srotm -
cblas_srotmg -
cblas_ssbmv -
cblas_sscal -
cblas_sspmv -
cblas_sspr -
cblas_sspr2 -
cblas_sswap -
cblas_ssymm -
cblas_ssymv -
cblas_ssyr -
cblas_ssyr2 -
cblas_ssyr2k -
cblas_ssyrk -
cblas_stbmv -
cblas_stbsv -
cblas_stpmv -
cblas_stpsv -
cblas_strmm -
cblas_strmv -
cblas_strsm -
cblas_strsv
Single-Precision Complex Matrix Functions
-
cblas_caxpy -
cblas_ccopy -
cblas_cgbmv -
cblas_cgemm -
cblas_cgemv -
cblas_cgerc -
cblas_cgeru -
cblas_chbmv -
cblas_chemm -
cblas_chemv -
cblas_cher -
cblas_cher2 -
cblas_cher2k -
cblas_cherk -
cblas_chpmv -
cblas_chpr -
cblas_chpr2 -
cblas_crotg -
cblas_cscal -
cblas_csrot -
cblas_csscal -
cblas_cswap -
cblas_csymm -
cblas_csyr2k -
cblas_csyrk -
cblas_ctbmv -
cblas_ctbsv -
cblas_ctpmv -
cblas_ctpsv -
cblas_ctrmm -
cblas_ctrmv -
cblas_ctrsm -
cblas_ctrsv -
cblas_scasum -
cblas_scnrm2
Double-Precision Float Matrix Functions
-
cblas_dasum -
cblas_daxpy -
cblas_dcopy -
cblas_dgbmv -
cblas_dgemm -
cblas_dgemv -
cblas_dger -
cblas_dnrm2 -
cblas_drot -
cblas_drotg -
cblas_drotm -
cblas_drotmg -
cblas_dsbmv -
cblas_dscal -
cblas_dspmv -
cblas_dspr -
cblas_dspr2 -
cblas_dswap -
cblas_dsymm -
cblas_dsymv -
cblas_dsyr -
cblas_dsyr2 -
cblas_dsyr2k -
cblas_dsyrk -
cblas_dtbmv -
cblas_dtbsv -
cblas_dtpmv -
cblas_dtpsv -
cblas_dtrmm -
cblas_dtrmv -
cblas_dtrsm -
cblas_dtrsv
Double-Precision Complex Matrix Functions
-
cblas_dzasum -
cblas_dznrm2 -
cblas_zaxpy -
cblas_zcopy -
cblas_zdrot -
cblas_zdscal -
cblas_zgbmv -
cblas_zgemm -
cblas_zgemv -
cblas_zgerc -
cblas_zgeru -
cblas_zhbmv -
cblas_zhemm -
cblas_zhemv -
cblas_zher -
cblas_zher2 -
cblas_zher2k -
cblas_zherk -
cblas_zhpmv -
cblas_zhpr -
cblas_zhpr2 -
cblas_zrotg -
cblas_zscal -
cblas_zswap -
cblas_zsymm -
cblas_zsyr2k -
cblas_zsyrk -
cblas_ztbmv -
cblas_ztbsv -
cblas_ztpmv -
cblas_ztpsv -
cblas_ztrmm -
cblas_ztrmv -
cblas_ztrsm -
cblas_ztrsv
Functions
ATLU_DestroyThreadMemory
Releases per-thread storage associated with BLAS.
void ATLU_DestroyThreadMemory ( void );
Discussion
Many BLAS functions parallelize computation to obtain performance from multiple CPU cores. These functions allocate thread memory. Call this function when you no longer need to call BLAS functions.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_caxpby
Computes the product of two vectors, scaling each one separately (single-precision complex).
void catlas_caxpby ( const int N, const void *alpha, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- N
Number of elements in the vector.
- alpha
Scaling factor for
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for Y.
- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_cset
Modifies a vector (single-precision complex) in place, setting each element to a given value.
void catlas_cset ( const int N, const void *alpha, void *X, const int incX );
Parameters
- N
The number of elements in the vector.
- alpha
The new value.
- X
The vector to modify.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_daxpby
Computes the product of two vectors, scaling each one separately (double-precision).
void catlas_daxpby ( const int N, const double alpha, const double *X, const int incX, const double beta, double *Y, const int incY );
Parameters
- N
Number of elements in the vector.
- alpha
Scaling factor for
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for Y.
- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_dset
Modifies a vector (double-precision) in place, setting each element to a given value.
void catlas_dset ( const int N, const double alpha, double *X, const int incX );
Parameters
- N
The number of elements in the vector.
- alpha
The new value.
- X
The vector to modify.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_saxpby
Scales the two input vectors separately, then adds the input vectors (single-precision).
void catlas_saxpby ( const int N, const float alpha, const float *X, const int incX, const float beta, float *Y, const int incY );
Parameters
- N
Number of elements in the vector.
- alpha
Scaling factor for
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for Y.
- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result.
This function performs the following operation:
Y = (alpha * X) + (beta * Y) |
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_sset
Modifies a vector (single-precision) in place, setting each element to a given value.
void catlas_sset ( const int N, const float alpha, float *X, const int incX );
Parameters
- N
The number of elements in the vector.
- alpha
The new value.
- X
The vector to modify.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_zaxpby
Computes the product of two vectors, scaling each one separately (double-precision complex).
void catlas_zaxpby ( const int N, const void *alpha, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- N
Number of elements in the vector.
- alpha
Scaling factor for
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for Y.
- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcatlas_zset
Modifies a vector (double-precision complex) in place, setting each element to a given value.
void catlas_zset ( const int N, const void *alpha, void *X, const int incX );
Parameters
- N
The number of elements in the vector.
- alpha
The new value.
- X
The vector to modify.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_caxpy
Computes a constant times a vector plus a vector (single-precision complex).
void cblas_caxpy ( const int N, const void *alpha, const void *X, const int incX, void *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- alpha
Scaling factor for the values in
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result. The value computed is (alpha * X[i]) + Y[i].
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ccopy
Copies a vector to another vector (single-precision complex).
void cblas_ccopy ( const int N, const void *X, const int incX, void *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- X
Source vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Destination vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cdotc_sub
Calculates the dot product of the complex conjugate of a single-precision complex vector with a second single-precision complex vector.
void cblas_cdotc_sub ( const int N, const void *X, const int incX, const void *Y, const int incY, void *dotc );
Parameters
- N
Number of elements in vectors
XandY.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- dotc
The result vector.
Discussion
Computes conjg(X) * Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cdotu_sub
Computes the dot product of two single-precision complex vectors.
void cblas_cdotu_sub ( const int N, const void *X, const int incX, const void *Y, const int incY, void *dotu );
Parameters
- N
The length of vectors
XandY.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- dotu
The result vector.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cgbmv
Scales a general band matrix, then multiplies by a vector, then adds a vector (single-precision complex).
void cblas_cgbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const int KL, const int KU, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- M
Number of rows in matrix A.
- N
Number of columns in matrix A.
- KL
Number of subdiagonals in matrix A.
- KU
Number of superdiagonals in matrix A.
- alpha
Scaling factor to multiply matrix
Aby.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A. (Must be at leastKL+KU+1.)- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor to multiply vector Y by.
- Y
Vector Y.
- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y, alpha*A'*x + beta*y, or alpha*conjg(A')*x + beta*y depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cgemm
Multiplies two matrices (single-precision complex).
void cblas_cgemm ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const int M, const int N, const int K, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- TransB
Specifies whether to transpose matrix
B.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- K
Number of columns in matrix
A; number of rows in matrixB.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
with optional use of transposed forms of A, B, or both.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cgemv
Multiplies a matrix by a vector (single-precision complex).
void cblas_cgemv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for the product of matrix
Aand vectorX.- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- X
Vector X.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
Y.- Y
Vector Y
- incY
Stride within Y. For example, if incY is 7, every 7th element is used.
Discussion
This function multiplies A * X (after transposing A, if needed) and multiplies the resulting matrix by alpha. It then multiplies vector Y by beta. It stores the sum of these two products in vector Y.
Thus, it calculates either
Y←αAX + βY
with optional use of the transposed form of A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cgerc
Multiplies vector X by the conjugate transform of vector Y, then adds matrix A (single-precision complex).
void cblas_cgerc ( const enum CBLAS_ORDER Order, const int M, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Computes alpha*x*conjg(y') + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cgeru
Multiplies vector X by the transform of vector Y, then adds matrix A (single-precision complex).
void cblas_cgeru ( const enum CBLAS_ORDER Order, const int M, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Computes alpha*x*y' + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_chbmv
Scales a Hermitian band matrix, then multiplies by a vector, then adds a vector (single-precision complex).
void cblas_chbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const int K, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- alpha
Scaling value to multiply matrix A by.
- A
Matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
Yis multiplied by.- Y
Vector
Y. Replaced by results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and returns the results in vector Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_chemm
Multiplies two Hermitian matrices (single-precision complex), then adds a third (with scaling).
void cblas_chemm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const int M, const int N, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- M
The number of rows in matrices
AandC.- N
The number of columns in matrices
BandC.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B or B * A (depending on the value of Side) and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
where
A = AH
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_chemv
Scales and multiplies a Hermitian matrix by a vector, then adds a second (scaled) vector.
void cblas_chemv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
X.- Y
Vector
Y. Overwritten by results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Calculates Y←αAX + βY.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cher
Hermitian rank 1 update: adds the product of a scaling factor, vector X, and the conjugate transpose of X to matrix A.
void cblas_cher ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const void *X, const int incX, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- alpha
The scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of matrix
A.
Discussion
Computes A←αX*conjg(X') + βA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cher2
Hermitian rank 2 update: adds the product of a scaling factor, vector X, and the conjugate transpose of vector Y to the product of the conjugate of the scaling factor, vector Y, and the conjugate transpose of vector X, and adds the result to matrix A.
void cblas_cher2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- alpha
The scaling factor
α.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
The leading dimension of matrix
A.
Discussion
Computes A←αX*conjg(Y') + conjg(α)*Y*conjg(X') + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cher2k
Performs a rank-2k update of a complex Hermitian matrix (single-precision complex).
void cblas_cher2k ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const float beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- N
Order of matrix
C.- K
Specifies the number of columns in matrices
AandBiftrans='N'.Specifies the number of rows if
trans='C'ortrans='T').- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- B
Matrix
B.- ldb
Leading dimension of array containing matrix
B.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Computes alpha*A*BH + alpha*B*AH +beta*C
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cherk
Rank-k update—multiplies a Hermitian matrix by its transpose and adds a second matrix (single precision).
void cblas_cherk ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const float alpha, const void *A, const int lda, const float beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n') or the conjugate transpose of A ('C'or'c').- N
Order of matrix
C.- K
Number of columns in matrix
A(or number of rows if matrixAis transposed).- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Calculates alpha*A*AH + beta*C; if transposed, calculates alpha*AH*A + beta*C.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_chpmv
Scales a packed hermitian matrix, multiplies it by a vector, and adds a scaled vector.
void cblas_chpmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *Ap, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorsxandy.- alpha
Scaling factor that matrix
Ais multiplied by.- Ap
Matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
yis multiplied by.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and stores the results in Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_chpr
Scales and multiplies a vector times its conjugate transpose, then adds a matrix.
void cblas_chpr ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const void *X, const int incX, void *A );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorx.- alpha
Scaling factor that vector
xis multiplied by.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- A
Matrix
A. Overwritten by results on return.
Discussion
Calculates alpha*x*conjg(x') + A and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_chpr2
Multiplies a vector times the conjugate transpose of a second vector and vice-versa, sums the results, and adds a matrix.
void cblas_chpr2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *Ap );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorsxandy.- alpha
Scaling factor that vector
xis multiplied by.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- Ap
Matrix
Ain packed storage format. Overwritten by the results on return.
Discussion
Calcuates alpha*x*conjg(y') + conjg(alpha)*y*conjg(x') + A, and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_crotg
Constructs a complex Givens rotation.
void cblas_crotg ( void *a, void *b, void *c, void *s );
Parameters
- a
Complex value
a. Overwritten on output.- b
Complex value
a.- c
Real value
c. Unused on entry. Overwritten on return with the valuecos(θ).- s
Complex value
s. Unused on entry. Overwritten on return with the valuesin(θ).
Discussion
Given a vertical matrix containing a and b, computes the values of cos θ and sin θ that zero the lower value (b). Returns the value of sin θ in s, the value of cos θ in c, and the upper value (r) in a.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cscal
Multiplies each element of a vector by a constant (single-precision complex).
void cblas_cscal ( const int N, const void *alpha, void *X, const int incX );
Parameters
- N
The number of elements in the vector.
- alpha
The constant scaling factor.
- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_csrot
Applies a Givens rotation matrix to a pair of complex vectors.
void cblas_csrot ( const int N, void *X, const int incX, void *Y, const int incY, const float c, const float s );
Parameters
- N
The number of elements in vectors
XandY.- X
Vector
X. Modified on return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y. Modified on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- c
The value
cos(θ)in the Givens rotation matrix.- s
The value
sin(θ)in the Givens rotation matrix.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_csscal
Multiplies each element of a vector by a constant (single-precision complex).
void cblas_csscal ( const int N, const float alpha, void *X, const int incX );
Parameters
- N
The number of elements in vector
x.- alpha
The constant scaling factor.
- X
Vector X.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_cswap
Exchanges the elements of two vectors (single-precision complex).
void cblas_cswap ( const int N, void *X, const int incX, void *Y, const int incY );
Parameters
- N
Number of elements in vectors
- X
Vector
x. On return, contains elements copied from vectory.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y. On return, contains elements copied from vectorx.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_csymm
Multiplies a matrix by a symmetric matrix (single-precision complex).
void cblas_csymm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const int M, const int N, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B or B * A (depending on the value of Side) and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
where
A = AT
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_csyr2k
Performs a rank-2k update of a symmetric matrix (single-precision complex).
void cblas_csyr2k ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- N
Order of matrix
C.- K
Specifies the number of columns in matrices
AandBiftrans='N'.Specifies the number of rows if
trans='C'ortrans='T').- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- B
Matrix
B.- ldb
Leading dimension of array containing matrix
B.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Computes alpha*A*BT + alpha*B*AT +beta*C
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_csyrk
Rank-k update—multiplies a symmetric matrix by its transpose and adds a second matrix (single-precision complex).
void cblas_csyrk ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const void *alpha, const void *A, const int lda, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T'or't').- N
Order of matrix
C.- K
Number of columns in matrix
A(or number of rows if matrixAis transposed).- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Calculates alpha*A*AT + beta*C; if transposed, calculates alpha*AT*A + beta*C.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctbmv
Scales a triangular band matrix, then multiplies by a vector (single-precision compex).
void cblas_ctbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- A
Matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x and stores the results in x.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctbsv
Solves a triangular banded system of equations.
void cblas_ctbsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- K
Number of superdiagonals or subdiagonals of matrix
A(depending on the value ofUplo).- A
Matrix
A.- lda
The leading dimension of matrix
A.- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctpmv
Multiplies a triangular matrix by a vector, then adds a vector (single-precision complex).
void cblas_ctpmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *Ap, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
Aand the number of elements in vectorsxandy.- Ap
Matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x, AT*x, or conjg(AT)*x and stores the results in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctpsv
Solves a packed triangular system of equations.
void cblas_ctpsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *Ap, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- Ap
Matrix
A(in packed storage format).- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctrmm
Scales a triangular matrix and multiplies it by a matrix.
void cblas_ctrmm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const void *alpha, const void *A, const int lda, void *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
Number of rows in matrix
B.- N
Number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- B
Matrix
B. Overwritten by results on return.- ldb
Leading dimension of matrix
B.
Discussion
If Side is 'L', multiplies alpha*A*B or alpha*A'*B, depending on TransA.
If Side is 'R', multiplies alpha*B*A or alpha*B*A', depending on TransA.
In either case, the results are stored in matrix B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctrmv
Multiplies a triangular matrix by a vector.
void cblas_ctrmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Multiplies A*X or A'*X, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctrsm
Solves a triangular system of equations with multiple values for the right side.
void cblas_ctrsm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const void *alpha, const void *A, const int lda, void *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrix and vector should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
The number of rows in matrix
B.- N
The number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- B
On entry, matrix
B. Overwritten on return by matrixX.- ldb
The leading dimension of matrix
B.
Discussion
If Side is 'L', solves A*X=alpha*B or A'*X=alpha*B, depending on TransA.
If Side is 'R', solves X*A=alpha*B or X*A'=alpha*B, depending on TransA.
In either case, the results overwrite the values of matrix B in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ctrsv
Solves a triangular system of equations with a single value for the right side.
void cblas_ctrsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- X
The vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves A*x=b or A'*x=b where x and b are elements in X and B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dasum
Computes the sum of the absolute values of elements in a vector (double-precision).
double cblas_dasum ( const int N, const double *X, const int incX );
Parameters
- N
The number of elements in vector
x.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Return Value
Returns the sum.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_daxpy
Computes a constant times a vector plus a vector (double-precision).
void cblas_daxpy ( const int N, const double alpha, const double *X, const int incX, double *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- alpha
Scaling factor for the values in
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result. The value computed is (alpha * X[i]) + Y[i].
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dcopy
Copies a vector to another vector (double-precision).
void cblas_dcopy ( const int N, const double *X, const int incX, double *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- X
Source vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Destination vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ddot
Computes the dot product of two vectors (double-precision).
double cblas_ddot ( const int N, const double *X, const int incX, const double *Y, const int incY );
Parameters
- N
The number of elements in the vectors.
- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dgbmv
Scales a general band matrix, then multiplies by a vector, then adds a vector (double precision).
void cblas_dgbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const int KL, const int KU, const double alpha, const double *A, const int lda, const double *X, const int incX, const double beta, double *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- M
Number of rows in matrix A.
- N
Number of columns in matrix A.
- KL
Number of subdiagonals in matrix A.
- KU
Number of superdiagonals in matrix A.
- alpha
Scaling factor to multiply matrix
Aby.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A. (Must be at leastKL+KU+1.)- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor to multiply vector Y by.
- Y
Vector Y.
- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y or alpha*A'*x + beta*y depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dgemm
Multiplies two matrices (double-precision).
void cblas_dgemm ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const int M, const int N, const int K, const double alpha, const double *A, const int lda, const double *B, const int ldb, const double beta, double *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- TransB
Specifies whether to transpose matrix
B.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- K
Number of columns in matrix
A; number of rows in matrixB.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
with optional use of transposed forms of A, B, or both.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dgemv
Multiplies a matrix by a vector (double precision).
void cblas_dgemv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const double alpha, const double *A, const int lda, const double *X, const int incX, const double beta, double *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for the product of matrix
Aand vectorX.- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- X
Vector X.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
Y.- Y
Vector Y
- incY
Stride within Y. For example, if incY is 7, every 7th element is used.
Discussion
This function multiplies A * X (after transposing A, if needed) and multiplies the resulting matrix by alpha. It then multiplies vector Y by beta. It stores the sum of these two products in vector Y.
Thus, it calculates either
Y←αAX + βY
with optional use of the transposed form of A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dger
Multiplies vector X by the transform of vector Y, then adds matrix A (double precison).
void cblas_dger ( const enum CBLAS_ORDER Order, const int M, const int N, const double alpha, const double *X, const int incX, const double *Y, const int incY, double *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Computes alpha*x*y' + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dnrm2
Computes the L2 norm (Euclidian length) of a vector (double precision).
double cblas_dnrm2 ( const int N, const double *X, const int incX );
Parameters
- N
Length of vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_drot
Applies a Givens rotation matrix to a pair of vectors.
void cblas_drot ( const int N, double *X, const int incX, double *Y, const int incY, const double c, const double s );
Parameters
- N
The number of elements in vectors
XandY.- X
Vector
X. Modified on return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y. Modified on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- c
The value
cos(θ)in the Givens rotation matrix.- s
The value
sin(θ)in the Givens rotation matrix.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_drotg
Constructs a Givens rotation matrix.
void cblas_drotg ( double *a, double *b, double *c, double *s );
Parameters
- a
Double-precision value
a. Overwritten on return with resultr.- b
Double-precision value
b. Overwritten on return with resultz(zero).- c
Unused on entry. Overwritten on return with the value
cos(θ).- s
Unused on entry. Overwritten on return with the value
sin(θ).
Discussion
Given a vertical matrix containing a and b, computes the values of cos θ and sin θ that zero the lower value (b). Returns the value of sin θ in s, the value of cos θ in c, and the upper value (r) in a.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_drotm
Applies a modified Givens transformation (single precision).
void cblas_drotm ( const int N, double *X, const int incX, double *Y, const int incY, const double *P );
Parameters
- N
Number of elements in vectors.
- X
Vector
X. Modified on return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y. Modified on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- P
A 5-element vector:
P[0]Flag value that defines the form of matrix
H.-2.0: matrixHcontains the identity matrix.-1.0: matrixHis identical to matrixSH(defined by the remaining values in the vector).0.0:H[1,2]andH[2,1]are obtained from matrixSH. The remaining values are both1.0.1.0:H[1,1]andH[2,2]are obtained from matrixSH.H[1,2]is 1.0.H[2,1]is -1.0.P[1]Contains
SH[1,1].P[2]Contains
SH[2,1].P[3]Contains
SH[1,2].P[4]Contains
SH[2,2].
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_drotmg
Generates a modified Givens rotation matrix.
void cblas_drotmg ( double *d1, double *d2, double *b1, const double b2, double *P );
Parameters
- d1
Scaling factor
D1.- d2
Scaling factor
D2.- b1
Scaling factor
B1.- b2
Scaling factor
B2.- P
A 5-element vector:
P[0]Flag value that defines the form of matrix
H.-2.0: matrixHcontains the identity matrix.-1.0: matrixHis identical to matrixSH(defined by the remaining values in the vector).0.0:H[1,2]andH[2,1]are obtained from matrixSH. The remaining values are both1.0.1.0:H[1,1]andH[2,2]are obtained from matrixSH.H[1,2]is 1.0.H[2,1]is -1.0.P[1]Contains
SH[1,1].P[2]Contains
SH[2,1].P[3]Contains
SH[1,2].P[4]Contains
SH[2,2].
Discussion
The resulting matrix zeroes the second component of the vector (sqrt(D1)*B1, sqrt(SD2)*B2)T.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsbmv
Scales a symmetric band matrix, then multiplies by a vector, then adds a vector (double precision).
void cblas_dsbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const int K, const double alpha, const double *A, const int lda, const double *X, const int incX, const double beta, double *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- alpha
Scaling value to multiply matrix A by.
- A
Matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
Yis multiplied by.- Y
Vector
Y. Replaced by results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and returns the results in vector Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dscal
Multiplies each element of a vector by a constant (double-precision).
void cblas_dscal ( const int N, const double alpha, double *X, const int incX );
Parameters
- N
The number of elements in vector
x.- alpha
The constant scaling factor to multiply by.
- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsdot
Computes the double-precision dot product of a pair of single-precision vectors.
double cblas_dsdot ( const int N, const float *X, const int incX, const float *Y, const int incY );
Parameters
- N
The number of elements in the vectors.
- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dspmv
Scales a packed symmetric matrix, then multiplies by a vector, then scales and adds another vector (double precision).
void cblas_dspmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const double *Ap, const double *X, const int incX, const double beta, double *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorsxandy.- alpha
Scaling factor that matrix
Ais multiplied by.- Ap
Matrix
A(in packed storage format).- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
yis multiplied by.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and stores the results in Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dspr
Rank one update: adds a packed symmetric matrix to the product of a scaling factor, a vector, and its transpose (double precision).
void cblas_dspr ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const double *X, const int incX, double *Ap );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Ap
Matrix
A(in packed storage format).
Discussion
Calculates A + alpha*x*xT and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dspr2
Rank two update of a packed symmetric matrix using two vectors (single precision).
void cblas_dspr2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const double *X, const int incX, const double *Y, const int incY, double *A );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A(in packed storage format).
Discussion
Calculates A + alpha*x*yT + alpha*y*xT.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dswap
Exchanges the elements of two vectors (double precision).
void cblas_dswap ( const int N, double *X, const int incX, double *Y, const int incY );
Parameters
- N
Number of elements in vectors
- X
Vector
x. On return, contains elements copied from vectory.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y. On return, contains elements copied from vectorx.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsymm
Multiplies a matrix by a symmetric matrix (double-precision).
void cblas_dsymm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const int M, const int N, const double alpha, const double *A, const int lda, const double *B, const int ldb, const double beta, double *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B or B * A (depending on the value of Side) and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
where
A = AT
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsymv
Scales a symmetric matrix, multiplies by a vector, then scales and adds another vector (single precision).
void cblas_dsymv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const double *A, const int lda, const double *X, const int incX, const double beta, double *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; length of vectors.- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
y.- Y
Vector
y. Contains results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and stores the results in Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsyr
Rank one update: adds a symmetric matrix to the product of a scaling factor, a vector, and its transpose (double precision).
void cblas_dsyr ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const double *X, const int incX, double *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix A.
Discussion
Calculates A + alpha*x*xT and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsyr2
Rank two update of a symmetric matrix using two vectors (single precision).
void cblas_dsyr2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const double *X, const int incX, const double *Y, const int incY, double *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Calculates A + alpha*x*yT + alpha*y*xT.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsyr2k
Performs a rank-2k update of a symmetric matrix (double precision).
void cblas_dsyr2k ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const double alpha, const double *A, const int lda, const double *B, const int ldb, const double beta, double *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- N
Order of matrix
C.- K
Specifies the number of columns in matrices
AandBiftrans='N'.Specifies the number of rows if
trans='C'ortrans='T').- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- B
Matrix
B.- ldb
Leading dimension of array containing matrix
B.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Computes alpha*A*BT + alpha*B*AT +beta*C
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dsyrk
Rank-k update—multiplies a symmetric matrix by its transpose and adds a second matrix (double precision).
void cblas_dsyrk ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const double alpha, const double *A, const int lda, const double beta, double *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- N
Order of matrix
C.- K
Number of columns in matrix
A(or number of rows if matrixAis transposed).- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Calculates alpha*A*AT + beta*C; if transposed, calculates alpha*AT*A + beta*C.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtbmv
Scales a triangular band matrix, then multiplies by a vector (double precision).
void cblas_dtbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const double *A, const int lda, double *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- A
Matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x and stores the results in x.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtbsv
Solves a triangular banded system of equations.
void cblas_dtbsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const double *A, const int lda, double *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- K
Number of superdiagonals or subdiagonals of matrix
A(depending on the value ofUplo).- A
Matrix
A.- lda
The leading dimension of matrix
A.- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtpmv
Multiplies a triangular matrix by a vector, then adds a vector (double precision).
void cblas_dtpmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const double *Ap, double *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
Aand the number of elements in vectorsxandy.- Ap
Matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x, AT*x, or conjg(AT)*x and stores the results in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtpsv
Solves a packed triangular system of equations.
void cblas_dtpsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const double *Ap, double *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- Ap
Matrix
A(in packed storage format).- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtrmm
Scales a triangular matrix and multiplies it by a matrix.
void cblas_dtrmm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const double alpha, const double *A, const int lda, double *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
Number of rows in matrix
B.- N
Number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- B
Matrix
B. Overwritten by results on return.- ldb
Leading dimension of matrix
B.
Discussion
If Side is 'L', multiplies alpha*A*B or alpha*A'*B, depending on TransA.
If Side is 'R', multiplies alpha*B*A or alpha*B*A', depending on TransA.
In either case, the results are stored in matrix B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtrmv
Multiplies a triangular matrix by a vector.
void cblas_dtrmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const double *A, const int lda, double *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- A
Triangular matrix
A.- lda
Leading dimension of matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Multiplies A*X or A'*X, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtrsm
Solves a triangular system of equations with multiple values for the right side.
void cblas_dtrsm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const double alpha, const double *A, const int lda, double *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrix and vector should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
The number of rows in matrix
B.- N
The number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- B
On entry, matrix
B. Overwritten on return by matrixX.- ldb
The leading dimension of matrix
B.
Discussion
If Side is 'L', solves A*X=alpha*B or A'*X=alpha*B, depending on TransA.
If Side is 'R', solves X*A=alpha*B or X*A'=alpha*B, depending on TransA.
In either case, the results overwrite the values of matrix B in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dtrsv
Solves a triangular system of equations with a single value for the right side.
void cblas_dtrsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const double *A, const int lda, double *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- X
The vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves A*x=b or A'*x=b where x and b are elements in X and B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dzasum
Computes the sum of the absolute values of real and imaginary parts of elements in a vector (single-precision complex).
double cblas_dzasum ( const int N, const void *X, const int incX );
Parameters
- N
Number of elements in the vector.
- X
Source vector
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Return Value
The return value is a single floating point value that contains the sum of the absolute values of both the real and imaginary parts of the vector.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_dznrm2
Computes the unitary norm of a vector (double-precision complex).
double cblas_dznrm2 ( const int N, const void *X, const int incX );
Parameters
- N
Length of vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_errprn
Prints an error message.
int cblas_errprn ( int ierr, int info, char *form, ... );
Parameters
- ierr
Error code number.
- info
Exit status returned by the function call. Negative values generally indicate the index of the offending parameter. Positive numbers generally indicate that an algorithm did not converge. Zero indicates success.
- form
A printf-style format string.
- ...
Arguments for the format string.
Return Value
Returns the minimum of ierr or info.
Discussion
This is commonly called by cblas_xerbla.
Availability
- Available in iOS 4.0 and later.
See Also
Declared In
cblas.hcblas_icamax
Returns the index of the element with the largest absolute value in a vector (single-precision complex).
int cblas_icamax ( const int N, const void *X, const int incX );
Parameters
- N
Number of elements in the vector.
- X
The vector.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Return Value
Returns an index in the range 0..N-1 corresponding with the element with the largest absolute value.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_idamax
Returns the index of the element with the largest absolute value in a vector (double-precision).
int cblas_idamax ( const int N, const double *X, const int incX );
Parameters
- N
Number of elements in the vector.
- X
The vector.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Return Value
Returns an index in the range 0..N-1 corresponding with the element with the largest absolute value.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_isamax
Returns the index of the element with the largest absolute value in a vector (single-precision).
int cblas_isamax ( const int N, const float *X, const int incX );
Parameters
- N
Number of elements in the vector.
- X
The vector.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Return Value
Returns an index in the range 0..N-1 corresponding with the element with the largest absolute value.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_izamax
Returns the index of the element with the largest absolute value in a vector (double-precision complex).
int cblas_izamax ( const int N, const void *X, const int incX );
Parameters
- N
Number of elements in the vector.
- X
The vector.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Return Value
Returns an index in the range 0..N-1 corresponding with the element with the largest absolute value.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sasum
Computes the sum of the absolute values of elements in a vector (single-precision).
float cblas_sasum ( const int N, const float *X, const int incX );
Parameters
- N
Number of elements in the vector.
- X
Source vector
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_saxpy
Computes a constant times a vector plus a vector (single-precision).
void cblas_saxpy ( const int N, const float alpha, const float *X, const int incX, float *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- alpha
Scaling factor for the values in
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result. The value computed is (alpha * X[i]) + Y[i].
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_scasum
Computes the sum of the absolute values of real and imaginary parts of elements in a vector (single-precision complex).
float cblas_scasum ( const int N, const void *X, const int incX );
Parameters
- N
Number of elements in the vector.
- X
Source vector
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Return Value
The return value is a single floating point value that contains the sum of the absolute values of both the real and imaginary parts of the vector.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_scnrm2
Computes the unitary norm of a vector (single-precision complex).
float cblas_scnrm2 ( const int N, const void *X, const int incX );
Parameters
- N
Length of vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_scopy
Copies a vector to another vector (single-precision).
void cblas_scopy ( const int N, const float *X, const int incX, float *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- X
Source vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Destination vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sdot
Computes the dot product of two vectors (single-precision).
float cblas_sdot ( const int N, const float *X, const int incX, const float *Y, const int incY );
Parameters
- N
The number of elements in the vectors.
- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sdsdot
Computes the dot product of two single-precision vectors plus an initial single-precision value.
float cblas_sdsdot ( const int N, const float alpha, const float *X, const int incX, const float *Y, const int incY );
Parameters
- N
The number of elements in the vectors.
- alpha
The initial value to add to the dot product.
- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sgbmv
Scales a general band matrix, then multiplies by a vector, then adds a vector (single precision).
void cblas_sgbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const int KL, const int KU, const float alpha, const float *A, const int lda, const float *X, const int incX, const float beta, float *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- M
Number of rows in matrix A.
- N
Number of columns in matrix A.
- KL
Number of subdiagonals in matrix A.
- KU
Number of superdiagonals in matrix A.
- alpha
Scaling factor to multiply matrix
Aby.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A. (Must be at leastKL+KU+1.)- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor to multiply vector Y by.
- Y
Vector Y.
- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y or alpha*A'*x + beta*y depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sgemm
Multiplies two matrices (single-precision).
void cblas_sgemm ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const int M, const int N, const int K, const float alpha, const float *A, const int lda, const float *B, const int ldb, const float beta, float *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- TransB
Specifies whether to transpose matrix
B.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- K
Number of columns in matrix
A; number of rows in matrixB.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
with optional use of transposed forms of A, B, or both.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sgemv
Multiplies a matrix by a vector (single precision).
void cblas_sgemv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const float alpha, const float *A, const int lda, const float *X, const int incX, const float beta, float *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for the product of matrix
Aand vectorX.- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- X
Vector X.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
Y.- Y
Vector Y
- incY
Stride within Y. For example, if incY is 7, every 7th element is used.
Discussion
This function multiplies A * X (after transposing A, if needed) and multiplies the resulting matrix by alpha. It then multiplies vector Y by beta. It stores the sum of these two products in vector Y.
Thus, it calculates either
Y←αAX + βY
with optional use of the transposed form of A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sger
Multiplies vector X by the transform of vector Y, then adds matrix A (single precison).
void cblas_sger ( const enum CBLAS_ORDER Order, const int M, const int N, const float alpha, const float *X, const int incX, const float *Y, const int incY, float *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Computes alpha*x*y' + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_snrm2
Computes the L2 norm (Euclidian length) of a vector (single precision).
float cblas_snrm2 ( const int N, const float *X, const int incX );
Parameters
- N
Length of vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_srot
Applies a Givens rotation matrix to a pair of vectors.
void cblas_srot ( const int N, float *X, const int incX, float *Y, const int incY, const float c, const float s );
Parameters
- N
The number of elements in vectors
XandY.- X
Vector
X. Modified on return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y. Modified on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- c
The value
cos(θ)in the Givens rotation matrix.- s
The value
sin(θ)in the Givens rotation matrix.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_srotg
Constructs a Givens rotation matrix.
void cblas_srotg ( float *a, float *b, float *c, float *s );
Parameters
- a
Single-precision value
a. Overwritten on return with resultr.- b
Single-precision value
b. Overwritten on return with resultz(zero).- c
Unused on entry. Overwritten on return with the value
cos(θ).- s
Unused on entry. Overwritten on return with the value
sin(θ).
Discussion
Given a vertical matrix containing a and b, computes the values of cos θ and sin θ that zero the lower value (b). Returns the value of sin θ in s, the value of cos θ in c, and the upper value (r) in a.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_srotm
Applies a modified Givens transformation (single precision).
void cblas_srotm ( const int N, float *X, const int incX, float *Y, const int incY, const float *P );
Parameters
- N
Number of elements in vectors.
- X
Vector
X. Modified on return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y. Modified on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- P
A 5-element vector:
P[0]Flag value that defines the form of matrix
H.-2.0: matrixHcontains the identity matrix.-1.0: matrixHis identical to matrixSH(defined by the remaining values in the vector).0.0:H[1,2]andH[2,1]are obtained from matrixSH. The remaining values are both1.0.1.0:H[1,1]andH[2,2]are obtained from matrixSH.H[1,2]is 1.0.H[2,1]is -1.0.P[1]Contains
SH[1,1].P[2]Contains
SH[2,1].P[3]Contains
SH[1,2].P[4]Contains
SH[2,2].
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_srotmg
Generates a modified Givens rotation matrix.
void cblas_srotmg ( float *d1, float *d2, float *b1, const float b2, float *P );
Parameters
- d1
Scaling factor
D1.- d2
Scaling factor
D2.- b1
Scaling factor
B1.- b2
Scaling factor
B2.- P
A 5-element vector:
P[0]Flag value that defines the form of matrix
H.-2.0: matrixHcontains the identity matrix.-1.0: matrixHis identical to matrixSH(defined by the remaining values in the vector).0.0:H[1,2]andH[2,1]are obtained from matrixSH. The remaining values are both1.0.1.0:H[1,1]andH[2,2]are obtained from matrixSH.H[1,2]is 1.0.H[2,1]is -1.0.P[1]Contains
SH[1,1].P[2]Contains
SH[2,1].P[3]Contains
SH[1,2].P[4]Contains
SH[2,2].
Discussion
The resulting matrix zeroes the second component of the vector (sqrt(D1)*B1, sqrt(SD2)*B2)T.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ssbmv
Scales a symmetric band matrix, then multiplies by a vector, then adds a vector (single-precision).
void cblas_ssbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const int K, const float alpha, const float *A, const int lda, const float *X, const int incX, const float beta, float *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- alpha
Scaling value to multiply matrix A by.
- A
Matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
Yis multiplied by.- Y
Vector
Y. Replaced by results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and returns the results in vector Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sscal
Multiplies each element of a vector by a constant (single-precision).
void cblas_sscal ( const int N, const float alpha, float *X, const int incX );
Parameters
- N
Number of elements to scale.
- alpha
The constant to multiply by.
- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is multiplied byalpha.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sspmv
Scales a packed symmetric matrix, then multiplies by a vector, then scales and adds another vector (single precision).
void cblas_sspmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const float *Ap, const float *X, const int incX, const float beta, float *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorsxandy.- alpha
Scaling factor that matrix
Ais multiplied by.- Ap
Matrix
A(in packed storage format).- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
yis multiplied by.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and stores the results in Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sspr
Rank one update: adds a packed symmetric matrix to the product of a scaling factor, a vector, and its transpose (single precision).
void cblas_sspr ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const float *X, const int incX, float *Ap );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Ap
Matrix
A(in packed storage format).
Discussion
Calculates A + alpha*x*xT and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sspr2
Rank two update of a packed symmetric matrix using two vectors (single precision).
void cblas_sspr2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const float *X, const int incX, const float *Y, const int incY, float *A );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A(in packed storage format).
Discussion
Calculates A + alpha*x*yT + alpha*y*xT.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_sswap
Exchanges the elements of two vectors (single precision).
void cblas_sswap ( const int N, float *X, const int incX, float *Y, const int incY );
Parameters
- N
Number of elements in vectors
- X
Vector
x. On return, contains elements copied from vectory.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y. On return, contains elements copied from vectorx.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ssymm
Multiplies a matrix by a symmetric matrix (single-precision).
void cblas_ssymm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const int M, const int N, const float alpha, const float *A, const int lda, const float *B, const int ldb, const float beta, float *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B or B * A (depending on the value of Side) and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
where
A = AT
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ssymv
Scales a symmetric matrix, multiplies by a vector, then scales and adds another vector (single precision).
void cblas_ssymv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const float *A, const int lda, const float *X, const int incX, const float beta, float *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; length of vectors.- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
y.- Y
Vector
y. Contains results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and stores the results in Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ssyr
Rank one update: adds a symmetric matrix to the product of a scaling factor, a vector, and its transpose (single precision).
void cblas_ssyr ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const float *X, const int incX, float *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Calculates A + alpha*x*xT and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ssyr2
Rank two update of a symmetric matrix using two vectors (single precision).
void cblas_ssyr2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const float alpha, const float *X, const int incX, const float *Y, const int incY, float *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
A; number of elements in vectorx.- alpha
Scaling factor to multiply
xby.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Calculates A + alpha*x*yT + alpha*y*xT.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ssyr2k
Performs a rank-2k update of a symmetric matrix (single precision).
void cblas_ssyr2k ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const float alpha, const float *A, const int lda, const float *B, const int ldb, const float beta, float *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- N
Order of matrix
C.- K
Specifies the number of columns in matrices
AandBiftrans='N'.Specifies the number of rows if
trans='C'ortrans='T').- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- B
Matrix
B.- ldb
Leading dimension of array containing matrix
B.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Computes alpha*A*BT + alpha*B*AT +beta*C
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ssyrk
Rank-k update—multiplies a symmetric matrix by its transpose and adds a second matrix (single precision).
void cblas_ssyrk ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const float alpha, const float *A, const int lda, const float beta, float *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- N
Order of matrix
C.- K
Number of columns in matrix
A(or number of rows if matrixAis transposed).- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Calculates alpha*A*AT + beta*C; if transposed, calculates alpha*AT*A + beta*C.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_stbmv
Scales a triangular band matrix, then multiplies by a vector (single precision).
void cblas_stbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const float *A, const int lda, float *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x and stores the results in x.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_stbsv
Solves a triangular banded system of equations.
void cblas_stbsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const float *A, const int lda, float *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- K
Number of superdiagonals or subdiagonals of matrix
A(depending on the value ofUplo).- A
Triangular matrix
A.- lda
The leading dimension of matrix
A.- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_stpmv
Multiplies a triangular matrix by a vector, then adds a vector (single precision).
void cblas_stpmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const float *Ap, float *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
Aand the number of elements in vectorsxandy.- Ap
Triangular matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x, AT*x, or conjg(AT)*x and stores the results in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_stpsv
Solves a packed triangular system of equations.
void cblas_stpsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const float *Ap, float *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- Ap
Triangular matrix
A(in packed storage format).- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_strmm
Scales a triangular matrix and multiplies it by a matrix.
void cblas_strmm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const float alpha, const float *A, const int lda, float *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
Number of rows in matrix
B.- N
Number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Triangular matrix
A.- lda
Leading dimension of matrix
A.- B
Matrix
B. Overwritten by results on return.- ldb
Leading dimension of matrix
B.
Discussion
If Side is 'L', multiplies alpha*A*B or alpha*A'*B, depending on TransA.
If Side is 'R', multiplies alpha*B*A or alpha*B*A', depending on TransA.
In either case, the results are stored in matrix B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_strmv
Multiplies a triangular matrix by a vector.
void cblas_strmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const float *A, const int lda, float *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- A
Triangular matrix
A.- lda
Leading dimension of matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Multiplies A*X or A'*X, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_strsm
Solves a triangular system of equations with multiple values for the right side.
void cblas_strsm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const float alpha, const float *A, const int lda, float *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrix and vector should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
The number of rows in matrix
B.- N
The number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- B
On entry, matrix
B. Overwritten on return by matrixX.- ldb
The leading dimension of matrix
B.
Discussion
If Side is 'L', solves A*X=alpha*B or A'*X=alpha*B, depending on TransA.
If Side is 'R', solves X*A=alpha*B or X*A'=alpha*B, depending on TransA.
In either case, the results overwrite the values of matrix B in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_strsv
Solves a triangular system of equations with a single value for the right side.
void cblas_strsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const float *A, const int lda, float *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- X
The vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves A*x=b or A'*x=b where x and b are elements in X and B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_xerbla
The default error handler for BLAS routines.
void cblas_xerbla ( int p, char *rout, char *form, ... );
Parameters
- p
The position of the invalid parameter
- rout
The name of the routine that generated this error.
- form
A format string describing the error.
- ...
Additional parameters for the format string.
Discussion
This is the default error handler for BLAS functions. You can replace it with another function by calling SetBLASParamErrorProc.
Availability
- Available in iOS 4.0 and later.
See Also
Declared In
cblas.hcblas_zaxpy
Computes a constant times a vector plus a vector (double-precision complex).
void cblas_zaxpy ( const int N, const void *alpha, const void *X, const int incX, void *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- alpha
Scaling factor for the values in
X.- X
Input vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Input vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
On return, the contents of vector Y are replaced with the result. The value computed is (alpha * X[i]) + Y[i].
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zcopy
Copies a vector to another vector (double-precision complex).
void cblas_zcopy ( const int N, const void *X, const int incX, void *Y, const int incY );
Parameters
- N
Number of elements in the vectors.
- X
Source vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Destination vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zdotc_sub
Calculates the dot product of the complex conjugate of a double-precision complex vector with a second double-precision complex vector.
void cblas_zdotc_sub ( const int N, const void *X, const int incX, const void *Y, const int incY, void *dotc );
Parameters
- N
Number of elements in vectors
XandY.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- dotc
The result vector.
Discussion
Computes conjg(X) * Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zdotu_sub
Computes the dot product of two double-precision complex vectors.
void cblas_zdotu_sub ( const int N, const void *X, const int incX, const void *Y, const int incY, void *dotu );
Parameters
- N
The length of vectors
XandY.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- dotu
The result vector.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zdrot
Applies a Givens rotation matrix to a pair of complex vectors.
void cblas_zdrot ( const int N, void *X, const int incX, void *Y, const int incY, const double c, const double s );
Parameters
- N
The number of elements in vectors
XandY.- X
Vector
X. Modified on return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y. Modified on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- c
The value
cos(θ)in the Givens rotation matrix.- s
The value
sin(θ)in the Givens rotation matrix.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zdscal
Multiplies each element of a vector by a constant (double-precision complex).
void cblas_zdscal ( const int N, const double alpha, void *X, const int incX );
Parameters
- N
The number of elements in the vector.
- alpha
The constant scaling factor.
- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zgbmv
Scales a general band matrix, then multiplies by a vector, then adds a vector (double-precision complex).
void cblas_zgbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const int KL, const int KU, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- M
Number of rows in matrix A.
- N
Number of columns in matrix A.
- KL
Number of subdiagonals in matrix A.
- KU
Number of superdiagonals in matrix A.
- alpha
Scaling factor to multiply matrix
Aby.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A. (Must be at leastKL+KU+1.)- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor to multiply vector Y by.
- Y
Vector Y.
- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y, alpha*A'*x + beta*y, or alpha*conjg(A')*x + beta*y depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zgemm
Multiplies two matrices (double-precision complex).
void cblas_zgemm ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const int M, const int N, const int K, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- TransB
Specifies whether to transpose matrix
B.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- K
Number of columns in matrix
A; number of rows in matrixB.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
with optional use of transposed forms of A, B, or both.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zgemv
Multiplies a matrix by a vector (double-precision complex).
void cblas_zgemv ( const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const int M, const int N, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- TransA
Specifies whether to transpose matrix
A.- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for the product of matrix
Aand vectorX.- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- X
Vector X.
- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
Y.- Y
Vector Y
- incY
Stride within Y. For example, if incY is 7, every 7th element is used.
Discussion
This function multiplies A * X (after transposing A, if needed) and multiplies the resulting matrix by alpha. It then multiplies vector Y by beta. It stores the sum of these two products in vector Y.
Thus, it calculates either
Y←αAX + βY
with optional use of the transposed form of A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zgerc
Multiplies vector X by the conjugate transform of vector Y, then adds matrix A (double-precision complex).
void cblas_zgerc ( const enum CBLAS_ORDER Order, const int M, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Computes alpha*x*conjg(y') + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zgeru
Multiplies vector X by the transform of vector Y, then adds matrix A (double-precision complex).
void cblas_zgeru ( const enum CBLAS_ORDER Order, const int M, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- M
Number of rows in matrix
A.- N
Number of columns in matrix
A.- alpha
Scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.
Discussion
Computes alpha*x*y' + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zhbmv
Scales a Hermitian band matrix, then multiplies by a vector, then adds a vector (double-precision complex).
void cblas_zhbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const int K, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- alpha
Scaling value to multiply matrix A by.
- A
Matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
Yis multiplied by.- Y
Vector
Y. Replaced by results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and returns the results in vector Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zhemm
Multiplies two Hermitian matrices (double-precision complex).
void cblas_zhemm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const int M, const int N, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- M
The number of rows in matrices
AandC.- N
The number of columns in matrices
BandC.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B or B * A (depending on the value of Side) and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
where
A = AH
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zhemv
Scales and multiplies a Hermitian matrix by a vector, then adds a second (scaled) vector.
void cblas_zhemv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *A, const int lda, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor for vector
X.- Y
Vector
Y. Overwritten by results on return.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Calculates Y←αAX + βY.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zher
Adds the product of a scaling factor, vector X, and the conjugate transpose of X to matrix A.
void cblas_zher ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const void *X, const int incX, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- alpha
The scaling factor for vector
X.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- A
Matrix
A.- lda
Leading dimension of matrix
A.
Discussion
Computes A←αX*conjg(X') + βA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zher2
Hermitian rank 2 update: adds the product of a scaling factor, vector X, and the conjugate transpose of vector Y to the product of the conjugate of the scaling factor, vector Y, and the conjugate transpose of vector X, and adds the result to matrix A.
void cblas_zher2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *A, const int lda );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
The order of matrix
A.- alpha
The scaling factor
α.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
Y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- A
Matrix
A.- lda
The leading dimension of matrix
A.
Discussion
Computes A←αX*conjg(Y') + conjg(α)*Y*conjg(X') + A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zher2k
Performs a rank-2k update of a complex Hermitian matrix (double-precision complex).
void cblas_zher2k ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const double beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- N
Order of matrix
C.- K
Specifies the number of columns in matrices
AandBiftrans='N'.Specifies the number of rows if
trans='C'ortrans='T').- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- B
Matrix
B.- ldb
Leading dimension of array containing matrix
B.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Computes alpha*A*BH + alpha*B*AH +beta*C
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zherk
Rank-k update—multiplies a Hermitian matrix by its transpose and adds a second matrix (single precision).
void cblas_zherk ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const double alpha, const void *A, const int lda, const double beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n') or the conjugate transpose of A ('C'or'c').- N
Order of matrix
C.- K
Number of columns in matrix
A(or number of rows if matrixAis transposed).- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Calculates alpha*A*AH + beta*C; if transposed, calculates alpha*AH*A + beta*C.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zhpmv
Scales a packed hermitian matrix, multiplies it by a vector, and adds a scaled vector.
void cblas_zhpmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *Ap, const void *X, const int incX, const void *beta, void *Y, const int incY );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorsxandy.- alpha
Scaling factor that matrix
Ais multiplied by.- Ap
Matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- beta
Scaling factor that vector
yis multiplied by.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Discussion
Computes alpha*A*x + beta*y and stores the results in Y.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zhpr
Scales and multiplies a vector times its conjugate transpose, then adds a matrix.
void cblas_zhpr ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const double alpha, const void *X, const int incX, void *A );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorx.- alpha
Scaling factor that vector
xis multiplied by.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- A
Matrix
A. Overwritten by results on return.
Discussion
Calculates alpha*x*conjg(x') + A and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zhpr2
Multiplies a vector times the conjugate transpose of a second vector and vice-versa, sums the results, and adds a matrix.
void cblas_zhpr2 ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const int N, const void *alpha, const void *X, const int incX, const void *Y, const int incY, void *Ap );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- N
Order of matrix
Aand the number of elements in vectorsxandy.- alpha
Scaling factor that vector
xis multiplied by.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.- Ap
Matrix
Ain packed storage format. Overwritten by the results on return.
Discussion
Calcuates alpha*x*conjg(y') + conjg(alpha)*y*conjg(x') + A, and stores the result in A.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zrotg
Constructs a complex Givens rotation.
void cblas_zrotg ( void *a, void *b, void *c, void *s );
Parameters
- a
Complex value
a. Overwritten on return with resultr.- b
Complex value
a. Overwritten on return with resultz(zero).- c
Real value
c. Unused on entry. Overwritten on return with the valuecos(θ).- s
Complex value
s. Unused on entry. Overwritten on return with the valuesin(θ).
Discussion
Given a vertical matrix containing a and b, computes the values of cos θ and sin θ that zero the lower value (b). Returns the value of sin θ in s, the value of cos θ in c, and the upper value (r) in a.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zscal
Multiplies each element of a vector by a constant (double-precision complex).
void cblas_zscal ( const int N, const void *alpha, void *X, const int incX );
Parameters
- N
The number of elements in the vector.
- alpha
The constant scaling factor.
- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zswap
Exchanges the elements of two vectors (double-precision complex).
void cblas_zswap ( const int N, void *X, const int incX, void *Y, const int incY );
Parameters
- N
Number of elements in vectors
- X
Vector
x. On return, contains elements copied from vectory.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.- Y
Vector
y. On return, contains elements copied from vectorx.- incY
Stride within
Y. For example, ifincYis 7, every 7th element is used.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zsymm
Multiplies a matrix by a symmetric matrix (double-precision complex).
void cblas_zsymm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const int M, const int N, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- M
Number of rows in matrices
AandC.- N
Number of columns in matrices
BandC.- alpha
Scaling factor for the product of matrices A and B.
- A
Matrix A.
- lda
The size of the first dimention of matrix
A; if you are passing a matrixA[m][n], the value should bem.- B
Matrix B.
- ldb
The size of the first dimention of matrix
B; if you are passing a matrixB[m][n], the value should bem.- beta
Scaling factor for matrix C.
- C
Matrix C.
- ldc
The size of the first dimention of matrix
C; if you are passing a matrixC[m][n], the value should bem.
Discussion
This function multiplies A * B or B * A (depending on the value of Side) and multiplies the resulting matrix by alpha. It then multiplies matrix C by beta. It stores the sum of these two products in matrix C.
Thus, it calculates either
C←αAB + βC
or
C←αBA + βC
where
A = AT
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zsyr2k
Performs a rank-2k update of a symmetric matrix (double-precision complex).
void cblas_zsyr2k ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const void *alpha, const void *A, const int lda, const void *B, const int ldb, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- N
Order of matrix
C.- K
Specifies the number of columns in matrices
AandBiftrans='N'.Specifies the number of rows if
trans='C'ortrans='T').- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- B
Matrix
B.- ldb
Leading dimension of array containing matrix
B.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Computes alpha*A*BT + alpha*B*AT +beta*C
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_zsyrk
Rank-k update—multiplies a symmetric matrix by its transpose and adds a second matrix (double-precision complex).
void cblas_zsyrk ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const int N, const int K, const void *alpha, const void *A, const int lda, const void *beta, void *C, const int ldc );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- Trans
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T'or't').- N
Order of matrix
C.- K
Number of columns in matrix
A(or number of rows if matrixAis transposed).- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of array containing matrix
A.- beta
Scaling factor for matrix
C.- C
Matrix
C.- ldc
Leading dimension of array containing matrix
C.
Discussion
Calculates alpha*A*AT + beta*C; if transposed, calculates alpha*AT*A + beta*C.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztbmv
Scales a triangular band matrix, then multiplies by a vector (double-precision complex).
void cblas_ztbmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- K
Half-bandwidth of matrix
A.- A
Matrix
A.- lda
The leading dimension of array containing matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x and stores the results in x.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztbsv
Solves a triangular banded system of equations.
void cblas_ztbsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const int K, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- K
Number of superdiagonals or subdiagonals of matrix
A(depending on the value ofUplo).- A
Matrix
A.- lda
The leading dimension of matrix
A.- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztpmv
Multiplies a triangular matrix by a vector, then adds a vector (double-precision compex).
void cblas_ztpmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *Ap, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n'), the transpose of A ('T'or't'), or the conjugate of A ('C'or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
Aand the number of elements in vectorsxandy.- Ap
Matrix
A.- X
Vector
x.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Computes A*x, AT*x, or conjg(AT)*x and stores the results in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztpsv
Solves a packed triangular system of equations.
void cblas_ztpsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *Ap, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- Ap
Matrix
A(in packed storage format).- X
Contains vector
Bon entry. Overwritten with vectorXon return.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves the system of equations A*X=B or A'*X=B, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztrmm
Scales a triangular matrix and multiplies it by a matrix.
void cblas_ztrmm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const void *alpha, const void *A, const int lda, void *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrices should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
Number of rows in matrix
B.- N
Number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- B
Matrix
B. Overwritten by results on return.- ldb
Leading dimension of matrix
B.
Discussion
If Side is 'L', multiplies alpha*A*B or alpha*A'*B, depending on TransA.
If Side is 'R', multiplies alpha*B*A or alpha*B*A', depending on TransA.
In either case, the results are stored in matrix B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztrmv
Multiplies a triangular matrix by a vector.
void cblas_ztrmv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
Order of matrix
A.- A
Matrix
A.- lda
Leading dimension of matrix
A.- X
Vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Multiplies A*X or A'*X, depending on the value of TransA.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztrsm
Solves a triangular system of equations with multiple values for the right side.
void cblas_ztrsm ( const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int M, const int N, const void *alpha, const void *A, const int lda, void *B, const int ldb );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Side
Determines the order in which the matrix and vector should be multiplied.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- M
The number of rows in matrix
B.- N
The number of columns in matrix
B.- alpha
Scaling factor for matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- B
On entry, matrix
B. Overwritten on return by matrixX.- ldb
The leading dimension of matrix
B.
Discussion
If Side is 'L', solves A*X=alpha*B or A'*X=alpha*B, depending on TransA.
If Side is 'R', solves X*A=alpha*B or X*A'=alpha*B, depending on TransA.
In either case, the results overwrite the values of matrix B in X.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hcblas_ztrsv
Solves a triangular system of equations with a single value for the right side.
void cblas_ztrsv ( const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const int N, const void *A, const int lda, void *X, const int incX );
Parameters
- Order
Specifies row-major (C) or column-major (Fortran) data ordering.
- Uplo
Specifies whether to use the upper or lower triangle from the matrix. Valid values are
'U'or'L'.- TransA
Specifies whether to use matrix A (
'N'or'n') or the transpose of A ('T','t','C', or'c').- Diag
Specifies whether the matrix is unit triangular. Possible values are
'U'(unit triangular) or'N'(not unit triangular).- N
The order of matrix
A.- A
Triangular matrix
A.- lda
The leading dimension of matrix
B.- X
The vector
X.- incX
Stride within
X. For example, ifincXis 7, every 7th element is used.
Discussion
Solves A*x=b or A'*x=b where x and b are elements in X and B.
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hSetBLASParamErrorProc
Sets an error handler function.
void SetBLASParamErrorProc ( BLASParamErrorProc ErrorProc );
Parameters
- ErrorProc
The handler function BLAS should call when an error occurs (because of an invalid input, for example).
Availability
- Available in iOS 4.0 and later.
See Also
Declared In
cblas.hData Types
BLASParamErrorProc
BLAS error handler callback type.
typedef void (*BLASParamErrorProc)( const char *funcName, const char *paramName, const int *paramPos, const int *paramValue);
Availability
- Available in iOS 4.0 and later.
Declared In
cblas.hConstants
CBLAS_ORDER
Indicates whether a matrix is in row-major or column-major order.
enum CBLAS_ORDER {
CblasRowMajor=101,
CblasColMajor=102
};
typedef enum CBLAS_ORDER CBLAS_ORDER;
Constants
CblasRowMajorRow-major order.
Available in iOS 4.0 and later.
Declared in
cblas.h.CblasColMajorColumn-major order.
Available in iOS 4.0 and later.
Declared in
cblas.h.
CBLAS_TRANSPOSE
Indiates transpose operation to perform on a matrix.
enum CBLAS_TRANSPOSE {
CblasNoTrans=111,
CblasTrans=112,
CblasConjTrans=113,
AtlasConj=114
};
typedef enum CBLAS_TRANSPOSE CBLAS_TRANSPOSE;
Constants
CblasNoTransNo transposition.
Available in iOS 4.0 and later.
Declared in
cblas.h.CblasTransFor matrix
X, useX(T).Available in iOS 4.0 and later.
Declared in
cblas.h.CblasConjTransFor matrix
X, useX(H)(conjugate or Hermitian transposition).Available in iOS 4.0 and later.
Declared in
cblas.h.AtlasConjAvailable in iOS 4.0 and later.
Declared in
cblas.h.
CBLAS_UPLO
Indicates which part of a symmetric matrix to use.
enum CBLAS_UPLO {
CblasUpper=121,
CblasLower=122
};
typedef enum CBLAS_UPLO CBLAS_UPLO;
Constants
CblasUpperUse the upper triangle of the matrix.
Available in iOS 4.0 and later.
Declared in
cblas.h.CblasLowerUse the lower triangle of the matrix.
Available in iOS 4.0 and later.
Declared in
cblas.h.
CBLAS_DIAG
Indicates whether a triangular matrix is unit-diagonal (diagonal elements are all equal to 1).
enum CBLAS_DIAG {
CblasNonUnit=131,
CblasUnit=132
};
typedef enum CBLAS_DIAG CBLAS_DIAG;
Constants
CblasNonUnitThe triangular matrix is not unit-diagonal.
Available in iOS 4.0 and later.
Declared in
cblas.h.CblasUnitThe triangular matrix is unit-diagonal.
Available in iOS 4.0 and later.
Declared in
cblas.h.
CBLAS_SIDE
Indicates the order of a matrix multiplication.
enum CBLAS_SIDE {
CblasLeft=141,
CblasRight=142
};
typedef enum CBLAS_SIDE CBLAS_SIDE;
Constants
CblasLeftMultiply A*B.
Available in iOS 4.0 and later.
Declared in
cblas.h.CblasRightMultiply B*A.
Available in iOS 4.0 and later.
Declared in
cblas.h.
© 2005, 2013 Apple Inc. All Rights Reserved. (Last updated: 2013-04-23)