| Ilya Zakharevich on Fri, 29 Jan 1999 00:19:31 -0500 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
| Partial derivatives |
I'm thinking about adding new type "a transcendental function" to
PARI. It is going to be a slight modification of a user variable
(undeterminate) with some additional rules of manipulation stored in
some database, so that
q=Trans(sin,x^2);
deriv(q,x)
may be calculated to be 2*x*Trans(cos,x^2).
But first I want to understand what happens with algebraic functions,
which *apparently* should be supported with the current implementation
as well.
Does not it look strange to you that
? q=Mod(z,x+y+z)
%1 = Mod(z, x + (z + y))
? deriv(q,x)
%2 = 0
? deriv(q,y)
%3 = 0
? deriv(q,z)
%4 = Mod(1, x + (z + y))
? Suppose that we have a modification
deriv(a,x,[y,y1,y2])
with the meaning "partial derivative of a wrt x when y,y1,y2 remain constant".
Then
deriv(q,x,[y])
might be calculated and be Mod(-1,x+(z+y)).
Any thoughts?
Ilya
P.S. Why is it that I cannot make a damn from Chapter2's PolMods? Is
not it a codification of some bugs in PARI? Why should
y+Mod(x,x^2+1) behave any differently than Mod(x+y,x^2+1)?