Re: CVS commit: src/games/factor

2010-05-16 Thread Jukka Ruohonen
On Sun, May 16, 2010 at 01:11:08PM +, Quentin Garnier wrote: > Honestly, I don't see anyone doing stricto sensu maths on a computer > limiting their tools to NetBSD'd games.tgz. Indeed. Maybe add some math book as a reference so that we can blame the author instead of each other from the algeb

Re: CVS commit: src/games/factor

2010-05-16 Thread David Holland
On Sun, May 16, 2010 at 10:49:22PM +0200, Martin Husemann wrote: > On Sun, May 16, 2010 at 07:30:54PM +, David Holland wrote: > > of which at least the 0 case is clearly incorrect... > > That obviously depends on the meaning you give the output, which is > not well defined in the man page

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
Joerg Sonnenberger writes: > On Mon, May 17, 2010 at 12:47:53AM +0400, Aleksej Saushev wrote: >> Joerg Sonnenberger writes: >> >> > On Sun, May 16, 2010 at 08:12:57PM +0400, Aleksej Saushev wrote: >> >> I have spent several years studying math and I say that this approach is >> >> wrong >> >>

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
Martin Husemann writes: > On Sun, May 16, 2010 at 07:30:54PM +, David Holland wrote: >> of which at least the 0 case is clearly incorrect... > > That obviously depends on the meaning you give the output, which is > not well defined in the man page and obviously a lot people around > here disa

Re: CVS commit: src/games/factor

2010-05-16 Thread Joerg Sonnenberger
On Mon, May 17, 2010 at 12:47:53AM +0400, Aleksej Saushev wrote: > Joerg Sonnenberger writes: > > > On Sun, May 16, 2010 at 08:12:57PM +0400, Aleksej Saushev wrote: > >> I have spent several years studying math and I say that this approach is > >> wrong > >> both in mathematical and procedural s

Re: CVS commit: src/games/factor

2010-05-16 Thread Martin Husemann
On Sun, May 16, 2010 at 07:30:54PM +, David Holland wrote: > of which at least the 0 case is clearly incorrect... That obviously depends on the meaning you give the output, which is not well defined in the man page and obviously a lot people around here disagree about. I would say the list of

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
Joerg Sonnenberger writes: > On Sun, May 16, 2010 at 08:12:57PM +0400, Aleksej Saushev wrote: >> I have spent several years studying math and I say that this approach is >> wrong >> both in mathematical and procedural sense. It is perfectly valid to count 0, >> +1 and -1 as prime numbers and thu

re: CVS commit: src/games/factor

2010-05-16 Thread matthew green
> I'm surprised to see so little common sense in all the discussions about > factor(6). The reasons why 1, -1 or negative numbers are not defined as i couldn't agree more. i don't even seen why it matters what the definition of "prime" is for this. irrespective of what a prime number is, "1"

Re: CVS commit: src/games/factor

2010-05-16 Thread David Holland
On Sun, May 16, 2010 at 04:30:45PM +0200, Martin Husemann wrote: > > [..] We should make > > our factor(6) compaible to the coreutils one, just in case POSIX picks > > it up in the next revision ;-} > > Just in case it's not clear from upthread (tech-userlevel): that > compatibility > mean

Re: CVS commit: src/games/factor

2010-05-16 Thread Joerg Sonnenberger
On Sun, May 16, 2010 at 08:12:57PM +0400, Aleksej Saushev wrote: > I have spent several years studying math and I say that this approach is wrong > both in mathematical and procedural sense. It is perfectly valid to count 0, > +1 and -1 as prime numbers and thus factor any finite ones, it just invo

Re: CVS commit: src/games/factor

2010-05-16 Thread Dennis den Brok
On 2010-05-16, David Laight wrote: > The definition of primality gets taken from that of the positive (or > non-negative integers) and applied more generally to other mathematical > objects - in particular 'fields'. > In field theory you need a definition that applies to any field, not > just the

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
Joerg Sonnenberger writes: > On Sun, May 16, 2010 at 02:10:35PM +0400, Aleksej Saushev wrote: >> Following the logic Joerg uses, one should reject all arguments to sqrt, >> asin, acos, atan, clog, casinh, cacosh, and other inverse functions just >> because they have more than one branch. In "fund

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
Joerg Sonnenberger writes: > On Sun, May 16, 2010 at 11:03:42AM +0400, Aleksej Saushev wrote: >> > Yes and it was quite interesting. >> >> I don't like your single-handed decision, referring to wiz or kristaps >> doesn't make honour to any of them (did Thomas present any arguments in >> public a

Re: CVS commit: src/games/factor

2010-05-16 Thread David Laight
On Sun, May 16, 2010 at 11:37:43AM +0200, Martin Husemann wrote: > On Sun, May 16, 2010 at 09:54:49AM +0100, David Laight wrote: > > The notion of 'primes' is valid in Z - the definition of a prime is a > > number that has no non-unit factors. > > Well, I only took the forced (for CS students) mat

Re: CVS commit: src/games/factor

2010-05-16 Thread Martin Husemann
On Sun, May 16, 2010 at 04:26:32PM +0200, Martin Husemann wrote: > [..] We should make > our factor(6) compaible to the coreutils one, just in case POSIX picks > it up in the next revision ;-} Just in case it's not clear from upthread (tech-userlevel): that compatibility means: - negative input c

