%PAGEEIG Page-wise eigenvalue decomposition.
%   D = PAGEEIG(A) returns an N-D array D, where each page D(:,:,i) is a
%   column vector containing the eigenvalues of the square matrix A(:,:,i).
%
%   [V,D] = PAGEEIG(A) computes the eigenvalue decomposition of each page
%   of N-D array A:   
%              A(:,:,i) * V(:,:,i) = V(:,:,i) * D(:,:,i)
%
%   D contains pages of diagonal matrices representing the eigenvalues, and
%   V contains pages of the corresponding eigenvectors.
% 
%   [V,D,W] = PAGEEIG(A) also returns W, whose pages are the corresponding
%   left eigenvectors such that:
%             W(:,:,i)' * A(:,:,i) = D(:,:,i) * W(:,:,i)'.
%
%   If A has more than 3 dimensions, then PAGEEIG returns N-D arrays that
%   contain the same dimensions:
%      A(:,:,i,j,k) * V(:,:,i,j,k) = V(:,:,i,j,k) * D(:,:,i,j,k),
%     W(:,:,i,j,k)' * A(:,:,i,j,k) = D(:,:,i,j,k) * W(:,:,i,j,k)'.
%
%   [...] = PAGEEIG(A,"nobalance") performs the computation with balancing
%   disabled, which sometimes gives more accurate results for certain
%   problems with unusual scaling. "nobalance" is ignored for each
%   symmetric page in A, since those pages are already balanced.
%
%   [...] = PAGEEIG(A,"balance") is the same as PAGEEIG(A).
%
%   [...] = PAGEEIG(...,OUTPUTFORM) optionally specifies the output format
%   for the eigenvalues returned in D. OUTPUTFORM can be:
%
%      "vector" - Each page of D is a column vector.
%      "matrix" - Each page of D is a diagonal matrix.
%
%   See also EIG, PAGESVD, PAGENORM, PAGEMTIMES

%   Copyright 2022 The MathWorks, Inc.
%   Built-in function.
