A new simple recursive algorithm for finding prime numbers using Rosser s theorem

Similar documents
The distribution of prime numbers: overview of. n.ln(n)

Methylation-associated PHOX2B gene silencing is a rare event in human neuroblastoma.

Smart Bolometer: Toward Monolithic Bolometer with Smart Functions

Can we reduce health inequalities? An analysis of the English strategy ( )

Easter bracelets for years

Case report on the article Water nanoelectrolysis: A simple model, Journal of Applied Physics (2017) 122,

Passerelle entre les arts : la sculpture sonore

A new approach of the concept of prime number

Vibro-acoustic simulation of a car window

There are infinitely many twin primes 30n+11 and 30n+13, 30n+17 and 30n+19, 30n+29 and 30n+31

Evolution of the cooperation and consequences of a decrease in plant diversity on the root symbiont diversity

On size, radius and minimum degree

A remark on a theorem of A. E. Ingham.

On the longest path in a recursively partitionable graph

Dispersion relation results for VCS at JLab

Completeness of the Tree System for Propositional Classical Logic

L institution sportive : rêve et illusion

Soundness of the System of Semantic Trees for Classical Logic based on Fitting and Smullyan

Thomas Lugand. To cite this version: HAL Id: tel

On Symmetric Norm Inequalities And Hermitian Block-Matrices

From Unstructured 3D Point Clouds to Structured Knowledge - A Semantics Approach

A Simple Proof of P versus NP

Full-order observers for linear systems with unknown inputs

The FLRW cosmological model revisited: relation of the local time with th e local curvature and consequences on the Heisenberg uncertainty principle

b-chromatic number of cacti

On Symmetric Norm Inequalities And Hermitian Block-Matrices

Analysis of Boyer and Moore s MJRTY algorithm

On a series of Ramanujan

The Riemann Hypothesis Proof And The Quadrivium Theory

Particle-in-cell simulations of high energy electron production by intense laser pulses in underdense plasmas

Towards an active anechoic room

STATISTICAL ENERGY ANALYSIS: CORRELATION BETWEEN DIFFUSE FIELD AND ENERGY EQUIPARTITION

Stickelberger s congruences for absolute norms of relative discriminants

Hook lengths and shifted parts of partitions

Exact Comparison of Quadratic Irrationals

Multiple sensor fault detection in heat exchanger system

Reduced Models (and control) of in-situ decontamination of large water resources

On a theorem of Erdos and Szemeredi

The Learner s Dictionary and the Sciences:

Entropies and fractal dimensions

Theoretical calculation of the power of wind turbine or tidal turbine

Solving the neutron slowing down equation

Axiom of infinity and construction of N

Impulse response measurement of ultrasonic transducers

SOLAR RADIATION ESTIMATION AND PREDICTION USING MEASURED AND PREDICTED AEROSOL OPTICAL DEPTH

The Mahler measure of trinomials of height 1

Quantum efficiency and metastable lifetime measurements in ruby ( Cr 3+ : Al2O3) via lock-in rate-window photothermal radiometry

Trench IGBT failure mechanisms evolution with temperature and gate resistance under various short-circuit conditions

Exogenous input estimation in Electronic Power Steering (EPS) systems

Best linear unbiased prediction when error vector is correlated with other random vectors in the model

Sparse multivariate factorization by mean of a few bivariate factorizations

Basic concepts and models in continuum damage mechanics

RHEOLOGICAL INTERPRETATION OF RAYLEIGH DAMPING

A Study of the Regular Pentagon with a Classic Geometric Approach

A numerical analysis of chaos in the double pendulum

Water Vapour Effects in Mass Measurement

The Windy Postman Problem on Series-Parallel Graphs

Numerical Modeling of Eddy Current Nondestructive Evaluation of Ferromagnetic Tubes via an Integral. Equation Approach

Cutwidth and degeneracy of graphs

A non-commutative algorithm for multiplying (7 7) matrices using 250 multiplications

