List:General Discussion« Previous MessageNext Message »
From:Jigal van Hemert Date:February 25 2005 3:47pm
Subject:Re: modulo operation
View as plain text  
From: "Peter Brawley"

> There are various interpretations of modulo. It's not simply
> "remainder", eg see the discussion at
> http://mathforum.org/library/drmath/view/52343.html including this chart
> from the 1983 Ada manual:

The article at wikipedia already mentioned multiple interpretations.

My point was that while Thomas wrote that modulo in MySQL was flawed and
pointed to the wikipedia page to prove his point, the wikipedia page in
question was not contradicting the MySQL implementation at all.

> >From: "Thomas Lenherr"
> >>(For the exact definition see
> >>http://en.wikipedia.org/wiki/Modulo_operation )

It is strange for mathematical operations/functions to depend upon
"interpretation" or "implementation". If there is anything in this world
that is properly defined, it must be mathematics.

Maybe Thomas (or you) can file a bugreport with the suggestion to add a
mathematically correct modulo function; I don't think the current modulo
function/operator should be altered, since this might break a lot of queries
out there!

Regards, Jigal.

Thread
modulo operationThomas Lenherr25 Feb
  • Re: modulo operationJigal van Hemert25 Feb
    • Re: modulo operationPeter Brawley25 Feb
  • Re: modulo operationJigal van Hemert25 Feb
    • Re: modulo operationThomas Lenherr25 Feb