cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-10 of 43 results. Next

A121999 Primes p such that p^2 divides Sierpinski number A014566((p-1)/2).

Original entry on oeis.org

29, 37, 3373
Offset: 1

Views

Author

Alexander Adamchuk, Sep 11 2006

Keywords

Comments

Subsequence of A003628.
No other terms below 10^11. - Max Alekseyev, Sep 18 2010

Crossrefs

Programs

  • Mathematica
    Do[p=Prime[n];f=((p-1)/2)^((p-1)/2)+1;If[IntegerQ[f/p^2],Print[p]],{n,1,3373}]
  • PARI
    { forprime(p=3, 10^11, if(Mod((p-1)/2, p^2)^((p-1)/2)==-1, print(p); )) } \\ Max Alekseyev, Sep 18 2010

Formula

Elements of A125854 that are congruent to 5 or 7 modulo 8, i.e., primes p such that p == 5 or 7 (mod 8) and 2^(p-1) == 1+p (mod p^2). - Max Alekseyev, Sep 18 2010

A124899 Sierpinski quotient ((2n-1)^(2n-1) + 1)/(2n) = A014566(2n-1)/(2n).

Original entry on oeis.org

1, 7, 521, 102943, 38742049, 23775972551, 21633936185161, 27368368148803711, 45957792327018709121, 98920982783015679456199, 265572137199362841880960201, 870019499993663001431459704607, 3416070845000481662841943594125601
Offset: 1

Views

Author

Alexander Adamchuk, Nov 12 2006

Keywords

Comments

2n divides Sierpinski number A014566(2n-1).
2^n divides A014566(2^n-1); A014566(2^n - 1) / 2^n = A081216(2^n - 1) = A122000(n) = {1, 7, 102943, 27368368148803711, 533411691585101123706582594658103586126397951, ...}.
p+1 divides A014566(p) for prime p; A014566(p)/(p+1) = A056852(n) = {7, 521, 102943, 23775972551, 21633936185161, ...}.
Primes in this sequence are {7, 521, 45957792327018709121}.

Crossrefs

Cf. A014566 (Sierpinski numbers of the first kind: n^n + 1).

Programs

  • GAP
    List([1..15],n->((2*n-1)^(2*n-1)+1)/(2*n)); # Muniru A Asiru, Apr 08 2018
    
  • Maple
    seq(((2*n-1)^(2*n-1)+1)/(2*n),n=1..20); # Muniru A Asiru, Apr 08 2018
  • Mathematica
    Table[((2n-1)^(2n-1)+1)/(2n),{n,1,20}]
  • PARI
    a(n) = ((2*n-1)^(2*n-1) + 1)/(2*n); \\ Michel Marcus, Apr 08 2018

Formula

a(n) = ((2n-1)^(2n-1) + 1)/(2n) = A014566(2n-1)/(2n).
(2n-1)^(a(n)-1) == 1 (mod a(n)). - Thomas Ordowski, Mar 16 2021

A001008 a(n) = numerator of harmonic number H(n) = Sum_{i=1..n} 1/i.

Original entry on oeis.org

1, 3, 11, 25, 137, 49, 363, 761, 7129, 7381, 83711, 86021, 1145993, 1171733, 1195757, 2436559, 42142223, 14274301, 275295799, 55835135, 18858053, 19093197, 444316699, 1347822955, 34052522467, 34395742267, 312536252003, 315404588903, 9227046511387
Offset: 1

Views

Author

Keywords

Comments

H(n)/2 is the maximal distance that a stack of n cards can project beyond the edge of a table without toppling.
By Wolstenholme's theorem, p^2 divides a(p-1) for all primes p > 3.
From Alexander Adamchuk, Dec 11 2006: (Start)
p divides a(p^2-1) for all primes p > 3.
p divides a((p-1)/2) for primes p in A001220.
p divides a((p+1)/2) or a((p-3)/2) for primes p in A125854.
a(n) is prime for n in A056903. Corresponding primes are given by A067657. (End)
a(n+1) is the numerator of the polynomial A[1, n](1) where the polynomial A[genus 1, level n](m) is defined to be Sum_{d = 1..n - 1} m^(n - d)/d. (See the Mathematica procedure generating A[1, n](m) below.) - Artur Jasinski, Oct 16 2008
Better solutions to the card stacking problem have been found by M. Paterson and U. Zwick (see link). - Hugo Pfoertner, Jan 01 2012
a(n) = A213999(n, n-1). - Reinhard Zumkeller, Jul 03 2012
a(n) coincides with A175441(n) if and only if n is not from the sequence A256102. The quotient a(n) / A175441(n) for n in A256102 is given as corresponding entry of A256103. - Wolfdieter Lang, Apr 23 2015
For a very short proof that the Harmonic series diverges, see the Goldmakher link. - N. J. A. Sloane, Nov 09 2015
All terms are odd while corresponding denominators (A002805) are all even for n > 1 (proof in Pólya and Szegő). - Bernard Schott, Dec 24 2021

