ReplaceRepeated - Maple Help

# Online Help

###### All Products    Maple    MapleSim

MmaTranslator[Mma]

 ReplaceRepeated
 perform replacements until expression no longer changes

 Calling Sequence ReplaceRepeated(arguments)

Parameters

 arguments - Maple translation of the Mathematica command arguments

Description

 • The ReplaceRepeated command performs replacements on a specified expression until the expression no longer changes.

Examples

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

Use the command with the Maple translation.

 > $\mathrm{ReplaceRepeated}\left(x+{x}^{2},\left[x=b,{x}^{2}=x\right]\right)$
 ${2}{}{b}$ (1)

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

 > $\mathrm{with}\left(\mathrm{MmaTranslator}\right):$
 > $\mathrm{FromMma}\left(\mathrm{ReplaceRepeated\left[x + x^2, \left\{x -> b, x^2->x\right\}\right]},\mathrm{evaluate}\right)$
 ${2}{}{b}$ (2)

 See Also