Giter Site home page Giter Site logo

primegen's Introduction

primegen.go is a Go package that generates prime numbers in order using the
Sieve of Atkin instead of the traditional Sieve of Eratosthenes.

It is a relatively straightforward port of D. J. Bernstein's original
C implementation (http://cr.yp.to/primegen.html) but makes use of
Go's concurrency features which should make it faster on multi-core CPUs.

Do "go get github.com/divergentdave/primegen" to install the package.

View the package documentation online at
http://gopkgdoc.appspot.com/pkg/github.com/divergentdave/primegen
or on the command line by running "go doc github.com/divergentdave/primegen".

The repository includes two additional programs that illustrate usage of the
primegen package:

  1. primes, which writes prime numbers to standard out
  2. primespeed, which prints the time taken to generate the first
     50,847,534 prime numbers

John Barham
[email protected]

(This was forked by David Cook to change the package name. As of ca. 2012,
repository names can no longer end in .go, to disambiguate between local files
and source controlled projects)

primegen's People

Contributors

jbarham avatar divergentdave avatar

Watchers

 avatar James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.