Liking cljdoc? Tell your friends :D

org.soulspace.qclojure.domain.math.fastmath.complex-linear-algebra


cholesky-decompositionclj

(cholesky-decomposition A)
(cholesky-decomposition A eps)

Compute Cholesky decomposition A = L * L† for positive definite complex matrices.

Compute Cholesky decomposition A = L * L† for positive definite complex matrices.
sourceraw docstring

complex->realclj

(complex->real z)

Extract real part of a complex number, checking it's actually real.

Extract real part of a complex number, checking it's actually real.
sourceraw docstring

complex-matrix->real-matrixclj

(complex-matrix->real-matrix matrix)

Convert complex matrix to real matrix.

Convert complex matrix to real matrix.
sourceraw docstring

complex-matrix-shapeclj

(complex-matrix-shape matrix)

Get the shape of a matrix containing Complex elements.

Get the shape of a matrix containing Complex elements.
sourceraw docstring

complex-matrix?clj

(complex-matrix? m)

Test if m represents a complex matrix.

Test if m represents a complex matrix.
sourceraw docstring

complex-scalar?clj

(complex-scalar? x)

Test if x represents a complex scalar (Vec2 or complex map).

Test if x represents a complex scalar (Vec2 or complex map).
sourceraw docstring

complex-scaleclj

(complex-scale v scalar)

Scale a complex number by a scalar.

Scale a complex number by a scalar.
sourceraw docstring

complex-vector?clj

(complex-vector? v)

Test if v represents a complex vector.

Test if v represents a complex vector.
sourceraw docstring

complex?clj

(complex? x)

Test if x is a FastMath Vec2 complex number.

Test if x is a FastMath Vec2 complex number.
sourceraw docstring

condition-numberclj

(condition-number A)

Compute the condition number κ₂(A) = ||A||₂ * ||A⁻¹||₂ for a complex matrix A.

Compute the condition number κ₂(A) = ||A||₂ * ||A⁻¹||₂ for a complex matrix A.
sourceraw docstring

conjugate-transposeclj

(conjugate-transpose A)

Compute the conjugate transpose Aᴴ (Hermitian adjoint).

Compute the conjugate transpose Aᴴ (Hermitian adjoint).
sourceraw docstring

default-toleranceclj

source

diagonal?clj

(diagonal? A eps)

Check if a complex matrix A is diagonal (off-diagonal elements ≈ 0).

Check if a complex matrix A is diagonal (off-diagonal elements ≈ 0).
sourceraw docstring

eigen-generalclj

(eigen-general A)

Compute eigenvalues and eigenvectors of a general matrix.

Compute eigenvalues and eigenvectors of a general matrix.
sourceraw docstring

eigen-hermitianclj

(eigen-hermitian A)

Compute eigenvalues and eigenvectors of a Hermitian matrix A.

Compute eigenvalues and eigenvectors of a Hermitian matrix A.
sourceraw docstring

ensure-complexclj

(ensure-complex x)

Ensure input is a complex number.

Ensure input is a complex number.
sourceraw docstring

hadamard-productclj

(hadamard-product A B)

Compute the element-wise (Hadamard) product A ⊙ B.

Compute the element-wise (Hadamard) product A ⊙ B.
sourceraw docstring

hermitian?clj

(hermitian? A eps)

Check if a complex matrix A is Hermitian (A ≈ Aᴴ).

Check if a complex matrix A is Hermitian (A ≈ Aᴴ).
sourceraw docstring

inner-productclj

(inner-product x y)

Compute the inner product ⟨x|y⟩ of two complex vectors.

Compute the inner product ⟨x|y⟩ of two complex vectors.
sourceraw docstring

inverseclj

(inverse A)

Compute matrix inverse using Gaussian elimination for complex matrices.

Compute matrix inverse using Gaussian elimination for complex matrices.
sourceraw docstring

kronecker-productclj

(kronecker-product A B)

Compute the Kronecker (tensor) product A ⊗ B.

Compute the Kronecker (tensor) product A ⊗ B.
sourceraw docstring

