solve A . X = B where A is in upper row echelon form - Maple Help

Online Help

All Products    Maple    MapleSim

Home : Support : Online Help : Mathematics : Linear Algebra : LinearAlgebra Package : Solvers : LinearAlgebra/BackwardSubstitute

LinearAlgebra[BackwardSubstitute] - solve A . X = B where A is in upper row echelon form

LinearAlgebra[ForwardSubstitute] - solve A . X = B where A is in lower row echelon form

Calling Sequence

BackwardSubstitute(A, B, t, ip, options)

ForwardSubstitute(A, B, t, ip, options)




row echelon form Matrix



(optional) Matrix or Vector



(optional) equation of the form free = symbol; variable for parametrization of infinite solution sets



(optional) BooleanOpt(inplace); specifies if output overwrites parameter B when A is square



(optional); constructor options for the transformation Matrix C



The BackwardSubstitute(A, B) function, where A is an upper row echelon Matrix,  returns a solution to the equation A.X=B.


The ForwardSubstitute(A, B) function, where A is a lower row echelon Matrix,  returns a solution to the equation A.X=B.


For each column b of B, this routine performs backwards (or forwards) substitution to obtain a solution x of A.x=b. These solution Vectors form a Matrix (or, singly, a Vector) solution which is returned. If no such solution Vector x exists for any column b (e.g., both A is not upper (or lower) triangular and the substitution is inconsistent), then an error is returned.


If the substitution does not result in a unique solution, then the infinite family of possible solutions will be parametrized as follows:


*  If B is a Vector, then the solution is parametrized by t[1], t[2], etc, as needed.


*  If B is a Matrix, then the jth column of the solution Matrix is parametrized by t[1,j], t[2,j], etc, as needed.


If the parameter t is not provided, then an unassigned name _t<#> is generated.  For example, if _t0, _t1.._t<i> are all assigned, but _t<i+1> is not assigned, then _t<i+1> is the generated name.


If B is not included in the calling sequence, A is assumed to be an augmented Matrix.


The inplace option (ip) determines where the result is returned.  If given as inplace=true and A is a square Matrix, the result overwrites the second argument B. If given as inplace=false, or if this option is not included in the calling sequence, the result is returned in a new Matrix or Vector.


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=[...], where [...] represents a Maple list.  If a constructor option is provided in both the calling sequence directly and in an outputoptions option, the latter takes precedence (regardless of the order).


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 BackwardSubstitute(..) only after executing the command with(LinearAlgebra). However, it can always be accessed through the long form of the command by using LinearAlgebra[BackwardSubstitute](..).

























See Also

Matrix, type[BooleanOpt]

Download Help Document

Was this information helpful?

Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam