Function

# cblas_crotg(_:_:_:_:)

Constructs a complex Givens rotation.

SDKs

- iOS 4.0+
- macOS 10.2+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 2.0+

## Parameters

`a`

Complex value `a`

. Overwritten on output.

`b`

`c`

Real value `c`

. Unused on entry. Overwritten on return with the value `cos(θ)`

.

`s`

Complex value `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`

.

## See Also

### Single-Precision Complex Matrix Functions

`func cblas_cgbmv(CBLAS_ORDER, CBLAS_TRANSPOSE, Int32, Int32, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Scales a general band matrix, then multiplies by a vector, then adds a vector (single-precision complex).

`func cblas_cgemm(CBLAS_ORDER, CBLAS_TRANSPOSE, CBLAS_TRANSPOSE, Int32, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Multiplies two matrices (single-precision complex).

`func cblas_cgemv(CBLAS_ORDER, CBLAS_TRANSPOSE, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Multiplies a matrix by a vector (single-precision complex).

`func cblas_cgerc(CBLAS_ORDER, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeMutableRawPointer!, Int32)`

Multiplies vector X by the conjugate transpose of vector Y, then adds matrix A (single-precision complex).

`func cblas_cgeru(CBLAS_ORDER, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeMutableRawPointer!, Int32)`

Multiplies vector X by the transpose of vector Y, then adds matrix A (single-precision complex).

`func cblas_chbmv(CBLAS_ORDER, CBLAS_UPLO, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Scales a Hermitian band matrix, then multiplies by a vector, then adds a vector (single-precision complex).

`func cblas_chemm(CBLAS_ORDER, CBLAS_SIDE, CBLAS_UPLO, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Multiplies two Hermitian matrices (single-precision complex), then adds a third (with scaling).

`func cblas_chemv(CBLAS_ORDER, CBLAS_UPLO, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Scales and multiplies a Hermitian matrix by a vector, then adds a second (scaled) vector.

`func cblas_cher2(CBLAS_ORDER, CBLAS_UPLO, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeMutableRawPointer!, Int32)`

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`

.

`func cblas_cher2k(CBLAS_ORDER, CBLAS_UPLO, CBLAS_TRANSPOSE, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, Float, UnsafeMutableRawPointer!, Int32)`

Performs a rank-2k update of a complex Hermitian matrix (single-precision complex).

`func cblas_cherk(CBLAS_ORDER, CBLAS_UPLO, CBLAS_TRANSPOSE, Int32, Int32, Float, UnsafeRawPointer!, Int32, Float, UnsafeMutableRawPointer!, Int32)`

Rank-k update—multiplies a Hermitian matrix by its transpose and adds a second matrix (single precision).

`func cblas_chpmv(CBLAS_ORDER, CBLAS_UPLO, Int32, UnsafeRawPointer!, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Scales a packed hermitian matrix, multiplies it by a vector, and adds a scaled vector.

`func cblas_chpr2(CBLAS_ORDER, CBLAS_UPLO, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeMutableRawPointer!)`

Multiplies a vector times the conjugate transpose of a second vector and vice-versa, sums the results, and adds a matrix.

`func cblas_csymm(CBLAS_ORDER, CBLAS_SIDE, CBLAS_UPLO, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Multiplies a matrix by a symmetric matrix (single-precision complex).

`func cblas_csyr2k(CBLAS_ORDER, CBLAS_UPLO, CBLAS_TRANSPOSE, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Performs a rank-2k update of a symmetric matrix (single-precision complex).

`func cblas_csyrk(CBLAS_ORDER, CBLAS_UPLO, CBLAS_TRANSPOSE, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeRawPointer!, UnsafeMutableRawPointer!, Int32)`

Rank-k update—multiplies a symmetric matrix by its transpose and adds a second matrix (single-precision complex).

`func cblas_ctbmv(CBLAS_ORDER, CBLAS_UPLO, CBLAS_TRANSPOSE, CBLAS_DIAG, Int32, Int32, UnsafeRawPointer!, Int32, UnsafeMutableRawPointer!, Int32)`

Scales a triangular band matrix, then multiplies by a vector (single-precision compex).

`func cblas_ctrmm(CBLAS_ORDER, CBLAS_SIDE, CBLAS_UPLO, CBLAS_TRANSPOSE, CBLAS_DIAG, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeMutableRawPointer!, Int32)`

Scales a triangular matrix and multiplies it by a matrix.

`func cblas_ctrsm(CBLAS_ORDER, CBLAS_SIDE, CBLAS_UPLO, CBLAS_TRANSPOSE, CBLAS_DIAG, Int32, Int32, UnsafeRawPointer!, UnsafeRawPointer!, Int32, UnsafeMutableRawPointer!, Int32)`

Solves a triangular system of equations with multiple values for the right side.