All Associated Stirling Numbers are Arithmetical Triangles

On infinite permutations

New estimates for the div-curl-grad operators and elliptic problems with L1-data in the half-space

The sound power output of a monopole source in a cylindrical pipe containing area discontinuities

The Accelerated Euclidean Algorithm

Solubility prediction of weak electrolyte mixtures

On The Exact Solution of Newell-Whitehead-Segel Equation Using the Homotopy Perturbation Method

Sound intensity as a function of sound insulation partition

Electromagnetic characterization of magnetic steel alloys with respect to the temperature

approximation results for the Traveling Salesman and related Problems

Solving an integrated Job-Shop problem with human resource constraints

Stochastic invariances and Lamperti transformations for Stochastic Processes

IMPROVEMENTS OF THE VARIABLE THERMAL RESISTANCE

AC Transport Losses Calculation in a Bi-2223 Current Lead Using Thermal Coupling With an Analytical Formula

A Slice Based 3-D Schur-Cohn Stability Criterion

Characterization of the local Electrical Properties of Electrical Machine Parts with non-trivial Geometry

DYNAMICAL PROPERTIES OF MONOTONE DENDRITE MAPS

A Context free language associated with interval maps

On one class of permutation polynomials over finite fields of characteristic two *

On path partitions of the divisor graph

New Basis Points of Geodetic Stations for Landslide Monitoring

On Newton-Raphson iteration for multiplicative inverses modulo prime powers

ON THE UNIQUENESS IN THE 3D NAVIER-STOKES EQUATIONS

Unbiased minimum variance estimation for systems with unknown exogenous inputs

Computer Visualization of the Riemann Zeta Function

Lorentz force velocimetry using small-size permanent magnet systems and a multi-degree-of-freedom force/torque sensor

Comparison of Harmonic, Geometric and Arithmetic means for change detection in SAR time series

Quasi-periodic solutions of the 2D Euler equation

Ion energy balance during fast wave heating in TORE SUPRA

The Zenith Passage of the Sun in the Plan of Brasilia

Unfolding the Skorohod reflection of a semimartingale

Nodal and divergence-conforming boundary-element methods applied to electromagnetic scattering problems

A Simple Model for Cavitation with Non-condensable Gases

FORMAL TREATMENT OF RADIATION FIELD FLUCTUATIONS IN VACUUM

Near-Earth Asteroids Orbit Propagation with Gaia Observations

Widely Linear Estimation with Complex Data

Lower bound of the covering radius of binary irreducible Goppa codes

Numerical Exploration of the Compacted Associated Stirling Numbers

Negative results on acyclic improper colorings

Solving a quartic equation and certain equations with degree n

Transcription:

A new simple recursive algorithm for finding prime numbers using Rosser s theorem Rédoane Daoudi To cite this version: Rédoane Daoudi. A new simple recursive algorithm for finding prime numbers using Rosser s theorem. 2017. <hal-01472833> HAL Id: hal-01472833 https://hal.archives-ouvertes.fr/hal-01472833 Submitted on 21 Feb 2017 HAL is a multi-disciplinary open access archive for the deposit and dissemination of scientific research documents, whether they are published or not. The documents may come from teaching and research institutions in France or abroad, or from public or private research centers. L archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.

A new simple recursive algorithm for finding prime numbers using Rosser s theorem Redoane D. *University of Poitiers 86000 FRANCE - Travail sans lien avec un laboratoire de recherche. E-mail: *redoane.daoudi@etu.univ-poitiers.fr Abstract In our previous work (The distribution of prime numbers: overview of n.ln(n), (1) and (2)) we defined a new method derived from Rosser s theorem (2) and we used it in order to approximate the nth prime number. In this paper we improve our method to try to determine the next prime number if the previous is known. We use our method with five intervals and two values for n (see Methods and results). Our preliminary results show a reduced difference between the real next prime number and the number given by our algorithm. However long-term studies are required to better estimate the next prime number and to reduce the difference when n tends to infinity. Indeed an efficient algorithm is an algorithm that could be used in practical research to find new prime numbers for instance. Keywords: Prime numbers, Algorithm prime numbers, Rosser s theorem. Introduction For more details, see the first study (The distribution of prime numbers: overview of n.ln(n)) We define the difference as below: 1

