A000058 Sylvester's sequence: a(n+1) = a(n)^2 - a(n) + 1, with a(0) = 2.
2, 3, 7, 43, 1807, 3263443, 10650056950807, 113423713055421844361000443, 12864938683278671740537145998360961546653259485195807
Offset: 0
Examples
a(0)=2, a(1) = 2+1 = 3, a(2) = 2*3 + 1 = 7, a(3) = 2*3*7 + 1 = 43.
References
- Graham Everest, Alf van der Poorten, Igor Shparlinski and Thomas Ward, Recurrence Sequences, Amer. Math. Soc., 2003; see esp. p. 255.
- Steven R. Finch, Mathematical Constants, Cambridge, 2003, Section 6.7.
- Ronald L. Graham, Donald E. Knuth and Oren Patashnik, Concrete Mathematics. Addison-Wesley, Reading, MA, 2nd. ed., 1994.
- Richard K. Guy, Unsolved Problems in Number Theory, Springer, 1st edition, 1981. See section E24.
- Richard K. Guy and Richard Nowakowski, Discovering primes with Euclid. Delta, Vol. 5 (1975), pp. 49-63.
- Amarnath Murthy, Smarandache Reciprocal partition of unity sets and sequences, Smarandache Notions Journal, Vol. 11, 1-2-3, Spring 2000.
- Amarnath Murthy and Charles Ashbacher, Generalized Partitions and Some New Ideas on Number Theory and Smarandache Sequences, Hexis, Phoenix; USA 2005. See Section 1.1.
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
Links
- N. J. A. Sloane, Table of n, a(n) for n = 0..12
- David Adjiashvili, Sandro Bosio and Robert Weismantel, Dynamic Combinatorial Optimization: a complexity and approximability study, 2012.
- A. V. Aho and N. J. A. Sloane, Some doubly exponential sequences, Fibonacci Quarterly, Vol. 11, No. 4 (1973), pp. 429-437.
- A. V. Aho and N. J. A. Sloane, Some doubly exponential sequences, Fibonacci Quarterly, Vol. 11, No. 4 (1973), pp. 429-437 (original plus references that F.Q. forgot to include - see last page!)
- Mohammad K. Azarian, Sylvester's Sequence and the Infinite Egyptian Fraction Decomposition of 1, Problem 958, College Mathematics Journal, Vol. 42, No. 4, September 2011, p. 330.
- Mohammad K. Azarian, Sylvester's Sequence and the Infinite Egyptian Fraction Decomposition of 1, Solution College Mathematics Journal, Vol. 43, No. 4, September 2012, pp. 340-342.
- Gennady Bachman and Troy Kessler, On divisibility properties of certain multinomial coefficients—II, Journal of Number Theory, Volume 106, Issue 1, May 2004, Pages 1-12.
- Andreas Bäuerle, Sharp volume and multiplicity bounds for Fano simplices, arXiv:2308.12719 [math.CO], 2023.
- Kevin S. Brown, Odd, Greedy and Stubborn (Unit Fractions).
- Eunice Y. S. Chan and Robert M. Corless, Minimal Height Companion Matrices for Euclid Polynomials, Mathematics in Computer Science, Vol. 13, No. 1-2 (2019), pp. 41-56, arXiv preprint, arXiv:1712.04405 [math.NA], 2017.
- Hung Viet Chu, A Threshold for the Best Two-term Underapproximation by the Greedy Algorithm, arXiv:2306.12564 [math.NT], 2023.
- Matthew Brendan Crawford, On the Number of Representations of One as the Sum of Unit Fractions, Master's Thesis, Virginia Polytechnic Institute and State University (2019).
- D. R. Curtiss, On Kellogg's Diophantine problem, Amer. Math. Monthly, Vol. 29, No. 10 (1922), pp. 380-387.
- Mehran Derakhshandeh, Why do Sylvester numbers, when reduced modulo 864, form an arithmetic progression 7,43,79,115,151,187,223,...?
- Paul Erdős and E. G. Straus, On the Irrationality of Certain Ahmes Series, J. Indian Math. Soc. (N.S.), 27(1964), pp. 129-133.
- Steven Finch, Exercises in Iterational Asymptotics, arXiv:2411.16062 [math.NT], 2024. See p. 10.
- Solomon W. Golomb, On the sum of the reciprocals of the Fermat numbers and related irrationalities, Canad. J. Math., 15 (1963), 475-478.
- Solomon W. Golomb, On certain nonlinear recurring sequences, Amer. Math. Monthly 70 (1963), 403-405.
- Richard K. Guy and Richard Nowakowski, Discovering primes with Euclid, Research Paper No. 260 (Nov 1974), The University of Calgary Department of Mathematics, Statistics and Computing Science.
- János Kollár, Which powers of holomorphic functions are integrable?, arXiv:0805.0756 [math.AG], 2008.
- E. Lemoine, Sur la décomposition d'un nombre en ses carrés maxima, Assoc. Française pour L'Avancement des Sciences (1896), 73-77.
- Zheng Li and Quanyu Tang, On a conjecture of Erdős and Graham about the Sylvester's sequence, arXiv:2503.12277 [math.NT], 2025. See p. 2.
- Nick Lord, A uniform construction of some infinite coprime sequences, The Mathematical Gazette, vol. 92, no. 523, March 2008, pp.66-70.
- Romeo Meštrović, Euclid's theorem on the infinitude of primes: a historical survey of its proofs (300 BC--2012) and another new proof, arXiv preprint arXiv:1202.3670 [math.HO], 2012. - _N. J. A. Sloane_, Jun 13 2012
- Melvyn B. Nathanson, Underapproximation by Egyptian fractions, arXiv:2202.00191 [math.NT], 2022.
- Benjamin Nill, Volume and lattice points of reflexive simplices, Discrete & Computational Geometry, Vol. 37, No. 2 (2007), pp. 301-320, arXiv preprint, arXiv:math/0412480 [math.AG], 2004-2007.
- R. W. K. Odoni, On the prime divisors of the sequence w_{n+1}=1+w_1 ... w_n, J. London Math. Soc. 32 (1985), 1-11.
- Michael Penn, An intriguing integer sequence — Sylvester’s Sequence, YouTube video (2022).
- Simon Plouffe, A set of formulas for primes, arXiv:1901.01849 [math.NT], 2019.
- Paul Pollack, Analytic and Combinatorial Number Theory Course Notes, p. 5. [?Broken link]
- Paul Pollack, Analytic and Combinatorial Number Theory Course Notes, p. 5.
- Filip Saidak, A New Proof of Euclid's Theorem, Amer. Math. Monthly, Vol. 113, No. 10 (Dec., 2006), pp. 937-938.
- N. J. A. Sloane, A Nasty Surprise in a Sequence and Other OEIS Stories, Experimental Mathematics Seminar, Rutgers University, Oct 10 2024, Youtube video; Slides [Mentions this sequence]
- Jonathan Sondow and Kieren MacMillan, Primary pseudoperfect numbers, arithmetic progressions, and the Erdős-Moser equation, Amer. Math. Monthly, Vol. 124, No. 3 (2017), pp. 232-240, arXiv preprint, arXiv:math/1812.06566 [math.NT], 2018.
- J. J. Sylvester, On a Point in the Theory of Vulgar Fractions, Amer. J. Math., Vol. 3, No. 4 (1880), pp. 332-335.
- Burt Totaro, The ACC conjecture for log canonical thresholds, Séminaire Bourbaki no. 1025 (juin 2010).
- Burt Totaro and Chengxi Wang, Varieties of general type with small volume, arXiv:2104.12200 [math.AG], 2021.
- Akiyoshi Tsuchiya, The delta-vectors of reflexive polytopes and of the dual polytopes, Discrete Mathematics, Vol. 339, No. 10 (2016), pp. 2450-2456, arXiv preprint, arXiv:1411.2122 [math.CO], 2014-2016.
- Stephan Wagner and Volker Ziegler, Irrationality of growth constants associated with polynomial recursions, arXiv:2004.09353 [math.NT], 2020.
- Eric Weisstein's World of Mathematics, Quadratic Recurrence Equation.
- Eric Weisstein's World of Mathematics, Sylvester's Sequence.
- Wikipedia, Sylvester's sequence.
- Bowen Yao, A note on fraction decompositions of integers, The American Mathematical Monthly, 127(10), 928-932, Dec 2020.
- Index entries for sequences of form a(n+1)=a(n)^2 + ....
- Index entries for "core" sequences.
Crossrefs
Programs
-
Haskell
a000058 0 = 2 a000058 n = a000058 m ^ 2 - a000058 m + 1 where m = n - 1 -- James Spahlinger, Oct 09 2012
-
Haskell
a000058_list = iterate a002061 2 -- Reinhard Zumkeller, Dec 18 2013
-
Julia
a(n) = n == 0 ? BigInt(2) : a(n - 1)*(a(n - 1) - 1) + 1 [a(n) for n in 0:8] |> println # Peter Luschny, Dec 15 2020
-
Maple
A[0]:= 2: for n from 1 to 12 do A[n]:= A[n-1]^2 - A[n-1]+1 od: seq(A[i],i=0..12); # Robert Israel, Jan 18 2015
-
Mathematica
a[0] = 2; a[n_] := a[n - 1]^2 - a[n - 1] + 1; Table[ a[ n ], {n, 0, 9} ] NestList[#^2-#+1&,2,10] (* Harvey P. Dale, May 05 2013 *) RecurrenceTable[{a[n + 1] == a[n]^2 - a[n] + 1, a[0] == 2}, a, {n, 0, 10}] (* Emanuele Munarini, Mar 30 2017 *)
-
Maxima
a(n) := if n = 0 then 2 else a(n-1)^2-a(n-1)+1 $ makelist(a(n),n,0,8); /* Emanuele Munarini, Mar 23 2017 */
-
PARI
a(n)=if(n<1,2*(n>=0),1+a(n-1)*(a(n-1)-1))
-
PARI
A000058(n,p=2)={for(k=1,n,p=(p-1)*p+1);p} \\ give Mod(2,m) as 2nd arg to calculate a(n) mod m. - M. F. Hasler, Apr 25 2014
-
PARI
a=vector(20); a[1]=3; for(n=2, #a, a[n]=a[n-1]^2-a[n-1]+1); concat(2, a) \\ Altug Alkan, Apr 04 2018
-
Python
A000058 = [2] for n in range(1, 10): A000058.append(A000058[n-1]*(A000058[n-1]-1)+1) # Chai Wah Wu, Aug 20 2014
Formula
a(n) = 1 + a(0)*a(1)*...*a(n-1).
a(n) = a(n-1)*(a(n-1)-1) + 1; Sum_{i>=0} 1/a(i) = 1. - Néstor Romeral Andrés, Oct 29 2001
Vardi showed that a(n) = floor(c^(2^(n+1)) + 1/2) where c = A076393 = 1.2640847353053011130795995... - Benoit Cloitre, Nov 06 2002 (But see the Aho-Sloane paper!)
a(n) = A007018(n+1)+1 = A007018(n+1)/A007018(n) [A007018 is a(n) = a(n-1)^2 + a(n-1), a(0)=1]. - Gerald McGarvey, Oct 11 2004
a(n) = A014117(n+1)+1 for n = 0,1,2,3,4; a(n) = A054377(n)+1 for n = 1,2,3,4. - Jonathan Sondow, Dec 07 2013
a(n) = f(1/(1-(1/a(0) + 1/a(1) + ... + 1/a(n-1)))) where f(x) is the smallest integer > x (see greedy algorithm above). - Robert FERREOL, Feb 22 2019
From Amiram Eldar, Oct 29 2020: (Start)
Sum_{n>=0} (-1)^n/(a(n)-1) = A118227.
Sum_{n>=0} (-1)^n/a(n) = 2 * A118227 - 1. (End)
Comments