(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.
(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.
(complex-matrix->real-matrix matrix)
Convert complex matrix to real matrix.
Convert complex matrix to real matrix.
(complex-matrix-shape matrix)
Get the shape of a matrix containing Complex elements.
Get the shape of a matrix containing Complex elements.
(complex-matrix? m)
Test if m represents a complex matrix.
Test if m represents a complex matrix.
(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).
(complex-scale v scalar)
Scale a complex number by a scalar.
Scale a complex number by a scalar.
(complex-vector? v)
Test if v represents a complex vector.
Test if v represents a complex vector.
(complex? x)
Test if x is a FastMath Vec2 complex number.
Test if x is a FastMath Vec2 complex number.
(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.
(conjugate-transpose A)
Compute the conjugate transpose Aᴴ (Hermitian adjoint).
Compute the conjugate transpose Aᴴ (Hermitian adjoint).
(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).
(eigen-general A)
Compute eigenvalues and eigenvectors of a general matrix.
Compute eigenvalues and eigenvectors of a general matrix.
(eigen-hermitian A)
Compute eigenvalues and eigenvectors of a Hermitian matrix A.
Compute eigenvalues and eigenvectors of a Hermitian matrix A.
(ensure-complex x)
Ensure input is a complex number.
Ensure input is a complex number.
(hadamard-product A B)
Compute the element-wise (Hadamard) product A ⊙ B.
Compute the element-wise (Hadamard) product A ⊙ B.
(hermitian? A eps)
Check if a complex matrix A is Hermitian (A ≈ Aᴴ).
Check if a complex matrix A is Hermitian (A ≈ Aᴴ).
(inner-product x y)
Compute the inner product ⟨x|y⟩ of two complex vectors.
Compute the inner product ⟨x|y⟩ of two complex vectors.
(inverse A)
Compute matrix inverse using Gaussian elimination for complex matrices.
Compute matrix inverse using Gaussian elimination for complex matrices.
(kronecker-product A B)
Compute the Kronecker (tensor) product A ⊗ B.
Compute the Kronecker (tensor) product A ⊗ B.
(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.
(matrix-exp A)
Compute the matrix exponential exp(A) using eigendecomposition.
Compute the matrix exponential exp(A) using eigendecomposition.
(matrix-log A)
Compute the principal matrix logarithm log(A) using eigendecomposition.
Compute the principal matrix logarithm log(A) using eigendecomposition.
(matrix-sqrt A)
Compute the principal matrix square root √A using eigendecomposition.
Compute the principal matrix square root √A using eigendecomposition.
(norm2 x)
Compute the Euclidean (L2) norm ||x||₂ of a complex vector x.
Compute the Euclidean (L2) norm ||x||₂ of a complex vector x.
(outer-product x y)
Compute the outer product x ⊗ y†.
Compute the outer product x ⊗ y†.
(positive-semidefinite? A eps)
Check if a complex matrix A is positive semidefinite.
Check if a complex matrix A is positive semidefinite.
(projector-from-state psi)
Create a projector matrix |ψ⟩⟨ψ| from a quantum state vector ψ.
Create a projector matrix |ψ⟩⟨ψ| from a quantum state vector ψ.
(qr-decomposition A)
Compute QR decomposition of a complex matrix A = Q * R.
Compute QR decomposition of a complex matrix A = Q * R.
(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).
(solve-linear A b)
Solve linear system using Gaussian elimination for complex matrices.
Solve linear system using Gaussian elimination for complex matrices.
(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.
(state-normalize state)
Normalize a quantum state vector to unit norm.
Normalize a quantum state vector to unit norm.
(svd A)
Compute Singular Value Decomposition A = U * S * V† for complex matrices.
Compute Singular Value Decomposition A = U * S * V† for complex matrices.
(trace A)
Compute the trace Tr(A) = Σᵢ aᵢᵢ of a complex matrix A.
Compute the trace Tr(A) = Σᵢ aᵢᵢ of a complex matrix A.
(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).
(transpose A)
Compute the transpose of a complex matrix Aᵀ.
Compute the transpose of a complex matrix Aᵀ.
(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).
cljdoc builds & hosts documentation for Clojure/Script libraries
Ctrl+k | Jump to recent docs |
← | Move to previous article |
→ | Move to next article |
Ctrl+/ | Jump to the search field |