IDEAS home Printed from https://ideas.repec.org/a/ibn/jmrjnl/v16y2024i3p28.html
   My bibliography  Save this article

A New Method for Testing Whether a Number Is Prime

Author

Listed:
  • Bouchaïb Bahbouhi

Abstract

The present paper describes a new method for the decomposition of integer numbers into their prime factors. To know if a number is prime, the classic and oldest method is to perform a series of Euclidean divisions by the prime factors in increasing order. In this article, I report a new and alternative method to the classic one. It is based on the fact that an even number that precedes a prime number must in no case have a potential prime factor that lacks a unit. This even number with one unit before the number to be decomposed can then be used to prove its primality or not by looking if it has a factor missing one unit. To achieve this, we divide the even by the prime factors (p) in ascending order and follow the decimal part. If the latter is equal to a ratio of (p - 1)/p (p is any prime factor), then the number to be decomposed is not prime and the prime number giving the ratio is its prime factor. This method has the potential to have applications in computer science and to lead to a new algorithm for decomposing numbers or further improve the performance of those existing.

Suggested Citation

  • Bouchaïb Bahbouhi, 2024. "A New Method for Testing Whether a Number Is Prime," Journal of Mathematics Research, Canadian Center of Science and Education, vol. 16(3), pages 1-28, December.
  • Handle: RePEc:ibn:jmrjnl:v:16:y:2024:i:3:p:28
    as

    Download full text from publisher

    File URL: https://ccsenet.org/journal/index.php/jmr/article/download/0/0/50375/54566
    Download Restriction: no

    File URL: https://ccsenet.org/journal/index.php/jmr/article/view/0/50375
    Download Restriction: no
    ---><---

    More about this item

    JEL classification:

    • R00 - Urban, Rural, Regional, Real Estate, and Transportation Economics - - General - - - General
    • Z0 - Other Special Topics - - General

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:ibn:jmrjnl:v:16:y:2024:i:3:p:28. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    We have no bibliographic references for this item. You can help adding them by using this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Canadian Center of Science and Education (email available below). General contact details of provider: https://edirc.repec.org/data/cepflch.html .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.