 HessenbergForm - Maple Help

LinearAlgebra

 HessenbergForm
 reduce a square Matrix to upper Hessenberg form Calling Sequence HessenbergForm(A, out, ip, options, outopts) Parameters

 A - square Matrix out - (optional) equation of the form output = obj where obj is one of 'H', 'Q', or 'NAG', or a list containing one or more of these names; selects result objects to compute ip - (optional) equation of the form inplace=true or false; specifies if output overwrites input options - (optional); constructor options for the result object(s) outopts - (optional) equation(s) of the form outputoptions[o] = list where o is one of 'H', 'Q', or 'NAG'; constructor options for the result object(s) Description

 • The HessenbergForm(A) function returns a Matrix in upper Hessenberg form. This routine operates in the floating-point domain. Hence, the entries in Matrix A must necessarily be of type complex(numeric).
 An upper Hessenberg Matrix has nonzero entries only in the upper triangle and on the first subdiagonal.
 • The original Matrix A, the orthogonal Matrix Q, and the upper Hessenberg Matrix H are related by $A=Q·H·\mathrm{Transpose}\left(Q\right)$.
 If A is complex, then Q is unitary and $A=Q·H·\mathrm{HermitianTranspose}\left(Q\right)$.
 • If the Matrix A does not have a floating-point datatype, then a working copy which does is made in agreement with the environment variable UseHardwareFloats.
 • The output option (out) determines the content of the returned expression sequence.
 Depending on what is included in the output option, an expression sequence containing one or both of the factors H (the upper Hessenberg form) and Q (the orthogonal reduction Matrix) can be returned. If output is a list, the objects are returned in the same order as specified in the list.
 If NAG is included in the output list, then the returned objects are an expression sequence consisting of a Matrix with the same dimensions as A, followed by a Vector of appropriate dimension. The upper triangle and the first subdiagonal of the Matrix contain the upper Hessenberg form of A, while the remaining lower portion, along with the returned Vector, contain details of the unitary reduction Matrix.
 • The inplace option (ip) determines where the result is returned. If given as inplace=true, the result overwrites the first argument. If given as inplace=false, or if this option is not included in the calling sequence, the result is returned in a new Matrix.
 The condition inplace=true can be abbreviated to inplace.
 The inplace option must be used with caution since, if the operation fails, the original Matrix argument may be corrupted.
 • The constructor options provide additional information (readonly, shape, storage, order, datatype, and attributes) to the Matrix or Vector constructor that builds the result. These options may also be provided in the form outputoptions[o]=[...], where [...] represents a Maple list.  If a constructor option is provided in both the calling sequence directly and in an outputoptions[o] option, the latter takes precedence (regardless of the order).
 The following list indicates permissible values for index [o] of outputoptions with their corresponding meaning.

 H upper Hessenberg form Q orthogonal reduction Matrix NAG NAG format of the reduction

 • The inplace and constructor options are mutually exclusive.
 • This function is part of the LinearAlgebra package, and so it can be used in the form HessenbergForm(..) only after executing the command with(LinearAlgebra). However, it can always be accessed through the long form of the command by using LinearAlgebra[HessenbergForm](..).
 • This function is part of the LinearAlgebra package, and so it can be used in the form HessenbergForm(..) only after executing the command with(LinearAlgebra). However, it can always be accessed through the long form of the command by using LinearAlgebra[HessenbergForm](..). Examples

 > $\mathrm{with}\left(\mathrm{LinearAlgebra}\right):$
 > $A≔\mathrm{RandomMatrix}\left(4,\mathrm{datatype}=\mathrm{float}\right)$
 ${A}{≔}\left[\begin{array}{cccc}{89.}& {-70.}& {-7.}& {-25.}\\ {-55.}& {13.}& {12.}& {40.}\\ {-67.}& {-58.}& {-53.}& {97.}\\ {77.}& {-94.}& {21.}& {43.}\end{array}\right]$ (1)
 > $\mathrm{HessenbergForm}\left(A\right)$
 $\left[\begin{array}{cccc}{89.}& {20.6479075379361}& {19.3695649707596}& {-69.0831663080693}\\ {115.943951976806}& {-36.6902477125642}& {-0.840905074177662}& {-59.6220150029191}\\ {0.}& {-132.583346753305}& {47.0383936704745}& {46.5629644437995}\\ {0.}& {0.}& {-41.3070781612517}& {-7.34814595791030}\end{array}\right]$ (2)
 > $B≔⟨⟨1+I,4,7⟩|⟨2,5-I,8⟩|⟨3,6,9I⟩⟩$
 ${B}{≔}\left[\begin{array}{ccc}{1}{+}{I}& {2}& {3}\\ {4}& {5}{-}{I}& {6}\\ {7}& {8}& {9}{}{I}\end{array}\right]$ (3)
 > $H,Q≔\mathrm{HessenbergForm}\left(B,\mathrm{output}=\left['H','Q'\right]\right)$
 ${H}{,}{Q}{≔}\left[\begin{array}{ccc}{1.}{+}{I}& {-3.59700730308704}{+}{0.}{}{I}& {0.183014321334235}{-}{0.167464084881000}{}{I}\\ {-8.06225774829855}{+}{0.}{}{I}& {7.26153846153846}{+}{6.53846153846154}{}{I}& {-2.04063807945056}{+}{7.70617579225405}{}{I}\\ {0.}{}{I}& {-6.38111117922708}{+}{0.}{}{I}& {-2.26153846153846}{+}{1.46153846153846}{}{I}\end{array}\right]{,}\left[\begin{array}{ccc}{1.}{+}{0.}{}{I}& {0.}{+}{0.}{}{I}& {0.}{+}{0.}{}{I}\\ {0.}{+}{0.}{}{I}& {-0.496138938356834}{+}{0.}{}{I}& {0.640550124669824}{-}{0.586124297083499}{}{I}\\ {0.}{+}{0.}{}{I}& {-0.868243142124459}{-}{0.}{}{I}& {-0.366028642668471}{+}{0.334928169762000}{}{I}\end{array}\right]$ (4)
 > $\mathrm{map}\left(\mathrm{fnormal},Q·H·\mathrm{HermitianTranspose}\left(Q\right)\right)$
 $\left[\begin{array}{ccc}{1.}{+}{I}& {2.000000000}{+}{0.}{}{I}& {3.000000000}{-}{0.}{}{I}\\ {4.000000000}{+}{0.}{}{I}& {5.000000000}{-}{I}& {6.000000000}{-}{0.}{}{I}\\ {7.000000000}{+}{0.}{}{I}& {8.000000000}{+}{0.}{}{I}& {0.}{+}{9.000000000}{}{I}\end{array}\right]$ (5)
 > $\mathrm{map}\left(\mathrm{fnormal},\mathrm{HermitianTranspose}\left(Q\right)·Q\right)$
 $\left[\begin{array}{ccc}{1.}{+}{0.}{}{I}& {0.}{+}{0.}{}{I}& {0.}{+}{0.}{}{I}\\ {0.}{+}{0.}{}{I}& {1.000000000}{+}{0.}{}{I}& {0.}{-}{0.}{}{I}\\ {0.}{+}{0.}{}{I}& {0.}{+}{0.}{}{I}& {1.000000000}{+}{0.}{}{I}\end{array}\right]$ (6)