Loading ...
Sorry, an error occurred while loading the content.

Re: request for comments on a prime generation algorithm

Expand Messages
  • rlberry2002
    ... to ... to ... ********************************************************************** The following points might help. First, other than two & three all
    Message 1 of 3 , Apr 17 6:06 PM
    View Source
    • 0 Attachment
      --- In primenumbers@y..., "padmapani19" <padmapani19@y...> wrote:
      > i am a newbie here and excuse my ignorance.this is to solicit the
      > readers' opinion on the prime generation algorithm i struck
      > upon.earlier i posted on this board that every prime other than 2 or
      > 3
      > is of the form sqrt(1+24*n).but the converse was not true and had
      to
      > use sieve for culling out the primes.for B steps the normal sieve
      > generates B/log B primes in contrast to my approach which is
      > k*sqrt(B).so i found another pattern which i am not sure if anybody
      > else already did it.so here what i came up with for prime number
      > generation of the first 1000 primes.This method also generates
      > numbers
      > like 25,35,49,etc which usually are product of primes generated
      > earlier.
      >
      > i understand a lot can be optimised here and i am working on ways
      to
      > improve it.
      **********************************************************************

      The following points might help. First, other than two & three all
      prime numbers are congruent 5 Mod 6 or 1 Mod 6. Your equation of sprt
      (1+24*n)is a correct represtation since it is a 1 Mod 6 number and
      the square of a 5 Mod 6 number or a 1 Mod 6 number is a 1 Mod 6
      number. The problem with you equation is that all it really achieves
      is to show that every prime number squared plus 1 has a whole number
      solution of n in your equation. There is no way to evaluate
      primeness,if you will, when say a 1 Mod 6 number is not prime....it
      will still have a solution in your equation [i.e. n=26... sqrt(1+24*
      26=625)which is 25 squared]. Furthermore, let 5 Mod 6 numbers be
      represented by 6X + 5 .... take this equation, square it and I think
      you will start to see the "converse" of what you are trying to do.

      Just some quick thoughts...perhaps others on this board can better
      help you here.

      Good luck,

      Robert
    Your message has been successfully submitted and would be delivered to recipients shortly.