ishermitian
Check whether a matrix is hermitian
Syntax
t = ishermitian(A)
Arguments
- A
real or complex square matrix.
- t
boolean value (%t or %f). Returns %t if the matrix is Hermitian, %f otherwise.
Description
ishermitian returns %t if the matrix A is hermitian, that is if A* = A, where
A* denotes the conjugate transpose of A.
Equivalently, a matrix is hermitian if A(i,j) = conj(A(j,i)) for all indices i and j.
And diagonal elements must be real.
Examples
X = [1 %i; -%i 2]; ishermitian(X) // %t
X = [1 %i; %i 2]; ishermitian(X) // %f
X = [1 2; 2 3]; ishermitian(X) // %t
See also
- issymmetric — Check whether a matrix is symmetric
- conj — 共役
- isequal — tests the strict global equality between several objects, without equivalences
- quote — (') 転置演算子, 文字列デリミタ
History
| バージョン | 記述 |
| 2026.1.0 | Function added. |
| Report an issue | ||
| << isequal | Elementary Functions | issymmetric >> |