BLAS Reference
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/blastforum/blastforum.html
Functions by Task
General Functions

SetBLASParamErrorProc

cblas_errprn

cblas_xerbla

cblas_icamax

cblas_idamax

cblas_isamax

cblas_izamax

ATLU_DestroyThreadMemory
Deprecated in iOS 7.0
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
SinglePrecision 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
SinglePrecision 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
DoublePrecision 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
DoublePrecision 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
catlas_caxpby
Computes the product of two vectors, scaling each one separately (singleprecision 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, ifincX
is 7, every 7th element is used. beta
Scaling factor for Y.
 Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
catlas_cset
Modifies a vector (singleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
catlas_daxpby
Computes the product of two vectors, scaling each one separately (doubleprecision).
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, ifincX
is 7, every 7th element is used. beta
Scaling factor for Y.
 Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
catlas_dset
Modifies a vector (doubleprecision) 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
catlas_saxpby
Scales the two input vectors separately, then adds the input vectors (singleprecision).
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, ifincX
is 7, every 7th element is used. beta
Scaling factor for Y.
 Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
catlas_sset
Modifies a vector (singleprecision) 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
catlas_zaxpby
Computes the product of two vectors, scaling each one separately (doubleprecision 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, ifincX
is 7, every 7th element is used. beta
Scaling factor for Y.
 Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
catlas_zset
Modifies a vector (doubleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_caxpy
Computes a constant times a vector plus a vector (singleprecision 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, ifincX
is 7, every 7th element is used. Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_ccopy
Copies a vector to another vector (singleprecision 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, ifincX
is 7, every 7th element is used. Y
Destination vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_cdotc_sub
Calculates the dot product of the complex conjugate of a singleprecision complex vector with a second singleprecision 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
X
andY
. X
Vector
X
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_cdotu_sub
Computes the dot product of two singleprecision 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
X
andY
. X
Vector
X
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. dotu
The result vector.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_cgbmv
Scales a general band matrix, then multiplies by a vector, then adds a vector (singleprecision 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 rowmajor (C) or columnmajor (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
A
by. 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, ifincX
is 7, every 7th element is used. beta
Scaling factor to multiply vector Y by.
 Y
Vector Y.
 incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_cgemm
Multiplies two matrices (singleprecision 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 rowmajor (C) or columnmajor (Fortran) data ordering.
 TransA
Specifies whether to transpose matrix
A
. TransB
Specifies whether to transpose matrix
B
. M
Number of rows in matrices
A
andC
. N
Number of columns in matrices
B
andC
. 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.h
cblas_cgemv
Multiplies a matrix by a vector (singleprecision 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 rowmajor (C) or columnmajor (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
A
and 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, ifincX
is 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.h
cblas_cgerc
Multiplies vector X by the conjugate transform of vector Y, then adds matrix A (singleprecision 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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_cgeru
Multiplies vector X by the transform of vector Y, then adds matrix A (singleprecision 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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_chbmv
Scales a Hermitian band matrix, then multiplies by a vector, then adds a vector (singleprecision 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 rowmajor (C) or columnmajor (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
Halfbandwidth 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, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
Y
is multiplied by. Y
Vector
Y
. Replaced by results on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_chemm
Multiplies two Hermitian matrices (singleprecision 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 rowmajor (C) or columnmajor (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
A
andC
. N
The number of columns in matrices
B
andC
. 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 = A^{H}
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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, ifincY
is 7, every 7th element is used.
Discussion
Calculates Y←αAX + βY
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_cher2k
Performs a rank2k update of a complex Hermitian matrix (singleprecision 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 rowmajor (C) or columnmajor (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
A
andB
iftrans='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*B^{H} + alpha*B*A^{H} +beta*C
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_cherk
Rankk 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 rowmajor (C) or columnmajor (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 matrixA
is 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*A^{H} + beta*C
; if transposed, calculates alpha*A^{H}*A + beta*C
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
and the number of elements in vectorsx
andy
. alpha
Scaling factor that matrix
A
is multiplied by. Ap
Matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
y
is multiplied by. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
and the number of elements in vectorx
. alpha
Scaling factor that vector
x
is multiplied by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_chpr2
Multiplies a vector times the conjugate transpose of a second vector and viceversa, 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 rowmajor (C) or columnmajor (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
and the number of elements in vectorsx
andy
. alpha
Scaling factor that vector
x
is multiplied by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. Ap
Matrix
A
in 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.h
cblas_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.h
cblas_cscal
Multiplies each element of a vector by a constant (singleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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
X
andY
. X
Vector
X
. Modified on return. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. Modified on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_csscal
Multiplies each element of a vector by a constant (singleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_cswap
Exchanges the elements of two vectors (singleprecision 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, ifincX
is 7, every 7th element is used. Y
Vector
y
. On return, contains elements copied from vectorx
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_csymm
Multiplies a matrix by a symmetric matrix (singleprecision 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 rowmajor (C) or columnmajor (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
A
andC
. N
Number of columns in matrices
B
andC
. 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 = A^{T}
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_csyr2k
Performs a rank2k update of a symmetric matrix (singleprecision 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 rowmajor (C) or columnmajor (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
A
andB
iftrans='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*B^{T} + alpha*B*A^{T} +beta*C
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_csyrk
Rankk update—multiplies a symmetric matrix by its transpose and adds a second matrix (singleprecision 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 rowmajor (C) or columnmajor (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 matrixA
is 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*A^{T} + beta*C
; if transposed, calculates alpha*A^{T}*A + beta*C
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_ctbmv
Scales a triangular band matrix, then multiplies by a vector (singleprecision 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 rowmajor (C) or columnmajor (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
Halfbandwidth of matrix
A
. A
Matrix
A
. lda
The leading dimension of array containing matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_ctpmv
Multiplies a triangular matrix by a vector, then adds a vector (singleprecision 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 rowmajor (C) or columnmajor (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
A
and the number of elements in vectorsx
andy
. Ap
Matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used.
Discussion
Computes A*x
, A^{T}*x
, or conjg(A^{T})*x
and stores the results in X
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_dasum
Computes the sum of the absolute values of elements in a vector (doubleprecision).
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, ifincX
is 7, every 7th element is used.
Return Value
Returns the sum.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_daxpy
Computes a constant times a vector plus a vector (doubleprecision).
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, ifincX
is 7, every 7th element is used. Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_dcopy
Copies a vector to another vector (doubleprecision).
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, ifincX
is 7, every 7th element is used. Y
Destination vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_ddot
Computes the dot product of two vectors (doubleprecision).
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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
A
by. 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, ifincX
is 7, every 7th element is used. beta
Scaling factor to multiply vector Y by.
 Y
Vector Y.
 incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_dgemm
Multiplies two matrices (doubleprecision).
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 rowmajor (C) or columnmajor (Fortran) data ordering.
 TransA
Specifies whether to transpose matrix
A
. TransB
Specifies whether to transpose matrix
B
. M
Number of rows in matrices
A
andC
. N
Number of columns in matrices
B
andC
. 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.h
cblas_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 rowmajor (C) or columnmajor (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
A
and 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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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
X
andY
. X
Vector
X
. Modified on return. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. Modified on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_drotg
Constructs a Givens rotation matrix.
void cblas_drotg ( double *a, double *b, double *c, double *s );
Parameters
 a
Doubleprecision value
a
. Overwritten on return with resultr
. b
Doubleprecision 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.h
cblas_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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. Modified on return. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. P
A 5element vector:
P[0]
Flag value that defines the form of matrix
H
.2.0
: matrixH
contains the identity matrix.1.0
: matrixH
is 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.h
cblas_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 5element vector:
P[0]
Flag value that defines the form of matrix
H
.2.0
: matrixH
contains the identity matrix.1.0
: matrixH
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
Halfbandwidth 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, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
Y
is multiplied by. Y
Vector
Y
. Replaced by results on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_dscal
Multiplies each element of a vector by a constant (doubleprecision).
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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_dsdot
Computes the doubleprecision dot product of a pair of singleprecision 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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
and the number of elements in vectorsx
andy
. alpha
Scaling factor that matrix
A
is multiplied by. Ap
Matrix
A
(in packed storage format). X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
y
is multiplied by. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Ap
Matrix
A
(in packed storage format).
Discussion
Calculates A + alpha*x*x^{T}
and stores the result in A
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. A
Matrix
A
(in packed storage format).
Discussion
Calculates A + alpha*x*y^{T} + alpha*y*x^{T}
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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, ifincX
is 7, every 7th element is used. Y
Vector
y
. On return, contains elements copied from vectorx
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_dsymm
Multiplies a matrix by a symmetric matrix (doubleprecision).
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 rowmajor (C) or columnmajor (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
A
andC
. N
Number of columns in matrices
B
andC
. 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 = A^{T}
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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, ifincY
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. A
Matrix
A
. lda
Leading dimension of array containing matrix A.
Discussion
Calculates A + alpha*x*x^{T}
and stores the result in A
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. A
Matrix
A
. lda
Leading dimension of array containing matrix
A
.
Discussion
Calculates A + alpha*x*y^{T} + alpha*y*x^{T}
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_dsyr2k
Performs a rank2k 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 rowmajor (C) or columnmajor (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
A
andB
iftrans='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*B^{T} + alpha*B*A^{T} +beta*C
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_dsyrk
Rankk 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 rowmajor (C) or columnmajor (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 matrixA
is 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*A^{T} + beta*C
; if transposed, calculates alpha*A^{T}*A + beta*C
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
Halfbandwidth of matrix
A
. A
Matrix
A
. lda
The leading dimension of array containing matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
A
and the number of elements in vectorsx
andy
. Ap
Matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used.
Discussion
Computes A*x
, A^{T}*x
, or conjg(A^{T})*x
and stores the results in X
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_dzasum
Computes the sum of the absolute values of real and imaginary parts of elements in a vector (singleprecision 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, ifincX
is 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.h
cblas_dznrm2
Computes the unitary norm of a vector (doubleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 printfstyle 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.h
cblas_icamax
Returns the index of the element with the largest absolute value in a vector (singleprecision 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, ifincX
is 7, every 7th element is used.
Return Value
Returns an index in the range 0..N1 corresponding with the element with the largest absolute value.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_idamax
Returns the index of the element with the largest absolute value in a vector (doubleprecision).
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, ifincX
is 7, every 7th element is used.
Return Value
Returns an index in the range 0..N1 corresponding with the element with the largest absolute value.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_isamax
Returns the index of the element with the largest absolute value in a vector (singleprecision).
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, ifincX
is 7, every 7th element is used.
Return Value
Returns an index in the range 0..N1 corresponding with the element with the largest absolute value.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_izamax
Returns the index of the element with the largest absolute value in a vector (doubleprecision 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, ifincX
is 7, every 7th element is used.
Return Value
Returns an index in the range 0..N1 corresponding with the element with the largest absolute value.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_sasum
Computes the sum of the absolute values of elements in a vector (singleprecision).
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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_saxpy
Computes a constant times a vector plus a vector (singleprecision).
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, ifincX
is 7, every 7th element is used. Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_scasum
Computes the sum of the absolute values of real and imaginary parts of elements in a vector (singleprecision 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, ifincX
is 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.h
cblas_scnrm2
Computes the unitary norm of a vector (singleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_scopy
Copies a vector to another vector (singleprecision).
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, ifincX
is 7, every 7th element is used. Y
Destination vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_sdot
Computes the dot product of two vectors (singleprecision).
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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_sdsdot
Computes the dot product of two singleprecision vectors plus an initial singleprecision 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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
A
by. 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, ifincX
is 7, every 7th element is used. beta
Scaling factor to multiply vector Y by.
 Y
Vector Y.
 incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_sgemm
Multiplies two matrices (singleprecision).
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 rowmajor (C) or columnmajor (Fortran) data ordering.
 TransA
Specifies whether to transpose matrix
A
. TransB
Specifies whether to transpose matrix
B
. M
Number of rows in matrices
A
andC
. N
Number of columns in matrices
B
andC
. 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.h
cblas_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 rowmajor (C) or columnmajor (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
A
and 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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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
X
andY
. X
Vector
X
. Modified on return. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. Modified on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_srotg
Constructs a Givens rotation matrix.
void cblas_srotg ( float *a, float *b, float *c, float *s );
Parameters
 a
Singleprecision value
a
. Overwritten on return with resultr
. b
Singleprecision 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.h
cblas_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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. Modified on return. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. P
A 5element vector:
P[0]
Flag value that defines the form of matrix
H
.2.0
: matrixH
contains the identity matrix.1.0
: matrixH
is 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.h
cblas_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 5element vector:
P[0]
Flag value that defines the form of matrix
H
.2.0
: matrixH
contains the identity matrix.1.0
: matrixH
is 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.h
cblas_ssbmv
Scales a symmetric band matrix, then multiplies by a vector, then adds a vector (singleprecision).
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 rowmajor (C) or columnmajor (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
Halfbandwidth 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, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
Y
is multiplied by. Y
Vector
Y
. Replaced by results on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_sscal
Multiplies each element of a vector by a constant (singleprecision).
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, ifincX
is 7, every 7th element is multiplied byalpha
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
and the number of elements in vectorsx
andy
. alpha
Scaling factor that matrix
A
is multiplied by. Ap
Matrix
A
(in packed storage format). X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
y
is multiplied by. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Ap
Matrix
A
(in packed storage format).
Discussion
Calculates A + alpha*x*x^{T}
and stores the result in A
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. A
Matrix
A
(in packed storage format).
Discussion
Calculates A + alpha*x*y^{T} + alpha*y*x^{T}
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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, ifincX
is 7, every 7th element is used. Y
Vector
y
. On return, contains elements copied from vectorx
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_ssymm
Multiplies a matrix by a symmetric matrix (singleprecision).
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 rowmajor (C) or columnmajor (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
A
andC
. N
Number of columns in matrices
B
andC
. 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 = A^{T}
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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, ifincY
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. A
Matrix
A
. lda
Leading dimension of array containing matrix
A
.
Discussion
Calculates A + alpha*x*x^{T}
and stores the result in A
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
x
by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. A
Matrix
A
. lda
Leading dimension of array containing matrix
A
.
Discussion
Calculates A + alpha*x*y^{T} + alpha*y*x^{T}
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_ssyr2k
Performs a rank2k 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 rowmajor (C) or columnmajor (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
A
andB
iftrans='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*B^{T} + alpha*B*A^{T} +beta*C
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_ssyrk
Rankk 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 rowmajor (C) or columnmajor (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 matrixA
is 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*A^{T} + beta*C
; if transposed, calculates alpha*A^{T}*A + beta*C
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
Halfbandwidth 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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
A
and the number of elements in vectorsx
andy
. Ap
Triangular matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used.
Discussion
Computes A*x
, A^{T}*x
, or conjg(A^{T})*x
and stores the results in X
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_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.h
cblas_zaxpy
Computes a constant times a vector plus a vector (doubleprecision 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, ifincX
is 7, every 7th element is used. Y
Input vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zcopy
Copies a vector to another vector (doubleprecision 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, ifincX
is 7, every 7th element is used. Y
Destination vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_zdotc_sub
Calculates the dot product of the complex conjugate of a doubleprecision complex vector with a second doubleprecision 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
X
andY
. X
Vector
X
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zdotu_sub
Computes the dot product of two doubleprecision 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
X
andY
. X
Vector
X
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. dotu
The result vector.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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
X
andY
. X
Vector
X
. Modified on return. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
Y
. Modified on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zdscal
Multiplies each element of a vector by a constant (doubleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_zgbmv
Scales a general band matrix, then multiplies by a vector, then adds a vector (doubleprecision 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 rowmajor (C) or columnmajor (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
A
by. 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, ifincX
is 7, every 7th element is used. beta
Scaling factor to multiply vector Y by.
 Y
Vector Y.
 incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zgemm
Multiplies two matrices (doubleprecision 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 rowmajor (C) or columnmajor (Fortran) data ordering.
 TransA
Specifies whether to transpose matrix
A
. TransB
Specifies whether to transpose matrix
B
. M
Number of rows in matrices
A
andC
. N
Number of columns in matrices
B
andC
. 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.h
cblas_zgemv
Multiplies a matrix by a vector (doubleprecision 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 rowmajor (C) or columnmajor (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
A
and 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, ifincX
is 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.h
cblas_zgerc
Multiplies vector X by the conjugate transform of vector Y, then adds matrix A (doubleprecision 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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zgeru
Multiplies vector X by the transform of vector Y, then adds matrix A (doubleprecision 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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zhbmv
Scales a Hermitian band matrix, then multiplies by a vector, then adds a vector (doubleprecision 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 rowmajor (C) or columnmajor (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
Halfbandwidth 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, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
Y
is multiplied by. Y
Vector
Y
. Replaced by results on return. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zhemm
Multiplies two Hermitian matrices (doubleprecision 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 rowmajor (C) or columnmajor (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
A
andC
. N
The number of columns in matrices
B
andC
. 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 = A^{H}
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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, ifincY
is 7, every 7th element is used.
Discussion
Calculates Y←αAX + βY
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 7, every 7th element is used. Y
Vector
Y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_zher2k
Performs a rank2k update of a complex Hermitian matrix (doubleprecision 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 rowmajor (C) or columnmajor (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
A
andB
iftrans='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*B^{H} + alpha*B*A^{H} +beta*C
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_zherk
Rankk 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 rowmajor (C) or columnmajor (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 matrixA
is 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*A^{H} + beta*C
; if transposed, calculates alpha*A^{H}*A + beta*C
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
and the number of elements in vectorsx
andy
. alpha
Scaling factor that matrix
A
is multiplied by. Ap
Matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. beta
Scaling factor that vector
y
is multiplied by. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
and the number of elements in vectorx
. alpha
Scaling factor that vector
x
is multiplied by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_zhpr2
Multiplies a vector times the conjugate transpose of a second vector and viceversa, 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 rowmajor (C) or columnmajor (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
and the number of elements in vectorsx
andy
. alpha
Scaling factor that vector
x
is multiplied by. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used. Y
Vector
y
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used. Ap
Matrix
A
in 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.h
cblas_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.h
cblas_zscal
Multiplies each element of a vector by a constant (doubleprecision 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, ifincX
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_zswap
Exchanges the elements of two vectors (doubleprecision 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, ifincX
is 7, every 7th element is used. Y
Vector
y
. On return, contains elements copied from vectorx
. incY
Stride within
Y
. For example, ifincY
is 7, every 7th element is used.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_zsymm
Multiplies a matrix by a symmetric matrix (doubleprecision 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 rowmajor (C) or columnmajor (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
A
andC
. N
Number of columns in matrices
B
andC
. 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 = A^{T}
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_zsyr2k
Performs a rank2k update of a symmetric matrix (doubleprecision 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 rowmajor (C) or columnmajor (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
A
andB
iftrans='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*B^{T} + alpha*B*A^{T} +beta*C
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_zsyrk
Rankk update—multiplies a symmetric matrix by its transpose and adds a second matrix (doubleprecision 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 rowmajor (C) or columnmajor (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 matrixA
is 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*A^{T} + beta*C
; if transposed, calculates alpha*A^{T}*A + beta*C
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_ztbmv
Scales a triangular band matrix, then multiplies by a vector (doubleprecision 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 rowmajor (C) or columnmajor (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
Halfbandwidth of matrix
A
. A
Matrix
A
. lda
The leading dimension of array containing matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_ztpmv
Multiplies a triangular matrix by a vector, then adds a vector (doubleprecision 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 rowmajor (C) or columnmajor (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
A
and the number of elements in vectorsx
andy
. Ap
Matrix
A
. X
Vector
x
. incX
Stride within
X
. For example, ifincX
is 7, every 7th element is used.
Discussion
Computes A*x
, A^{T}*x
, or conjg(A^{T})*x
and stores the results in X
.
Availability
 Available in iOS 4.0 and later.
Declared In
cblas.h
cblas_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 rowmajor (C) or columnmajor (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
B
on entry. Overwritten with vectorX
on return. incX
Stride within
X
. For example, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
cblas_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 rowmajor (C) or columnmajor (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.h
cblas_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 rowmajor (C) or columnmajor (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, ifincX
is 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.h
SetBLASParamErrorProc
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.h
Data 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.h
Constants
CBLAS_ORDER
Indicates whether a matrix is in rowmajor or columnmajor order.
enum CBLAS_ORDER { CblasRowMajor=101, CblasColMajor=102 }; typedef enum CBLAS_ORDER CBLAS_ORDER;
Constants
CblasRowMajor
Rowmajor order.
Available in iOS 4.0 and later.
Declared in
cblas.h
.CblasColMajor
Columnmajor order.
Available in iOS 4.0 and later.
Declared in
cblas.h
.
CBLAS_TRANSPOSE
Indicates 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
CblasNoTrans
No transposition.
Available in iOS 4.0 and later.
Declared in
cblas.h
.CblasTrans
For matrix
X
, useX(T)
.Available in iOS 4.0 and later.
Declared in
cblas.h
.CblasConjTrans
For matrix
X
, useX(H)
(conjugate or Hermitian transposition).Available in iOS 4.0 and later.
Declared in
cblas.h
.AtlasConj
Available 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
CblasUpper
Use the upper triangle of the matrix.
Available in iOS 4.0 and later.
Declared in
cblas.h
.CblasLower
Use 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 unitdiagonal (diagonal elements are all equal to 1).
enum CBLAS_DIAG { CblasNonUnit=131, CblasUnit=132 }; typedef enum CBLAS_DIAG CBLAS_DIAG;
Constants
CblasNonUnit
The triangular matrix is not unitdiagonal.
Available in iOS 4.0 and later.
Declared in
cblas.h
.CblasUnit
The triangular matrix is unitdiagonal.
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
CblasLeft
Multiply A*B.
Available in iOS 4.0 and later.
Declared in
cblas.h
.CblasRight
Multiply B*A.
Available in iOS 4.0 and later.
Declared in
cblas.h
.
Copyright © 2005, 2013 Apple Inc. All Rights Reserved. Terms of Use  Privacy Policy  Updated: 20130423