element-wise division of Array entries - Maple Help

Online Help

All Products    Maple    MapleSim


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

ArrayTools[ElementDivide] - element-wise division of Array entries

ArrayTools[ElementMultiply] - element-wise multiplication of Array entries

ArrayTools[ElementPower] - element-wise power of Array entries

Calling Sequence

ElementMultiply(A,B)

ElementDivide(A,B)

ElementPower(A,B)

Parameters

A

-

scalar, Matrix, Vector, or Array

B

-

scalar, Matrix, Vector, or Array

Description

• 

These commands apply operations on individual elements of an Array. If one of A or B are scalars and the other is an Array, the operation is mapped over the Array.  If both A or B are Arrays of the same size, then the operation is applied using zip.

• 

These functions are part of the ArrayTools package, so they can be used in the short form ElementMultiply(..), ElementDivide(..), or ElementPower(..) only after executing the command with(ArrayTools).  However, they can always be accessed through the long form of the commands by using ArrayTools[ElementMultiply](..), ArrayTools[ElementDivide](..), or ArrayTools[ElementPower(..), respectively.

Examples

withArrayTools:

ElementPowerArraya,b,c,2

a2b2c2

(1)

ElementDivideArraya,b,c,Arraye,f,g

aebfcg

(2)

ElementMultiply3,Arraya,b,c

3a3b3c

(3)

See Also

ArrayTools, map, operators/elementwise, zip


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