Details of the LinearAlgebra Package
Basic Information
Description
List of LinearAlgebra Subpackages
Accessing LinearAlgebra Package Commands
List of LinearAlgebra Package Commands
Examples
This help page contains complete information about the LinearAlgebra package. For basic information on the LinearAlgebra package, see the LinearAlgebra help page.
The LinearAlgebra package is an efficient and robust suite of commands for performing computational linear algebra.
LinearAlgebra routines operate on three principal data structures: Matrices, Vectors, and scalars. For more information, see the Construct a Matrix, Construct a Vector, and About Data Structures in the LinearAlgebra Package help pages.
Full rectangular and sparse matrices are fully supported at the data structure level, as well as upper and lower triangular matrices, unit triangular matrices, banded matrices, and a variety of others. Further, symmetric, skew-symmetric, hermitian, and skew-hermitian are known qualifiers that are used appropriately to reduce storage and select amongst algorithms. For more information, see the Shapes and Storage Modes for Matrices and Vectors help page.
The following data types are handled efficiently: hardware floating-point numbers (both real and complex), hardware integers of various sizes, arbitrary-precision floating-point numbers (both real and complex), and general symbolic expressions. For increased compatibility with external routines, matrices can be stored in either C or Fortran order.
The LinearAlgebra and VectorCalculus packages supersede the deprecated linalg package. For information illustrating the differences between these packages, see the Linear Algebra Computations in Maple help page. For an example worksheet on migrating linalg code to the new packages, see examples/LinearAlgebraMigration.
The Modular subpackage provides a highly efficient suite of programmer tools for performing dense linear algebra computations in Z/m, the integers modulo m over the positive range.
The Generic subpackage uses generic implementations of algorithms for linear algebra over fields, Euclidean domains, integral domains and rings.
Each command in the LinearAlgebra package can be accessed by using either the long form or the short form of the command name in the command calling sequence.
The long form, LinearAlgebra:-command, is always available. The short form can be used after loading the package.
The following is a list of available commands.
`&x`
Add
Adjoint
BackwardSubstitute
BandMatrix
Basis
BezoutMatrix
BidiagonalForm
BilinearForm
CARE
CharacteristicMatrix
CharacteristicPolynomial
Column
ColumnDimension
ColumnOperation
ColumnSpace
CompanionMatrix
CompressedSparseForm
ConditionNumber
ConstantMatrix
ConstantVector
Copy
CreatePermutation
CrossProduct
DARE
DeleteColumn
DeleteRow
Determinant
Diagonal
DiagonalMatrix
Dimension
DotProduct
EigenConditionNumbers
Eigenvalues
Eigenvectors
Equal
ForwardSubstitute
FrobeniusForm
FromCompressedSparseForm
FromSplitForm
GaussianElimination
GenerateEquations
GenerateMatrix
GetResultDataType
GetResultShape
GivensRotationMatrix
GramSchmidt
HankelMatrix
HermiteForm
HermitianTranspose
HessenbergForm
HilbertMatrix
HouseholderMatrix
IdentityMatrix
IntersectionBasis
IsDefinite
IsOrthogonal
IsSimilar
IsUnitary
JordanBlockMatrix
JordanForm
KroneckerProduct
LeastSquares
LinearSolve
LUDecomposition
LyapunovSolve
Map
Map2
MatrixAdd
MatrixExponential
MatrixFunction
MatrixInverse
MatrixMatrixMultiply
MatrixNorm
MatrixPower
MatrixScalarMultiply
MatrixVectorMultiply
MinimalPolynomial
Minor
Multiply
Norm
Normalize
NullSpace
OuterProductMatrix
Permanent
Pivot
PopovForm
ProjectionMatrix
QRDecomposition
RandomMatrix
RandomVector
Rank
RationalCanonicalForm
ReducedRowEchelonForm
Row
RowDimension
RowOperation
RowSpace
ScalarMatrix
ScalarMultiply
ScalarVector
SchurForm
SingularValues
SmithForm
SplitForm
StronglyConnectedBlocks
SubMatrix
SubVector
SumBasis
SylvesterMatrix
SylvesterSolve
ToeplitzMatrix
Trace
Transpose
TridiagonalForm
UnitVector
VandermondeMatrix
VectorAdd
VectorAngle
VectorMatrixMultiply
VectorNorm
VectorScalarMultiply
ZeroMatrix
ZeroVector
Zip
To display the help page for a particular LinearAlgebra command, see Getting Help with a Command in a Package.
with⁡LinearAlgebra:
Construct a Matrix using shortcut notation
1|2|3,4|5|6
123456
Construct a Matrix with optional construction parameters
Matrix⁡1,2,3,4,5,6,readonly=true
Create a random Matrix.
A≔RandomMatrix⁡2,3
A≔9944−31299267
The inplace option saves memory and prevents creating new variable names for intermediate results.
RowOperation⁡A,1,2,inplace
2992679944−31
A
Create an upper triangular Matrix.
M≔RandomMatrix⁡5,outputoptions=shape=triangularupper
M≔69827−4−740−32−2−72−7600−932757000−77−98000033
Define two matrices.
A≔Matrix⁡2,5,1,3:
B≔Matrix⁡6,11,9,21:
Performing calculations in a casual usage scenario accepts optional arguments in any order.
MatrixAdd⁡A,B,1,−1
−4−6−8−18
See Also
examples/LA_Linear_Solve
examples/LA_NAG
examples/LA_options
LAIndex
module
UsingPackages
with
Download Help Document