The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and Sundaram

Prime numbers are unique numbers. Prime numbers are numbers that only have a dividing factor consisting of numbers 1 and the number itself. The prime numbers from 1 to n that are relatively small can be generated manually, but a prime number generator algorithm is needed to generate prime numbers on...

Full description

Bibliographic Details
Main Authors: Muhammad Khoiruddin Harahap, Nurul Khairina
Format: Article
Language:English
Published: Politeknik Ganesha Medan 2019-04-01
Series:Sinkron
Online Access:https://jurnal.polgan.ac.id/index.php/sinkron/article/view/10129
id doaj-3612a92ffd8443989e491ab3ae47e59c
record_format Article
spelling doaj-3612a92ffd8443989e491ab3ae47e59c2020-11-25T03:28:27ZengPoliteknik Ganesha MedanSinkron2541-044X2541-20192019-04-013229329810.33395/sinkron.v3i2.1012910129The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and SundaramMuhammad Khoiruddin Harahap0Nurul Khairina1Politeknik Ganesha MedanUniversitas Medan AreaPrime numbers are unique numbers. Prime numbers are numbers that only have a dividing factor consisting of numbers 1 and the number itself. The prime numbers from 1 to n that are relatively small can be generated manually, but a prime number generator algorithm is needed to generate prime numbers on a large scale. This study compares three prime number generator algorithms, namely: The Sieve of Eratosthenes, The Sieve of Atkins, and The Sieve of Sundaram. These three sieve algorithms have their own differences in generating prime numbers. The Sieve of Eratosthenes uses a simpler method by crossing multiples of prime numbers and marking them as non-prime numbers. The Sieve of Atkins uses several requirements for quadratic equations and modulus in determining prime numbers. The Sieve of Sundaram has an algorithm similar to The Sieve of Atkins, but there are requirements for linear equations to determine prime numbers. This study aims to see a comparison of these three algorithms in terms of accuracy and speed in generating prime numbers on a large scale. The results of this study indicate The Sieve of Eratosthenes, Atkins and Sundaram algorithms can generate large numbers of prime numbers with good accuracy, this was tested by the Fermat Primality Test Algorithm. The conclusion that can be drawn from this study, The Sieve of Eratosthenes have a faster time to generate prime numbers on a large scale than the other two algorithms.https://jurnal.polgan.ac.id/index.php/sinkron/article/view/10129
collection DOAJ
language English
format Article
sources DOAJ
author Muhammad Khoiruddin Harahap
Nurul Khairina
spellingShingle Muhammad Khoiruddin Harahap
Nurul Khairina
The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and Sundaram
Sinkron
author_facet Muhammad Khoiruddin Harahap
Nurul Khairina
author_sort Muhammad Khoiruddin Harahap
title The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and Sundaram
title_short The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and Sundaram
title_full The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and Sundaram
title_fullStr The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and Sundaram
title_full_unstemmed The Comparison of Methods for Generating Prime Numbers between The Sieve of Eratosthenes, Atkins, and Sundaram
title_sort comparison of methods for generating prime numbers between the sieve of eratosthenes, atkins, and sundaram
publisher Politeknik Ganesha Medan
series Sinkron
issn 2541-044X
2541-2019
publishDate 2019-04-01
description Prime numbers are unique numbers. Prime numbers are numbers that only have a dividing factor consisting of numbers 1 and the number itself. The prime numbers from 1 to n that are relatively small can be generated manually, but a prime number generator algorithm is needed to generate prime numbers on a large scale. This study compares three prime number generator algorithms, namely: The Sieve of Eratosthenes, The Sieve of Atkins, and The Sieve of Sundaram. These three sieve algorithms have their own differences in generating prime numbers. The Sieve of Eratosthenes uses a simpler method by crossing multiples of prime numbers and marking them as non-prime numbers. The Sieve of Atkins uses several requirements for quadratic equations and modulus in determining prime numbers. The Sieve of Sundaram has an algorithm similar to The Sieve of Atkins, but there are requirements for linear equations to determine prime numbers. This study aims to see a comparison of these three algorithms in terms of accuracy and speed in generating prime numbers on a large scale. The results of this study indicate The Sieve of Eratosthenes, Atkins and Sundaram algorithms can generate large numbers of prime numbers with good accuracy, this was tested by the Fermat Primality Test Algorithm. The conclusion that can be drawn from this study, The Sieve of Eratosthenes have a faster time to generate prime numbers on a large scale than the other two algorithms.
url https://jurnal.polgan.ac.id/index.php/sinkron/article/view/10129
work_keys_str_mv AT muhammadkhoiruddinharahap thecomparisonofmethodsforgeneratingprimenumbersbetweenthesieveoferatosthenesatkinsandsundaram
AT nurulkhairina thecomparisonofmethodsforgeneratingprimenumbersbetweenthesieveoferatosthenesatkinsandsundaram
AT muhammadkhoiruddinharahap comparisonofmethodsforgeneratingprimenumbersbetweenthesieveoferatosthenesatkinsandsundaram
AT nurulkhairina comparisonofmethodsforgeneratingprimenumbersbetweenthesieveoferatosthenesatkinsandsundaram
_version_ 1724584092746383360