Examples

			H(n) = [ 1, 3/2, 11/6, 25/12, 137/60, 49/20, 363/140, 761/280, 7129/2520, ... ].
Coincidences with A175441: the first 19 entries coincide because 20 is the first entry of A256102. Indeed, a(20)/A175441(20) = 55835135 / 11167027 = 5 = A256103(1). - _Wolfdieter Lang_, Apr 23 2015
		

References

  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See pp. 258-261.
  • H. W. Gould, Combinatorial Identities, Morgantown Printing and Binding Co., 1972, # 1.45, page 6, #3.122, page 36.
  • R. L. Graham, D. E. Knuth and O. Patashnik, Concrete Mathematics. Addison-Wesley, Reading, MA, 1990, p. 259.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers. 3rd ed., Oxford Univ. Press, 1954, page 347.
  • D. E. Knuth, The Art of Computer Programming. Addison-Wesley, Reading, MA, Vol. 1, p. 615.
  • G. Pólya and G. Szegő, Problems and Theorems in Analysis, volume II, Springer, reprint of the 1976 edition, 1998, problem 251, p. 154.
  • 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).

Crossrefs

Cf. A145609-A145640. - Artur Jasinski, Oct 16 2008
Cf. A003506. - Paul Curtz, Nov 30 2013
The following fractions are all related to each other: Sum 1/n: A001008/A002805, Sum 1/prime(n): A024451/A002110 and A106830/A034386, Sum 1/nonprime(n): A282511/A282512, Sum 1/composite(n): A250133/A296358.
Cf. A195505.

