### The Maxima on-line user's manual

Algebra Calculator

#### Apply1

Function: apply1 (<expr>, <rule_1>, ..., <rule_n>) Repeatedly applies <rule_1> to <expr> until it fails, then repeatedly applies the same rule to all subexpressions of <expr>, left to right, until <rule_1> has failed on all subexpressions. Call the result of transforming <expr> in this manner <expr_2>. Then <rule_2> is applied in the same fashion starting at the top of <expr_2>. When <rule_n> fails on the final subexpression, the result is returned.

`maxapplydepth` is the depth of the deepest subexpressions processed by `apply1` and `apply2`.

See also `applyb1`, `apply2`, and `let`.

```(%o1)                                true
(%i2) ```

### Related Examples

##### apply1-cos-defrule-sin-true

mathdeclare([x,y], tr...

defrule(extrig1,sin(x...

apply1(E,extrig1);

Calculate

##### apply1-cos-defrule-sin-true

mathdeclare([x,y], tr...

defrule(extrig1,sin(x...

apply1(E,extrig1);

Calculate

Calculate

Calculate

##### apply1-cos-defrule-sin-true

mathdeclare([x,y], tr...

defrule(extrig1,sin(x...

apply1(E,extrig1);

Calculate

##### apply1-binomial-block-cos-defrule-delta-diff-ev-exp-factor-freeof-kron_delta-lambda-linear-log-matchdeclare-remvalue-return-sin-subst

remvalue(n,z);

matchdeclare(a,lambda...

matchdeclare(b,lambda...

Calculate

##### apply1-binomial-block-cos-defrule-delta-diff-ev-exp-factor-freeof-kron_delta-lambda-linear-log-matchdeclare-remvalue-return-sin-subst

remvalue(n,z);

matchdeclare(a,lambda...

matchdeclare(b,lambda...

Calculate

Calculate

Calculate