Dear Waldek,
thanks a lot for you description for decomposing the result of 'guess'.
I now wanted to rename the running variable by simply modifying the
third entry in the argument list of the %defprod kernel and reconstruct.
%%% (2) -> p := product(x^2+x+1, x=1..n)
n
++-++ 2
(2) | | x + x + 1
| |
x = 1
%%% (3) -> k := kernels(p).1; o := operator k; a := argument k
2
(3) [%B + %B + 1, %B, x, 1, n]
Type: List(Expression(Integer))
%%% (4) -> py := o [a.1,a.2,y,a.4,a.5]
n
++-++ 2
(4) | | x + x + 1
| |
x = 1
Type: Expression(Integer)
Unfortunately, that does not replace x by y. :-(
%%% (4) -> ky := kernels(py).1
n
++-++ 2
(4) | | x + x + 1
| |
x = 1
Type: Kernel(Expression(Integer))
%%% (5) -> oy := operator ky
(5) %defprod
Type: BasicOperator
%%% (6) -> ay := argument ky
2
(6) [%B + %B + 1, %B, x, 1, n]
Type: List(Expression(Integer))
How come that there is an x in this structure?
%%% (8) -> (k=ky)@Boolean
(8) true
Type: Boolean
And why is this true?
The following works, but is certainly not what I want because of a
destructive operation that also modifies the original p.
Ralf
%%% (5) -> a.3 := y
(5) y
%%% (6) -> a
2
(6) [%B + %B + 1, %B, y, 1, n]
Type: List(Expression(Integer))
%%% (7) -> p
n
++-++ 2
(7) | | y + y + 1
| |
y = 1
Type: Expression(Integer)
%%% (8) -> o a
n
++-++ 2
(8) | | y + y + 1
| |
y = 1
Type: Expression(Integer)
--
You received this message because you are subscribed to the Google Groups "FriCAS -
computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to fricas-devel+unsubscr...@googlegroups.com.
To view this discussion visit
https://groups.google.com/d/msgid/fricas-devel/b83469b5-7c61-4258-92f2-5c542c3e2b82%40hemmecke.org.