Programs

  • GAP
    List([1..30],n->NumeratorRat(Sum([1..n],i->1/i))); # Muniru A Asiru, Dec 20 2018
  • Haskell
    import Data.Ratio ((%), numerator)
    a001008 = numerator . sum . map (1 %) . enumFromTo 1
    a001008_list = map numerator $ scanl1 (+) $ map (1 %) [1..]
    -- Reinhard Zumkeller, Jul 03 2012
    
  • Magma
    [Numerator(HarmonicNumber(n)): n in [1..30]]; // Bruno Berselli, Feb 17 2016
    
  • Maple
    A001008 := proc(n)
        add(1/k,k=1..n) ;
        numer(%) ;
    end proc:
    seq( A001008(n),n=1..40) ; # Zerinvary Lajos, Mar 28 2007; R. J. Mathar, Dec 02 2016
  • Mathematica
    Table[Numerator[HarmonicNumber[n]], {n, 30}]
    (* Procedure generating A[1,n](m) (see Comments section) *) m =1; aa = {}; Do[k = 0; Do[k = k + m^(r - d)/d, {d, 1, r - 1}]; AppendTo[aa, k], {r, 1, 20}]; aa (* Artur Jasinski, Oct 16 2008 *)
    Numerator[Accumulate[1/Range[25]]] (* Alonso del Arte, Nov 21 2018 *)
    Numerator[Table[((n - 1)/2)*HypergeometricPFQ[{1, 1, 2 - n}, {2, 3}, 1] + 1, {n, 1, 29}]] (* Artur Jasinski, Jan 08 2021 *)
  • PARI
    A001008(n) = numerator(sum(i=1,n,1/i)) \\ Michael B. Porter, Dec 08 2009
    
  • PARI
    H1008=List(1); A001008(n)={for(k=#H1008,n-1,listput(H1008,H1008[k]+1/(k+1))); numerator(H1008[n])} \\ about 100x faster for n=1..1500. - M. F. Hasler, Jul 03 2019
    
  • Python
    from sympy import Integer
    [sum(1/Integer(i) for i in range(1, n + 1)).numerator() for n in range(1, 31)]  # Indranil Ghosh, Mar 23 2017
    
  • Sage
    def harmonic(a, b):  # See the F. Johansson link.
        if b - a == 1:
            return 1, a
        m = (a+b)//2
        p, q = harmonic(a,m)
        r, s = harmonic(m,b)
        return p*s+q*r, q*s
    def A001008(n): H = harmonic(1,n+1); return numerator(H[0]/H[1])
    [A001008(n) for n in (1..29)] # Peter Luschny, Sep 01 2012
    

Formula

H(n) ~ log n + gamma + O(1/n). [See Hardy and Wright, Th. 422.]
log n + gamma - 1/n < H(n) < log n + gamma + 1/n [follows easily from Hardy and Wright, Th. 422]. - David Applegate and N. J. A. Sloane, Oct 14 2008
G.f. for H(n): log(1-x)/(x-1). - Benoit Cloitre, Jun 15 2003
H(n) = sqrt(Sum_{i = 1..n} Sum_{j = 1..n} 1/(i*j)). - Alexander Adamchuk, Oct 24 2004
a(n) is the numerator of Gamma/n + Psi(1 + n)/n = Gamma + Psi(n), where Psi is the digamma function. - Artur Jasinski, Nov 02 2008
H(n) = 3/2 + 2*Sum_{k = 0..n-3} binomial(k+2, 2)/((n-2-k)*(n-1)*n), n > 1. - Gary Detlefs, Aug 02 2011
H(n) = (-1)^(n-1)*(n+1)*n*Sum_{k = 0..n-1} k!*Stirling2(n-1, k) * Stirling1(n+k+1,n+1)/(n+k+1)!. - Vladimir Kruchinin, Feb 05 2013
H(n) = n*Sum_{k = 0..n-1} (-1)^k*binomial(n-1,k)/(k+1)^2. (Wenchang Chu) - Gary Detlefs, Apr 13 2013
H(n) = (1/2)*Sum_{k = 1..n} (-1)^(k-1)*binomial(n,k)*binomial(n+k, k)/k. (H. W. Gould) - Gary Detlefs, Apr 13 2013
E.g.f. for H(n) = a(n)/A002805(n): (gamma + log(x) - Ei(-x)) * exp(x), where gamma is the Euler-Mascheroni constant, and Ei(x) is the exponential integral. - Vladimir Reshetnikov, Apr 24 2013
H(n) = residue((psi(-s)+gamma)^2/2, {s, n}) where psi is the digamma function and gamma is the Euler-Mascheroni constant. - Jean-François Alcover, Feb 19 2014
H(n) = Sum_{m >= 1} n/(m^2 + n*m) = gamma + digamma(1+n), numerators and denominators. (see Mathworld link on Digamma). - Richard R. Forberg, Jan 18 2015
H(n) = (1/2) Sum_{j >= 1} Sum_{k = 1..n} ((1 - 2*k + 2*n)/((-1 + k + j*n)*(k + j*n))) + log(n) + 1/(2*n). - Dimitri Papadopoulos, Jan 13 2016
H(n) = (n!)^2*Sum_{k = 1..n} 1/(k*(n-k)!*(n+k)!). - Vladimir Kruchinin, Mar 31 2016
a(n) = Stirling1(n+1, 2) / gcd(Stirling1(n+1, 2), n!) = A000254(n) / gcd(A000254(n), n!). - Max Alekseyev, Mar 01 2018
From Peter Bala, Jan 31 2019: (Start)
H(n) = 1 + (1 + 1/2)*(n-1)/(n+1) + (1/2 + 1/3)*(n-1)*(n-2)/((n+1)*(n+2)) + (1/3 + 1/4)*(n-1)*(n-2)*(n-3)/((n+1)*(n+2)*(n+3)) + ... .
H(n)/n = 1 + (1/2^2 - 1)*(n-1)/(n+1) + (1/3^2 - 1/2^2)*(n-1)*(n-2)/((n+1)*(n+2)) + (1/4^2 - 1/3^2)*(n-1)*(n-2)*(n-3)/((n+1)*(n+2)*(n+3)) + ... .
For odd n >= 3, (1/2)*H((n-1)/2) = (n-1)/(n+1) + (1/2)*(n-1)*(n-3)/((n+1)*(n+3)) + 1/3*(n-1)*(n-3)*(n-5)/((n+1)*(n+3)*(n+5)) + ... . Cf. A195505. See the Bala link in A036970. (End)
H(n) = ((n-1)/2) * hypergeom([1,1,2-n], [2,3], 1) + 1. - Artur Jasinski, Jan 08 2021
Conjecture: for nonzero m, H(n) = (1/m)*Sum_{k = 1..n} ((-1)^(k+1)/k) * binomial(m*k,k)*binomial(n+(m-1)*k,n-k). The case m = 1 is well-known; the case m = 2 is given above by Detlefs (dated Apr 13 2013). - Peter Bala, Mar 04 2022
a(n) = the (reduced) numerator of the continued fraction 1/(1 - 1^2/(3 - 2^2/(5 - 3^2/(7 - ... - (n-1)^2/(2*n-1))))). - Peter Bala, Feb 18 2024
H(n) = Sum_{k=1..n} (-1)^(k-1)*binomial(n,k)/k (H. W. Gould). - Gary Detlefs, May 28 2024

Extensions

Edited by Max Alekseyev, Oct 21 2011
Changed title, deleting the incorrect name "Wolstenholme numbers" which conflicted with the definition of the latter in both Weisstein's World of Mathematics and in Wikipedia, as well as with OEIS A007406. - Stanislav Sykora, Mar 25 2016

A007571 a(n) = largest prime factor of n^n + 1.

Original entry on oeis.org

2, 5, 7, 257, 521, 97, 911, 673, 530713, 27961, 58367, 2227777, 79301, 176597, 142111, 67280421310721, 45957792327018709121, 33388093, 870542161121, 4406613081041681, 22864311556633, 73194743542229, 1522029233, 27250359649
Offset: 1

Views

Author

Keywords

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Magma
    [Max(PrimeDivisors(n^n+1)):n in [1..24]]; // Marius A. Burtea, Aug 24 2019
  • Mathematica
    Table[ FactorInteger[ n^n + 1, FactorComplete -> True ] [ [ -1, 1 ] ], {n, 1, 25} ]
  • PARI
    for(k=1, 24, my(x=factor(k^k+1), f=x[#x[, 1], 1]); print1(f,", ")) \\ Hugo Pfoertner, Aug 23 2019
    

Formula

a(n) = A006530(A014566(n)). - Michel Marcus, Aug 24 2019

A110932 Numbers k such that 2*k^k + 1 is prime.

Original entry on oeis.org

0, 1, 12, 18, 251, 82992
Offset: 0

Views

Author

Ray G. Opao, Sep 25 2005

Keywords

Comments

As a "list of numbers such that ...", the sequence should have offset 1, but to preserve the validity of formulas referring to this sequence, the offset was set to 0 when the initial value a(0)=0 was added. - M. F. Hasler, Sep 02 2012

Crossrefs

Cf. A110931, A121270 (= primes in A014566), A088790, A160360, A160600.
The primes 2n^n+1, for k<4, n=a(k)<251, are listed at A216148(k) = A216147(a(k)). - M. F. Hasler, Sep 02 2012

Programs

  • Mathematica
    Join[{0}, Select[Range[1000], PrimeQ[2*#^# + 1] &]] (* Robert Price, Mar 27 2019 *)
  • PARI
    is_A110932(n)=ispseudoprime(n^n*2+1) \\ M. F. Hasler, Sep 02 2012

Extensions

a(5) from Serge Batalov, Apr 08 2018

A121270 Prime Sierpinski numbers of the first kind: primes of the form k^k+1.

Original entry on oeis.org

2, 5, 257
Offset: 1

Views

Author

Alexander Adamchuk, Aug 23 2006

Keywords

Comments

Sierpinski proved that k>1 must be of the form 2^(2^j) for k^k+1 to be a prime. All a(n) > 2 must be the Fermat numbers F(m) with m = j+2^j = A006127(j). [Edited by Jeppe Stig Nielsen, Jul 09 2023]

References

  • See e.g. pp. 156-157 in M. Krizek, F. Luca & L. Somer, 17 Lectures on Fermat Numbers, Springer-Verlag NY 2001. - Walter Nissen, Mar 20 2010

Crossrefs

Primes of form b*k^k + 1: this sequence (b=1), A216148 (b=2), A301644 (b=3), A301641 (b=4), A301642 (b=16).

Programs

  • Mathematica
    Do[f=n^n+1;If[PrimeQ[f],Print[{n,f}]],{n,1,1000}]
  • PARI
    for(n=1,9,if(ispseudoprime(t=n^n+1),print1(t", "))) \\ Charles R Greathouse IV, Feb 01 2013

Extensions

Definition rewritten by Walter Nissen, Mar 20 2010

A081216 a(n) = (n^n-(-1)^n)/(n+1).

Original entry on oeis.org

0, 1, 1, 7, 51, 521, 6665, 102943, 1864135, 38742049, 909090909, 23775972551, 685853880635, 21633936185161, 740800455037201, 27368368148803711, 1085102592571150095, 45957792327018709121, 2070863582910344082917, 98920982783015679456199
Offset: 0

Views

Author

Vladeta Jovovic, Apr 17 2003

Keywords

Comments

a(n) is prime for n = {3, 5, 17, 157} = A056826(n) Primes p such that (p^p + 1)/(p + 1) is a prime. Prime a(n) are {7, 521, 45957792327018709121, ...}. Bisection of a(n) is Sierpinski quotient a(2n-1) = A124899(n) = ((2n-1)^(2n-1) + 1)/(2n) = A014566(2n-1)/(2n). - Alexander Adamchuk, Nov 12 2006
This is related to the dimension of the primitive middle cohomology of Dwork hypersurfaces x1**n+x2**n+...+xn**n=n*psi*x1*x2*...*xn. [F. Chapoton, Dec 11 2009]

Crossrefs

Main diagonal of A062160.
Cf. A056826, A124899, A014566 (Sierpinski numbers of the first kind: n^n + 1).

Programs

  • Maple
    a:= n-> (n^n-(-1)^n)/(n+1):
    seq(a(n), n=0..20);  # Alois P. Heinz, May 11 2023
  • PARI
    a(n) = (n^n-(-1)^n)/(n+1); \\ Michel Marcus, Jul 29 2017
  • Sage
    [((n - 1)**(n - 1) + (-1)**n) // n for n in range(1, 16)]
    

Extensions

Edited by F. Chapoton, Feb 03 2011

A110567 a(n) = n^(n+1) + 1.

Original entry on oeis.org

1, 2, 9, 82, 1025, 15626, 279937, 5764802, 134217729, 3486784402, 100000000001, 3138428376722, 106993205379073, 3937376385699290, 155568095557812225, 6568408355712890626, 295147905179352825857, 14063084452067724991010
Offset: 0

Views

Author

Jonathan Vos Post, Sep 12 2005

Keywords

Comments

For n >= 2, a(n) = the n-th positive integer such that a(n) (base n) has a block of exactly n consecutive zeros.
Comments from Alexander Adamchuk, Nov 12 2006 (Start)
(2n+1)^2 divides a(2n). a(2n)/(2n+1)^2 = {1,1,41,5713,1657009,826446281,633095889817,691413758034721,...} = A081215(2n).
p divides a(p-1) for prime p. a(p-1)/p = {1,3,205,39991,9090909091,8230246567621,...} = A081209(p-1) = A076951(p-1).
p^2 divides a(p-1) for an odd prime p. a(p-1)/p^2 = {1,41,5713,826446281,633095889817,1021273028302258913,1961870762757168078553, 14199269001914612973017444081,...} = A081215(p-1).
Prime p divides a((p-3)/2) for p = {13,17,19,23,37,41,43,47,61,67,71,89, 109,113,137,139,157,163,167,181,191,...}.
Prime p divides a((p-5)/4) for p = {29,41,61,89,229,241,281,349,421,509,601,641,661,701,709,769,809,821,881,...} = A107218(n) Primes of the form 4x^2+25y^2.
Prime p divides a((p-7)/6) for p = {79,109,127,151,313,421,541,601,613,751,757,787,...}.
Prime p divides a((p-9)/8) for p = {41,337,401,521,569,577,601,857,929,937,953,977,...} A subset of A007519(n) Primes of form 8n+1.
Prime p divides a((p-11)/10) for p = {41,181,331,601,761,1021,1151,1231,1801,...}.
Prime p divides a((p-13)/12) for p = {313,337,433,1621,1873,1993,2161,2677,2833,...}. (End)

Examples

			Examples illustrating the Comment:
a(2) = 9 because the first positive integer (base 2) with a block of 2 consecutive zeros is 100 (base 2) = 4, and the 2nd is 1001 (base 2) = 9 = 1 + 2^3.
a(3) = 82 because the first positive integer (base 3) with a block of 3 consecutive zeros is 1000 (base 3) = 81, the 2nd is 2000 (base 3) = 54 and the 3rd is 10001 (base 3) = 82 = 1 + 3^4.
a(4) = 1025 because the first positive integer (base 4) with a block of 4 consecutive zeros is 10000 (base 4) = 256, the 2nd is 20000 (base 4) = 512, the 3rd is 30000 (base 4) = 768 and the 4th 100001 (base 4) = 1025 = 1 + 4^5. and the 2nd is 1001 (base 2) = 9 = 1 + 2^3.
		

Crossrefs

Cf. A007778: n^(n+1); A000312: n^n; A014566: Sierpinski numbers of the first kind: n^n + 1.

Programs

  • Magma
    [n^(n+1) + 1: n in [0..25]]; // G. C. Greubel, Oct 16 2017
  • Mathematica
    Table[n^(n+1)+1,{n,0,30}] (* Harvey P. Dale, Oct 30 2015 *)
  • PARI
    for(n=0,25, print1(1 + n^(n+1), ", ")) \\ G. C. Greubel, Aug 31 2017
    

Formula

a(n) = A007778(n) + 1.
a(n) = A110567(n) for n > 1. - Georg Fischer, Oct 20 2018

Extensions

Entry revised by N. J. A. Sloane, Oct 20 2018 at the suggestion of Georg Fischer.

A125854 Primes p with the property that p divides the Wolstenholme number A001008((p+1)/2).

Original entry on oeis.org

3, 29, 37, 3373, 2001907169
Offset: 1

Views

Author

Alexander Adamchuk, Dec 11 2006

Keywords

Comments

Note that if prime p>3 divides A001008((p+1)/2) then it also divides A001008((p-3)/2).
Note that for a prime p, H([p/2]) == 2*(2^(-p(p-1)) - 1)/p^2 (mod p). Therefore a prime p divides the Wolstenholme number A001008((p+1)/2) if and only if 2^(-p(p-1)) == 1 - p^2 (mod p^3) or, equivalently, 2^(p-1) == 1 + p (mod p^2).
Disjunctive union of the sequences A154998 and A121999 that contain primes congruent respectively to 1,3 and 5,7 modulo 8. (Alekseyev)
a(6) > 5.5*10^12. - Giovanni Resta, Apr 13 2017
Primes p that are base-((p-1)/2) Wieferich primes, that is, primes p such that ((p-1)/2)^(p-1) == 1 (mod p^2). - Jianing Song, Jan 27 2019

Examples

			a(1) = 3 because prime 3 divides A001008(2) = 3 and there is no p < 3 that divides A001008((p+1)/2).
a(2) = 29 because 29 divides A001008(15) = 1195757 and there is no prime p (3 < p < 29) that divides A001008((p+1)/2).
		

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[1, 5000]],
    Divisible[Numerator[HarmonicNumber[(# + 1)/2]], #] &] (* Robert Price, May 10 2019 *)

Extensions

Entry revised and a(5) = 2001907169 provided by Max Alekseyev, Jan 18 2009
Edited by Max Alekseyev, Oct 13 2009

A055385 Smallest prime factor of n^n + 1.

Original entry on oeis.org

2, 5, 2, 257, 2, 13, 2, 97, 2, 101, 2, 89, 2, 29, 2, 274177, 2, 5, 2, 148721, 2, 5, 2, 17, 2, 53, 2, 449, 2, 17, 2, 641, 2, 13, 2, 17, 2, 5, 2, 17, 2, 5, 2, 41, 2, 29, 2, 769, 2, 41, 2, 89, 2, 13, 2, 17, 2, 5, 2, 17, 2, 5, 2, 59649589127497217, 2, 37, 2, 41, 2, 13, 2, 97, 2, 149
Offset: 1

Views

Author

Walter Nissen, Jun 24 2000

Keywords

Comments

If we use the commonly accepted convention that 0^0 = 1, then a(0) = 2. - Chai Wah Wu, Jul 22 2019

Examples

			4^4 + 1 = 257 prime, so a(4) = 257;
6^6 + 1 = 13 * 37 * 97, so a(6) = 13.
		

References

  • C. Stanley Ogilvy and John T. Anderson, Excursions in Number Theory. Dover. New York: 1988. Page 82.

Crossrefs

Programs

  • Mathematica
    Table[FactorInteger[n^n + 1][[1, 1]], {n, 74}] (* Vincenzo Librandi, Jul 23 2013 *)
  • PARI
    a(n) = {if (n % 2, return (2)); return (factor(n^n + 1)[1, 1]);} \\ Michel Marcus, Jul 23 2013
Showing 1-10 of 43 results. Next