ArrayTools - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Low-level Manipulation : Matrices, Vectors, and Arrays : ArrayTools : ArrayTools/UpperTriangle

ArrayTools

  

UpperTriangle

  

return the upper triangular region of a Matrix

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

UpperTriangle(A)

UpperTriangle(A,k)

Parameters

A

-

Matrix, Vector, Array, or scalar

k

-

(optional) integer

Description

• 

For a matrix A, the UpperTriangle(A) command returns a matrix R where R[i,j] = A[i,j] when R[i,j] is on or above the main diagonal of R. R[i,j] = 0 otherwise.

• 

For a matrix A, the UpperTriangle(A,k) command returns a matrix R where R[i,j] = A[i,j] when R[i,j] is on or above the diagonal of R indexed by k. R[i,j] = 0 otherwise.

• 

The diagonals of a matrix are indexed using signed integers, where the main diagonal has index 0. Superdiagonals are indexed with positive integers and subdiagonals are indexed with negative integers.

• 

This function is part of the ArrayTools package, so it can be used in the short form UpperTriangle(..) only after executing the command with(ArrayTools).  However, it can always be accessed through the long form of the command by using ArrayTools[UpperTriangle](..).

Examples

withArrayTools:

AMatrix1,2,1,4,5,6,2,8,1

A:=121456281

(1)

UpperTriangleA

121056001

(2)

UpperTriangleA,1

021006000

(3)

UpperTriangleA,1

121456081

(4)

See Also

ArrayTools

ArrayTools[Diagonal]

ArrayTools[LowerTriangle]

 


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