Question: Repetitive mapping in Maple?

I have occasionally a need to map a function over the components of an expression; but not just at the top level---which map() does---but to an arbitrary level. One application is e.g. to throw simplify at subexpressions of a complicated object. Sooner or later I will want to specify the deepest level also... I looked through the docs and Help but could not find anything like that. I had expected map[n]() to do something like this, but it does not.

Does Maple have a mechanism for this or do I need to write one? I am familiar with things like op() and the various looping constructs so I think it is possible for me to cook something up, but this seems basic enough that I'd think there was already a mechanism in place. Also, I would expect such a mapping programmed at a lower level to be more efficient than a user-written procedure.

Mac Dude.

Please Wait...