axiom-mail
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Axiom-mail] A little simplification problem


From: Bill Page
Subject: Re: [Axiom-mail] A little simplification problem
Date: Fri, 1 Aug 2008 10:43:44 -0400

On Fri, Aug 1, 2008 at 10:18 AM, Alasdair McAndrew wrote:

> f(n)==7^n
> f(n+1)-7*f(n)
> simplify(%)
>
> What do I need to do to enable the final statement to produce 0?
>

You might use a pattern like this:

(1) -> f(n)==7^n
                                                    Type: Void
(2) -> f(n+1)-7*f(n)

         n + 1      n
   (2)  7      - 7 7
                                                     Type: Expression Integer

(3) -> expandPowers := rule x^(n+1) == x*x^n

         n + 1       n
   (3)  x      == x x
                        Type: RewriteRule(Integer,Integer,Expression Integer)

(4) -> expandPowers( %% 2)

   (4)  0
                                                     Type: Expression Integer

---------

Regards,
Bill Page.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]