Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#1660 'diff() inconsistent

closed
nobody
None
5
2009-11-29
2009-05-05
Žiga Lenarčič
No

'diff(x*y,x) gives the correct result (holds form), while
'diff(x,x) gives 1, calculates the differencial.

Discussion

  • I may be stupid or blind, but I do not see the problem here. Would you like to see diff(x*x,x) resulting in x rather than 2x? May be your remark is more subtle than this.

     
  • Problem is in quoted diff, which should not evaluate, but it does in 'diff(x,x) case:
    (%i2) 'diff(x*y,x);
    d
    (%o2) -- (x y)
    dx
    (%i3) 'diff(x,x);
    (%o3) 1
    (%i4) 'diff(2*x,x);
    d
    (%o4) -- (2 x)
    dx

     
  • Dieter Kaiser
    Dieter Kaiser
    2009-11-14

    'diff(x,x) gives 1 because of simplification in the simplifying function simpderiv.

    We have a similar simplification for integrals:

    (%i9) 'integrate(1,x);
    (%o9) x

    Therefore, we can do something like

    (%i10) 'diff('integrate(1,x),x);
    (%o10) 1

    Furthermore, the following simplification is build in:

    (%i15) 'diff(x,x,0);
    (%o15) x

    This works for an arbitrary expression too:

    (%i17) 'diff(sin(x),x,0);
    (%o17) sin(x)

    It might be arguable why Maxima does not do more simplifications of this type, but the implement simplifications are not wrong. I have no example, where these simplifications cause problems.

    So, I would suggest not to change the behavior of Maxima to simplify the examples in this bug report.

    Setting the status to pending and resolution "works for me".

    Dieter Kaiser

     
  • Dieter Kaiser
    Dieter Kaiser
    2009-11-14

    • status: open --> pending
     
  • This Tracker item was closed automatically by the system. It was
    previously set to a Pending status, and the original submitter
    did not respond within 14 days (the time period specified by
    the administrator of this Tracker).

     
    • status: pending --> closed