#1395 complex-number-p test for floatp

closed
nobody
5
2009-11-21
2008-04-23
No

(%i1) x : 3.1 + %i * 1.7;
(%o1) 1.7*%i+3.1

This is wrong:

(%i2) :lisp(complex-number-p (meval $x) 'floatp);
NIL

Thi is OK

(%i2) :lisp(complex-number-p (meval $x) 'mnump);
T

I think this is due to the (N 1) check in
complex-number-p.

Maxima version: 5.14.99rc1
Maxima build date: 11:38 4/12/2008

Discussion

  • Robert Dodier

    Robert Dodier - 2008-06-22
    • labels: 460522 --> Lisp Core - Complex
     
  • Dieter Kaiser

    Dieter Kaiser - 2009-11-07

    The bug seems to be no longer present. These are the results with Maxima 5.19post:

    (%i4) x : 3.1 + %i * 1.7;
    (%o4) 1.7*%i+3.1
    (%i5) :lisp (complex-number-p (meval $x) 'floatp)
    T
    (%i5) :lisp (complex-number-p (meval $x) 'float-or-rational-p)
    T
    (%i5) :lisp (complex-number-p (meval $x) 'mnump)
    T

    Setting the status to pending and works for me.
    Dieter Kaiser

     
  • Dieter Kaiser

    Dieter Kaiser - 2009-11-07
    • status: open --> pending
     
  • SourceForge Robot

    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).

     
  • SourceForge Robot

    • status: pending --> closed
     

Log in to post a comment.