## open-axiom-help — Discussions about uses of OpenAxiom

You can subscribe to this list here.

 2008 2009 2010 2011 2012 2013 2014 Jan (4) Feb (2) Mar Apr May Jun Jul Aug (2) Sep Oct (27) Nov Dec (6) Jan (3) Feb Mar Apr (1) May Jun (27) Jul Aug Sep (3) Oct (22) Nov (12) Dec Jan (11) Feb (3) Mar (2) Apr (11) May (29) Jun (59) Jul Aug (3) Sep (2) Oct (8) Nov (3) Dec Jan (5) Feb Mar Apr (6) May Jun Jul (13) Aug (4) Sep (4) Oct (19) Nov Dec (2) Jan (2) Feb (1) Mar (3) Apr May Jun Jul (1) Aug Sep Oct Nov Dec Jan Feb Mar Apr May (78) Jun (10) Jul Aug Sep Oct Nov Dec (2) Jan (2) Feb Mar Apr May Jun Jul Aug Sep (1) Oct (1) Nov Dec
S M T W T F S
1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23
(3)
24

25

26

27

28

29

30

31

Showing 3 results of 3

 Re: [open-axiom-help] simplification of the expression From: Игорь Пашев - 2010-08-23 19:26:39 ```Why not do it in mind ? ;-) ```
 Re: [open-axiom-help] simplification of the expression From: Yue Li - 2010-08-23 15:03:01 ```On Aug 23, 2010, at 9:41 AM, Urban Simoncic wrote: > Hi, > > I am wondering if I could simplify the expression with new variables. > Let say I have b:=x+y+z and a:=b+exp(b). Then I calculate derivative > D(a, x) and I get the exp(x+y+z) + 1, which is correct. But, how could I > get the expression exp(b)+1 instead of exp(x+y+z)+1? Is there a way to > exchange every occurrence of x+y+z with b? > Hi Urban You could utilize OpenAxiom's pattern matching facility to manually do so. One needs to use function ``rule" to define his/her own rewriting rule, then apply it to an expression. For instance: (8) -> b := x+y+z (8) z + y + x Type: Polynomial Integer (9) -> a := b + exp(b) z + y + x (9) %e + z + y + x Type: Expression Integer (10) -> d := D(a, x) z + y + x (10) %e + 1 Type: Expression Integer (11) -> myRule := rule(x+y+z == b) (11) z + y + x == b Type: RewriteRule(Integer,Integer,Expression Integer) (12) -> myRule(d) b (12) %e + 1 Type: Expression Integer Best, Yue ```
 [open-axiom-help] simplification of the expression From: Urban Simoncic - 2010-08-23 14:41:45 ```Hi, I am wondering if I could simplify the expression with new variables. Let say I have b:=x+y+z and a:=b+exp(b). Then I calculate derivative D(a, x) and I get the exp(x+y+z) + 1, which is correct. But, how could I get the expression exp(b)+1 instead of exp(x+y+z)+1? Is there a way to exchange every occurrence of x+y+z with b? That is an illustrative example, but I actually have much more complicated case, where the result will go to an algorithm and a new variable would significantly reduce computation time. Thanks, Urban ```

Showing 3 results of 3