fortran-lang/stdlib

Add a `hermitian` function to `stdlib_linalg`

Closed this issue · 0 comments

Motivation

I've been working quite a lot with complex arrays recently and ended-up having to write conj(transpose(A)) quite often. Would encapsulating these into a hermitian function be of use for stdlib_linalg? It is more sugar-coating than anything but could still be useful to reduce a bit code bloat.

(ping @perazz, @jvdp1, @jalvesz)

Prior Art

  • In Julia, if $A \in \mathbb{C}^{m \times n}$, the syntax A' is equivalent to $A^H$.
  • In Numpy, if A is an np.matrix object, then A.H returns the hermitian as well.
  • Currently in Fortran (as far as I know), the Hermitian needs to be computed using conj(transpose(A)) or transpose(conj(A)).

Additional Information

No response