= N (n.ln(n)) n N (1) if N is the real nth prime number and n.ln(n) the approximated nth prime number. We define ζ as below: ζ = (n.ln(n)) n N (2) We define ɛ as below: ɛ = ζ 0 (3) The aim is to know to find the real nth prime number. In fact is the difference between the real nth prime number and the number given by the empirical formula. According to (2) we have: ζ = (n.ln(n)) n N ζ = (n.ln(n)) ζ ɛ ɛ 0 ζ = ɛ(n.ln(n)) ζ ɛ ɛ 0 ɛζ + ζ = ɛ(n.ln(n)) ζ(ɛ + 1) = ɛ(n.ln(n)) ζ = ɛ(n.ln(n)) ɛ+1 According to (3) we have: 2

ɛ = ζ 0 = ζ ɛ ɛ 0 = ɛ(n.ln(n)) ɛ 2 +ɛ ɛ 0 (4) Finally the real nth prime number is given by the following formula: N = (n.ln(n)) + n N N = (n.ln(n)) 2+ɛ 1+ɛ ɛ 1 N = (n.ln(n))p with 1 < p < 2, p = 2+ɛ 1+ɛ and n > 2 (5) We must know p to find and the real nth prime number. In the previous study we noticed that the value of ɛ (and consequently p) for a next prime number was very close to the value of p for a previous prime number (for the third interval of the previous study). In this work we confirm that two consecutive prime numbers seem to have values of p that are very close to each other. For this reason we try to use the value of p that is associated with the nth prime number to approximate the next prime number. However there are errors in the determination of the next prime number when we use this value to determine the next prime number. Because the value of p of the next prime number is unpredictable and is either greater than, smaller than or equal to the value of p of the previous prime number, we change the value of p that is associated with the nth prime number and we use three values of p to approximate the next prime number (see Methods and results). Methods and results Methods In this work we use five intervals and two values for n as described below: 3

n [2, 200] n [1000, 1195] n [1800, 1999] n [2600, 2903] n [999971, 10 6 ] n = 100000 n = (2 10 17 ) 1 By using Microsoft Excel 2016 we calculate the value of p for each n of each interval and for each value of n (for more details see Introduction and the previous study). Then, in order to approximate the next prime number, we change the value of p as described below: p ± ln(ln(ln(n+1))) n+1 with ln(ln(ln(n + 1))) = ln 3 (n + 1) We use these three values of p to approximate the next prime number, as below: p 1 = p ln(ln(ln(n+1))) n+1 with ln(ln(ln(n + 1))) = ln 3 (n + 1) p 2 = p p 3 = p + ln(ln(ln(n+1))) n+1 with ln(ln(ln(n + 1))) = ln 3 (n + 1) Finally we have: p 1 ((n + 1).ln(n + 1)) p 2 ((n + 1).ln(n + 1)) p 3 ((n + 1).ln(n + 1)) Our results show that the next prime number defined as p(n+1) is close to one of these three values, with a margin of error and exceptions. 4