lu-decompositionclj

(lu-decomposition A)

Compute LU decomposition of a complex matrix A = P * L * U.

Compute LU decomposition of a complex matrix A = P * L * U.
sourceraw docstring

matrix-addclj

(matrix-add A B)
source

matrix-expclj

(matrix-exp A)

Compute the matrix exponential exp(A) using eigendecomposition.

Compute the matrix exponential exp(A) using eigendecomposition.
sourceraw docstring

matrix-logclj

(matrix-log A)

Compute the principal matrix logarithm log(A) using eigendecomposition.

Compute the principal matrix logarithm log(A) using eigendecomposition.
sourceraw docstring

matrix-multiplyclj

(matrix-multiply A B)
source

matrix-negateclj

(matrix-negate A)
source

matrix-scaleclj

(matrix-scale A alpha)
source

matrix-sqrtclj

(matrix-sqrt A)

Compute the principal matrix square root √A using eigendecomposition.

Compute the principal matrix square root √A using eigendecomposition.
sourceraw docstring

matrix-subtractclj

(matrix-subtract A B)
source

matrix-vector-productclj

(matrix-vector-product A x)
source

norm2clj

(norm2 x)

Compute the Euclidean (L2) norm ||x||₂ of a complex vector x.

Compute the Euclidean (L2) norm ||x||₂ of a complex vector x.
sourceraw docstring

outer-productclj

(outer-product x y)

Compute the outer product x ⊗ y†.

Compute the outer product x ⊗ y†.
sourceraw docstring

positive-semidefinite?clj

(positive-semidefinite? A eps)

Check if a complex matrix A is positive semidefinite.

Check if a complex matrix A is positive semidefinite.
sourceraw docstring

projector-from-stateclj

(projector-from-state psi)

Create a projector matrix |ψ⟩⟨ψ| from a quantum state vector ψ.

Create a projector matrix |ψ⟩⟨ψ| from a quantum state vector ψ.
sourceraw docstring

qr-decompositionclj

(qr-decomposition A)

Compute QR decomposition of a complex matrix A = Q * R.

Compute QR decomposition of a complex matrix A = Q * R.
sourceraw docstring

real-matrix?clj

(real-matrix? matrix)

Check if a matrix contains only real numbers (zero imaginary parts).

Check if a matrix contains only real numbers (zero imaginary parts).
sourceraw docstring

solve-linearclj

(solve-linear A b)

Solve linear system using Gaussian elimination for complex matrices.

Solve linear system using Gaussian elimination for complex matrices.
sourceraw docstring

spectral-normclj

(spectral-norm A)

Compute the spectral norm ||A||₂ (largest singular value) of a complex matrix A.

Compute the spectral norm ||A||₂ (largest singular value) of a complex matrix A.
sourceraw docstring

state-normalizeclj

(state-normalize state)

Normalize a quantum state vector to unit norm.

Normalize a quantum state vector to unit norm.
sourceraw docstring

svdclj

(svd A)

Compute Singular Value Decomposition A = U * S * V† for complex matrices.

Compute Singular Value Decomposition A = U * S * V† for complex matrices.
sourceraw docstring

traceclj

(trace A)

Compute the trace Tr(A) = Σᵢ aᵢᵢ of a complex matrix A.

Compute the trace Tr(A) = Σᵢ aᵢᵢ of a complex matrix A.
sourceraw docstring

trace-one?clj

(trace-one? rho)
(trace-one? rho eps)

Check if a density matrix has trace equal to one (Tr(ρ) ≈ 1).

Check if a density matrix has trace equal to one (Tr(ρ) ≈ 1).
sourceraw docstring

transposeclj

(transpose A)

Compute the transpose of a complex matrix Aᵀ.

Compute the transpose of a complex matrix Aᵀ.
sourceraw docstring

unitary?clj

(unitary? U eps)

Check if a complex matrix U is unitary (Uᴴ U ≈ I).

Check if a complex matrix U is unitary (Uᴴ U ≈ I).
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close