On Aug 5, 2009, at 6:25 AM, Burcin Erocal wrote:
> >> (5) Looses information irrecoverably: >> >> From "D[0](f)(x-a)" its not possible to decide whether original >> variable of differentiation was "x" as in f(x-a).diff(x) or "a" >> as in -f(x-a).diff(a). This again affects integration algorithm. > > What is the lost information in this case? D[0](f)(x-a) is both > f(x-a).derivative(x) and -f(x-a).derivative(a). > > sage: f(x-a).derivative(x) > D[1](f)(-a + x) > sage: -f(x-a).derivative(a) > D[1](f)(-a + x) > > Where do you need the variable? > In various kinds of manipulations, you often need the variable. I use this kind of information all the time. A common example is changing from one variable to another. > If we had a proper inverse for differentiation you could recover both > of these easily. > > In[7]:= u = Derivative[1][f][x-a] > > Out[7]= f'[-a + x] > > In[8]:= Integrate[u, a] > > Out[8]= -f[-a + x] > > In[9]:= Integrate[u, x] > > Out[9]= f[-a + x] > > > Unfortunately, the integrate command in Sage fails miserably on the > above examples. > > >> (6) Compact? >> >> It is true that this format is sometime compact but consider >> the counter example: >> ------ >> sage: f( g(x) + h(x) ).diff(x) >> (D[0](g)(x) + D[0](h)(x))*D[0](f)(g(x) + h(x)) >> ------ >> >> In old symbolics it takes less space to print >> ----- >> sage: f( g(x) + h(x) ).diff(x) >> diff(f(h(x) + g(x)), x, 1) >> ----- >> >> >> (7) Printing issues: >> >> We are still debating on this in separate thread. > > The debate seems to be over. There is a patch at #6344. Can someone > please review it? Is it really over? This thread brings up many of the same problems. > >> My question now is it really worth solving all of the >> above issue to keep working with fderivative of pynac? > > As you can see from the output from other systems above, they use a > similar notation and data structure to represent partial > derivatives. I > think it's worth considering why they chose to do things that way. One of the things is that other systems usually have a way to represent things in standard notation which one will want to do at least for teaching purposes. > >> Or should we just restore old "diff" by simply sub-classing it >> from SFunction like what is being done for "integration" >> and others? > > IIRC, you wrote that your implementation can coexist with the current > one in Sage. Why don't you submit your changes so people can try out > both approaches? > > Maple also has an inert "Diff" operator, your implementation can be > the > Sage equivalent. > I don't like this being the inert Diff. I want to see my output in standard differential notation. Sage doesn't allow for that, except through Golam's work. Golam and I are not the only ones who want it. Cheers, Tim. --- Tim Lahey PhD Candidate, Systems Design Engineering University of Waterloo http://www.linkedin.com/in/timlahey --~--~---------~--~----~------------~-------~--~----~ To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---