Proposed algorithm We propose the following recursive algorithm as a way to approximate the next prime number if we know a nth prime number: 1. We define p(n) as the nth prime number. We want to approximate the next prime number p(n+1) with the value of p that is associated with n. 2. We calculate n.ln(n) 3. We calculate 4. We calculate n.ln(n) - 5. We calculate ɛ 6. We calculate p 1, p 2 and p 3 as described above 7. We approximate p(n+1) using the three values of p : p(n + 1) p 1 ((n + 1).ln(n + 1)) Or p(n + 1) p 2 ((n + 1).ln(n + 1)) Or p(n + 1) p 3 ((n + 1).ln(n + 1)) The real next prime number p(n+1) is close to one of these three values, with a margin of error and several exceptions. Results n p(n) p1 p2 p3 p(n+1) (p1) p(n+1) (p2) p(n+1) (p3) Real next prime number 175 1039 1.14672182 1.14954286 1.15236391 1043.5228 1046.08996 1048.65713 1049 176 1049 1.14993182 1.15274069 1.15554956 1053.54281 1056.11624 1058.68966 1051 1158 9349 1.14386326 1.14444114 1.14501902 9353.49293 9358.21834 9362.94375 9371 1180 9533 1.14159283 1.14216111 1.14272938 9537.47382 9542.22146 9546.9691 9539 1900 16363 1.14036498 1.14073525 1.14110551 16367.4388 16372.7531 16378.0675 16369 1901 16369 1.14010367 1.14047375 1.14084384 16373.4365 16378.7515 16384.0665 16381 2642 23719 1.13912624 1.13940047 1.1396747 23723.4062 23729.1173 23734.8283 23741 2643 23741 1.13969691 1.13997104 1.14024518 23745.4113 23751.1228 23756.8343 23743 100000 1299709 1.128903959 1.128912894 1.128921828 1299712.84 1299723.126 1299733.412 1299721 999971 15485473 1.12090981 1.12091077 1.12091174 15485476.3 15485489.6 15485502.9 15485497 999972 15485497 1.12091034 1.12091131 1.12091227 15485500.3 15485513.6 15485526.9 15485537 999973 15485537 1.12091203 1.120913 1.12091397 15485540.3 15485553.6 15485566.9 15485539 999974 15485539 1.12091098 1.12091194 1.12091291 15485542.3 15485555.6 15485568.9 15485543 (2.10 17 ) 1 1 2 3 4 5 6 7 8 1 8512677386048191019 2 1.06843604568915229910775060 3 1.06843604568915230562882979 4 1.06843604568915231214990898 5 8512677386048191010.6 6 8512677386048191062.6 7 8512677386048191114.5 8 8512677386048191063 5

p(n+1) (p) refers to the number given by our method with the value of p 1, p 2 or p 3. Discussion We notice that the real next prime number is close to one of the three values of p(n+1). However there is often a margin of error and there are several exceptions. Moreover it is impossible to predict the exact value of p that is associated with the next prime number. Because the value of p of the next prime number is unpredictable and is either greater than, smaller than or equal to the value of p of the previous prime number, we must use the three values of p. Consequently the speed of the algorithm is slow and this is a problem if we want to find new prime numbers. We fail to approximate the next prime number with p 2 or p 3 when there are twin primes (n and n+2 are both prime) but not with p 1. Finally our method seems to be particularly effective even if the value of n is increased (n = (2.10 17 ) 1)) because we found the exact value ( 0.4) of the next prime number using p 2, suggesting that our algorithm may be used to find new prime numbers. However we fail to determine the exact value of other next prime numbers (with n = (2.10 17 ), n = (2.10 17 )+1 and n = (2.10 17 ) + 2, data not shown here). Conclusion In this work we approximated the next prime number using the value of p of the previous prime number. It is clear that the value of the next prime number is close to one of the three values of p(n+1) but there is a margin of error and several exceptions. Further investigations are needed to improve this algorithm. Is it possible to predict the exact value of p of the next prime number using the value of p of the previous prime number? Is it possible to decrease the margin of error (when n tends to infinity)? 6

Tools Statistics. Statistics were performed using Microsoft Excel 2016. The list of prime numbers used in this study. http://compoasso.free.fr/primelistweb/page/prime/ liste online.php The next prime numbers. The next prime numbers were found using http://www.numberempire.com/primenumbers.php References 1. PIERRE DUSART, The k th prime is greater than k(lnk + lnlnk 1) for k 2, Math. Comp. 68 (1999), 411-415 2. J.B. ROSSER, The n th prime is greater than n.log(n), Proc. London Math. Soc. (2) 45 (1939), 21-44 7