MapAll - Maple Help

# Online Help

###### All Products    Maple    MapleSim

MmaTranslator[Mma]

 MapAll
 apply a function to every subexpression

 Calling Sequence MapAll(arguments)

Parameters

 arguments - Maple translation of the Mathematica command arguments

Description

 • The MapAll command applies a function to every subexpression in the specified expression.

Examples

 > $\mathrm{with}\left(\mathrm{MmaTranslator}\left[\mathrm{Mma}\right]\right):$

Use the command with the Maple translation.

 > $\mathrm{MapAll}\left(f,\left[\left[a,b\right],\left[c,d\right]\right]\right)$
 ${f}{}\left(\left[{f}{}\left(\left[{f}{}\left({a}\right){,}{f}{}\left({b}\right)\right]\right){,}{f}{}\left(\left[{f}{}\left({c}\right){,}{f}{}\left({d}\right)\right]\right)\right]\right)$ (1)

Alternatively, you can use the FromMma command with the evaluate option specified.

 > $\mathrm{with}\left(\mathrm{MmaTranslator}\right):$
 > $\mathrm{FromMma}\left(\mathrm{MapAll\left[f, \left\{\left\{a, b\right\}, \left\{c, d\right\}\right\}\right]},\mathrm{evaluate}\right)$
 ${f}{}\left(\left[{f}{}\left(\left[{f}{}\left({a}\right){,}{f}{}\left({b}\right)\right]\right){,}{f}{}\left(\left[{f}{}\left({c}\right){,}{f}{}\left({d}\right)\right]\right)\right]\right)$ (2)

 See Also