Skip to content

num::hessenberg_shifted_factor

Defined in header <linear/factorization/hessenberg.hpp>

template <std::floating_point T, class Index>
void hessenberg_shifted_factor(std::complex<T> *work, const T *H, std::complex<T> shift,
                               idx n, Index *piv) noexcept;

Factor \(sI - H\) in place for an upper Hessenberg \(H\), in \(O(n^2)\).

Only one subdiagonal entry per column is eliminated, and pivoting compares it against the diagonal. This makes each shift of a Krylov resolvent cheap.

Parameters

  • work: In/out, n*n. Receives \(sI - H\) and its factors.
  • H: Upper Hessenberg matrix, n*n row-major, real.
  • shift: Complex shift \(s\).
  • n: Dimension.
  • piv: Output pivot record, length n.