Re: CVS commit: src/games/factor

2010-05-16 Thread Martin Husemann
On Sun, May 16, 2010 at 01:11:08PM +, Quentin Garnier wrote: > [..] The likely source for > input for factor(6) is a cut-and-paste, or the end of a pipeline > crunching some numbers. Sounds like quite a stretch from "common sense" to a pipeline of number crunching scripts with factor at the en

Re: CVS commit: src/games/factor

2010-05-16 Thread Quentin Garnier
On Sun, May 16, 2010 at 02:10:35PM +0400, Aleksej Saushev wrote: [...] > > So nothing about algebra stops you factoring negative numbers. > > However, since the 'prime factors' should be prime numbers, they > > shouldn't include -1, but maybe the smallest factor should be negative. > > While it ma

Re: CVS commit: src/games/factor

2010-05-16 Thread Joerg Sonnenberger
On Sun, May 16, 2010 at 11:03:42AM +0400, Aleksej Saushev wrote: > > Yes and it was quite interesting. > > I don't like your single-handed decision, referring to wiz or kristaps > doesn't make honour to any of them (did Thomas present any arguments in > public at all?). Essentially, you're using f

Re: CVS commit: src/games/factor

2010-05-16 Thread Joerg Sonnenberger
On Sun, May 16, 2010 at 02:10:35PM +0400, Aleksej Saushev wrote: > Following the logic Joerg uses, one should reject all arguments to sqrt, > asin, acos, atan, clog, casinh, cacosh, and other inverse functions just > because they have more than one branch. In "fundamental theory of mathematics" > b

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
Martin Husemann writes: > On Sun, May 16, 2010 at 09:54:49AM +0100, David Laight wrote: >> The notion of 'primes' is valid in Z - the definition of a prime is a >> number that has no non-unit factors. > > Well, I only took the forced (for CS students) math courses at university, > and it's been q

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
David Laight writes: > On Sat, May 15, 2010 at 09:22:39PM +, Joerg Sonnenberger wrote: >> >> Log Message: >> Follow the Fundamental Theory of Algebra. Disallow factorising of >> numbers less than 2 as it is not >> - naturally unique (negative numbers) >> - finite (0) >> - non-empty (1) > > T

Re: CVS commit: src/games/factor

2010-05-16 Thread Martin Husemann
On Sun, May 16, 2010 at 09:54:49AM +0100, David Laight wrote: > The notion of 'primes' is valid in Z - the definition of a prime is a > number that has no non-unit factors. Well, I only took the forced (for CS students) math courses at university, and it's been quite some time, but I would have de

Re: CVS commit: src/games/factor

2010-05-16 Thread David Laight
On Sat, May 15, 2010 at 09:22:39PM +, Joerg Sonnenberger wrote: > > Log Message: > Follow the Fundamental Theory of Algebra. Disallow factorising of > numbers less than 2 as it is not > - naturally unique (negative numbers) > - finite (0) > - non-empty (1) The 'Natural numbers (N)' are the po

Re: CVS commit: src/games/factor

2010-05-16 Thread Aleksej Saushev
Joerg Sonnenberger writes: > On Sat, May 15, 2010 at 09:44:34PM +, David Holland wrote: >> On Sat, May 15, 2010 at 09:22:39PM +, Joerg Sonnenberger wrote: >> > Modified Files: >> > src/games/factor: factor.6 factor.c >> > >> > Log Message: >> > Follow the Fundamental Theory of Alg

Re: CVS commit: src/games/factor

2010-05-15 Thread David Holland
On Sat, May 15, 2010 at 11:46:16PM +0200, Joerg Sonnenberger wrote: > > > Discussed with the kristaps and wiz > > > > Did you bother to read tech-userlevel before doing this? > > Yes and it was quite interesting. so you blithely ignored the conclusion? -- David A. Holland dholl...@netbsd

Re: CVS commit: src/games/factor

2010-05-15 Thread Joerg Sonnenberger
On Sat, May 15, 2010 at 09:44:34PM +, David Holland wrote: > On Sat, May 15, 2010 at 09:22:39PM +, Joerg Sonnenberger wrote: > > Modified Files: > >src/games/factor: factor.6 factor.c > > > > Log Message: > > Follow the Fundamental Theory of Algebra. Disallow factorising of > > n

Re: CVS commit: src/games/factor

2010-05-15 Thread David Holland
On Sat, May 15, 2010 at 09:22:39PM +, Joerg Sonnenberger wrote: > Modified Files: > src/games/factor: factor.6 factor.c > > Log Message: > Follow the Fundamental Theory of Algebra. Disallow factorising of > numbers less than 2 as it is not > - naturally unique (negative numbers) >