File tree Expand file tree Collapse file tree 2 files changed +32
-1
lines changed Expand file tree Collapse file tree 2 files changed +32
-1
lines changed Original file line number Diff line number Diff line change @@ -509,6 +509,37 @@ Returns a `logical` scalar that is `.true.` if the input matrix is skew-symmetri
509509{!example/linalg/example_is_skew_symmetric.f90!}
510510```
511511
512+ ## ` hermitian ` - Compute the Hermitian version of a rank-2 matrix
513+
514+ ### Status
515+
516+ Experimental
517+
518+ ### Description
519+
520+ Compute the Hermitian version of a rank-2 matrix.
521+ For ` complex ` matrices, the function returns the conjugate transpose (` conjg(transpose(a)) ` ).
522+ For ` real ` or ` integer ` matrices, the function returns the transpose (` transpose(a) ` ).
523+
524+ ### Syntax
525+
526+ ` h = ` [[ stdlib_linalg(module): hermitian (interface)]] ` (a) `
527+
528+ ### Arguments
529+
530+ ` a ` : Shall be a rank-2 array of type ` integer ` , ` real ` , or ` complex ` . The input matrix ` a ` is not modified.
531+
532+ ### Return value
533+
534+ Returns a rank-2 array of the same shape and type as ` a ` . If ` a ` is of type ` complex ` , the Hermitian matrix is computed as ` conjg(transpose(a)) ` .
535+ For ` real ` or ` integer ` types, it is equivalent to ` transpose(a) ` .
536+
537+ ### Example
538+
539+ ``` fortran
540+ {!example/linalg/example_hermitian.f90!}
541+ ```
542+
512543## ` is_hermitian ` - Checks if a matrix is Hermitian
513544
514545### Status
Original file line number Diff line number Diff line change @@ -312,7 +312,7 @@ module stdlib_linalg
312312 !! AH = hermitian(A)
313313 !! ```
314314 !!
315- !! [Specification](../page/specs/stdlib_linalg.html#hermitian)
315+ !! [Specification](../page/specs/stdlib_linalg.html#hermitian-compute-the-hermitian-version-of-a-rank-2-matrix )
316316 !!
317317
318318 #:for k1, t1 in RCI_KINDS_TYPES
You can’t perform that action at this time.
0 commit comments