Michael Somos on Sat, 30 Oct 1999 20:42:58 -0400 (EDT)


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Euclidean quotient suggestion


In looking at the "calc" program I noticed that their Euclidean division

-------------------------------------------------------------------------
> 16//3
        5
> 2//(3/8)
        5
-------------------------------------------------------------------------

is able to handle rational numbers, while in GP/PARI

-------------------------------------------------------------------------
gp> 16\3
%13 = 5
gp> 2\(3/8)
  ***   incorrect type in gdivent.
gp> ??\
\:

   The expression x \ y is the

   Euclidean quotient of x and y. The types must be either both integer or both
polynomials.    The  result is the Euclidean quotient.   In the case of integer
division, the quotient is such that the corresponding remainder is
non-negative.
-------------------------------------------------------------------------

this is not allowed. Any chance to modify this so that it is? Shalom, Michael

-- 
Michael Somos <somos@grail.cba.csuohio.edu>     Cleveland State University
http://grail.cba.csuohio.edu/~somos/            Cleveland, Ohio, USA 44115