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.

Previous Showing 21-30 of 43 results. Next

A122000 a(n) = ((2^n - 1)^(2^n - 1) + 1) / 2^n.

Original entry on oeis.org

1, 7, 102943, 27368368148803711, 533411691585101123706582594658103586126397951, 3566766192921360077810945505268211287512797261288920841093043641769808083046939618603793791988232043305924036607
Offset: 1

Views

Author

Alexander Adamchuk, Sep 11 2006

Keywords

Comments

A014566(n) = n^n + 1 is Sierpinski Number of the First Kind. A014566(2^n - 1) is divisible by 2^n. a(n) is a subset of A081216(n) = (n^n-(-1)^n)/(n+1).
2^p - 1 divides a(p-1) for prime p>2. Corresponding quotients are a(p-1) / (2^p - 1) = {1, 882850585445281, 28084773172609134470952326813135521948919663474715912134590894817085103016117634792155856629828598766188378241, ...}, where p = prime(n) for n>1. - Alexander Adamchuk, Jan 22 2007

Crossrefs

Programs

  • Mathematica
    Table[((2^n-1)^(2^n-1)+1)/2^n,{n,1,7}]

Formula

a(n) = A014566(2^n - 1) / 2^n.
a(n) = A081216(2^n - 1).
a(n) = A056009(2^n - 1).

A134883 Decimal expansion of Sum_{n>=1} 1/(n^n+1).

Original entry on oeis.org

7, 3, 9, 9, 4, 7, 9, 4, 3, 4, 9, 5, 4, 6, 5, 5, 1, 2, 2, 5, 6, 0, 2, 5, 5, 3, 0, 7, 3, 4, 9, 9, 4, 7, 8, 2, 0, 5, 6, 1, 1, 0, 6, 6, 5, 7, 4, 2, 2, 4, 3, 9, 6, 2, 8, 7, 4, 5, 4, 5, 6, 5, 1, 9, 9, 9, 8, 0, 4, 3, 0, 8, 5, 4, 0, 8, 4, 8, 8, 1, 0, 2, 8, 9, 7, 3, 9, 5, 3, 1, 1, 2, 0, 7, 1, 2, 1, 5, 6, 8, 2, 0, 5, 9
Offset: 0

Views

Author

Artur Jasinski, Nov 15 2007

Keywords

Comments

Constant formed from sum of reversed Sierpinski numbers of first kind A014566.

Examples

			0.7399479434954655122560255307349947820561106657422439628745456519998...
		

Crossrefs

Programs

  • Mathematica
    RealDigits[N[Sum[1/(n^n + 1), {n, 1, 150}], 100]][[1]] (* first zero removed *)

A184967 Numbers k such that k^k+1 is squarefree.

Original entry on oeis.org

1, 2, 4, 5, 6, 8, 9, 10, 12, 13, 16, 20, 21, 22, 24, 25, 26, 28, 29, 30, 32, 33, 34, 36, 37, 41, 42, 44, 45, 46, 48, 50, 52, 54, 56, 57, 58, 60, 61, 62, 64, 65, 66, 68, 72, 73, 74, 76, 77, 78, 80, 81, 84, 85, 86, 88, 90, 92, 93, 94, 96, 98, 100, 101, 102, 104, 105, 106, 108, 109, 110, 112, 113, 114, 116, 120, 121, 122
Offset: 1

Views

Author

Keywords

Comments

5^5+1 = 3126 = 2*3*521.
6^6+1 = 46657 = 13*37*97.
8^8 = 16777217 = 97*257*673.

Crossrefs

Programs

  • Magma
    [ n: n in [1..60] | IsSquarefree(n^n+1) ]; // Bruno Berselli, Mar 24 2011
    
  • Mathematica
    Select[Range@46,SquareFreeQ[#^#+1]&]
  • PARI
    isok(k) = issquarefree(k^k+1); \\ Michel Marcus, Feb 22 2021

Extensions

Extended by Bruno Berselli, Mar 24 2011
a(39)-a(78) from Amiram Eldar, Feb 22 2021

A238981 Sum of n-th powers of unitary divisors of n (d such that d divides n, gcd(d, n/d) = 1).

Original entry on oeis.org

1, 5, 28, 257, 3126, 47450, 823544, 16777217, 387420490, 10009766650, 285311670612, 8916117756914, 302875106592254, 11112685048647250, 437893920912786408, 18446744073709551617, 827240261886336764178, 39346558169931834836690, 1978419655660313589123980
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_, k_] := Sum[If[GCD[i, n] == i && GCD[i, n/i] == 1, i^k, 0], {i, n}]; Table[a[n, n], {n, 1, 24}]
    a[1] = 1; a[n_] := Times @@ (1 + First[#]^(n * Last[#]) &/@ FactorInteger[n]);  Array[a, 19] (* Amiram Eldar, Aug 10 2019 *)
  • PARI
    a(n) = sumdiv(n, d, d^n*(gcd(d, n/d) == 1)); \\ Michel Marcus, Mar 19 2014

Formula

For prime p, a(p) = p^p + 1; A125137 is a subsequence. - Michel Marcus, Nov 20 2015
a(n) = n^n+1 (A014566) if n is a prime power (A246655). - Michel Marcus, Nov 21 2015
a(n) = Sum_{d|n, gcd(d,n/d)=1} d^n. - Wesley Ivan Hurt, Apr 28 2023

A342489 a(n) = Sum_{d|n} phi(d)^(d-1).

Original entry on oeis.org

1, 2, 5, 10, 257, 38, 46657, 16394, 1679621, 262402, 10000000001, 4194350, 8916100448257, 13060740674, 4398046511365, 35184372105226, 18446744073709551617, 16926661124390, 39346408075296537575425, 144115188076118282, 3833759992447475168837
Offset: 1

Views

Author

Seiichi Manyama, Mar 13 2021

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := DivisorSum[n, EulerPhi[#]^(#-1) &]; Array[a, 20] (* Amiram Eldar, Mar 14 2021 *)
  • PARI
    a(n) = sumdiv(n, d, eulerphi(d)^(d-1));
    
  • PARI
    a(n) = sum(k=1, n, eulerphi(n/gcd(k, n))^(n/gcd(k, n)-2));
    
  • PARI
    my(N=40, x='x+O('x^N)); Vec(sum(k=1, N, eulerphi(k)^(k-1)*x^k/(1-x^k)))

Formula

a(n) = Sum_{k=1..n} phi(n/gcd(k, n))^(n/gcd(k, n) - 2).
G.f.: Sum_{k>=1} phi(k)^(k-1) * x^k/(1 - x^k).
If p is prime, a(p) = 1 + (p-1)^(p-1) = A014566(p-1).

A342707 T(n, k) is the result of replacing 2's by k's in the hereditary base-2 expansion of n; square array T(n, k) read by antidiagonals upwards, n, k >= 0.

Original entry on oeis.org

0, 1, 0, 0, 1, 0, 1, 1, 1, 0, 1, 2, 2, 1, 0, 2, 1, 3, 3, 1, 0, 1, 2, 4, 4, 4, 1, 0, 2, 2, 5, 27, 5, 5, 1, 0, 0, 3, 6, 28, 256, 6, 6, 1, 0, 1, 1, 7, 30, 257, 3125, 7, 7, 1, 0, 0, 2, 8, 31, 260, 3126, 46656, 8, 8, 1, 0, 1, 2, 9, 81, 261, 3130, 46657, 823543, 9, 9, 1, 0
Offset: 0

Views

Author

Rémy Sigrist, Jun 04 2021

Keywords

Examples

			Array T(n, k) begins:
  n\k|  0  1   2   3     4      5       6        7          8           9
  ---+-------------------------------------------------------------------
    0|  0  0   0   0     0      0       0        0          0           0
    1|  1  1   1   1     1      1       1        1          1           1
    2|  0  1   2   3     4      5       6        7          8           9
    3|  1  2   3   4     5      6       7        8          9          10
    4|  1  1   4  27   256   3125   46656   823543   16777216   387420489
    5|  2  2   5  28   257   3126   46657   823544   16777217   387420490
    6|  1  2   6  30   260   3130   46662   823550   16777224   387420498
    7|  2  3   7  31   261   3131   46663   823551   16777225   387420499
    8|  0  1   8  81  1024  15625  279936  5764801  134217728  3486784401
    9|  1  2   9  82  1025  15626  279937  5764802  134217729  3486784402
   10|  0  2  10  84  1028  15630  279942  5764808  134217736  3486784410
		

Crossrefs

See A341907 for a similar sequence.

Programs

  • PARI
    T(n,k) = { my (v=0, e); while (n, n-=2^e=valuation(n,2); v+=k^T(e,k)); v }

Formula

T(n, n) = A343255(n).
T(n, 0) = A345021(n).
T(n, 1) = A000120(n).
T(n, 2) = n.
T(n, 3) = A222112(n-1).
T(0, k) = 0.
T(1, k) = 1.
T(2, k) = k.
T(3, k) = k + 1.
T(4, k) = k^k = A000312(k).
T(5, k) = k^k + 1 = A014566(k).
T(6, k) = k^k + k = A066068(k).
T(7, k) = k^k + k + 1 = A066279(k).
T(16, k) = k^k^k = A002488(k).
T(m + n, k) = T(m, k) + T(n, k) when m AND n = 0 (where AND denotes the bitwise AND operator).

A366822 a(n) is phi(n^n + 1) where phi is the Euler totient function.

Original entry on oeis.org

1, 1, 4, 12, 256, 1040, 41472, 407680, 16515072, 152845056, 9897840000, 89493288192, 8732596764672, 129785922489600, 10576701872701440, 210729768933600000, 18446676793287966720, 275746753962112254720, 28084363369373740400640, 791359800910482004224000
Offset: 0

Views

Author

Sean A. Irvine, Oct 24 2023

Keywords

Crossrefs

Programs

  • Mathematica
    {1}~Join~Array[EulerPhi[#^# + 1] &, 19] (* Michael De Vlieger, Oct 24 2023 *)
  • PARI
    a(n) = eulerphi(n^n+1);

Formula

a(n) = A000010(A014566(n)).

A117812 a(n) = n^(2*n) - 1.

Original entry on oeis.org

0, 0, 15, 728, 65535, 9765624, 2176782335, 678223072848, 281474976710655, 150094635296999120, 99999999999999999999, 81402749386839761113320, 79496847203390844133441535, 91733330193268616658399616008, 123476695691247935826229781856255
Offset: 0

Views

Author

Reinhard Zumkeller, Oct 17 2006

Keywords

Comments

a(n) = A048861(n)*A014566(n) = A062206(n) - 1.

Crossrefs

Programs

A131836 Multiplicative persistence of the Sierpinski numbers of the first kind (n^n + 1).

Original entry on oeis.org

0, 0, 2, 2, 3, 2, 2, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

Keywords

Comments

Question: Are there any terms larger than 1 after a(22) = 2? In other words, do all terms of A014566 contain zero somewhere in their decimal representation after A014566(22) = 341427877364219557396646723585? - Antti Karttunen, Oct 08 2017

Examples

			For n=4 we have A014566(4) = Sierpinski number 257 --> 2*5*7 = 70 --> 7*0 = 0 thus persistence = 2, and a(4) = 2. - Edited by _Antti Karttunen_, Oct 08 2017
		

Crossrefs

Programs

  • Maple
    P:=proc(n) local i,k,w,ok,cont; for i from 1 by 1 to n do w:=1; k:=i^i+1; ok:=1; if k<10 then print(0); else cont:=1; while ok=1 do while k>0 do w:=w*(k-(trunc(k/10)*10)); k:=trunc(k/10); od; if w<10 then ok:=0; print(cont); else cont:=cont+1; k:=w; w:=1; fi; od; fi; od; end: P(100);
  • Mathematica
    Table[-1 + Length@ NestWhileList[Times @@ IntegerDigits@ # &, If[n == 0, 2, n^n + 1], # > 9 &], {n, 105}] (* Michael De Vlieger, Oct 08 2017 *)
  • Scheme
    ;; The whole program follows:
    (define (A131836 n) (A031346 (A014566 n)))
    (define (A014566 n) (+ 1 (expt n n)))
    (define (A031346 n) (let loop ((n n) (k 0)) (if (< n 10) k (loop (A007954 n) (+ 1 k)))))
    (define (A007954 n) (if (zero? n) n (let loop ((n n) (m 1)) (if (zero? n) m (let ((d (modulo n 10))) (loop (/ (- n d) 10) (* d m)))))))
    ;; Antti Karttunen, Oct 08 2017

Formula

a(n) = A031346(A014566(n)). - Michel Marcus, Oct 08 2017

A249784 Number of divisors of n^(n^n).

Original entry on oeis.org

1, 5, 28, 513, 3126, 2176875649, 823544, 50331649, 774840979, 100000000020000000001, 285311670612, 158993694406808436568227841, 302875106592254, 123476695691247958050243432972289, 191751059232884087544279144287109376, 73786976294838206465
Offset: 1

Views

Author

Jon E. Schoenfield, Nov 05 2014

Keywords

Comments

An infinite number of squares are terms of this sequence.
Proof: for any n of the form (p*q)^k (with p and q distinct primes), a(n) = (k * n^n + 1)^2.
It seems likely that the only nontrivial palindromes in this sequence comprise a subset of these squares and occur at n = 10^(10^M) for M>=0; at such values of n, a(n) = (10^(10^(10^M + M) + M) + 1)^2 = A033934(10^(10^M + M) + M). The actual decimal expansion of each of these numbers is of the form 1000...0002000...0001, where the total number of zero digits on each side of the 2 is 10^(10^M + M) + M - 1.

Examples

			12 = 2^2 * 3^1 (two distinct prime factors, with multiplicities e_1=2 and e_2=1), so a(12) = (2*k+1)*(1*k+1) = 2*k^2 + 3*k + 1 where k = 12^12, so a(12) = 158993694406808436568227841.
		

Crossrefs

Programs

  • Magma
    // program to generate b-file
    for n in [1..155] do
       k:=n^n;
       F:=Factorization(n);
       prod:=1;
       for j in [1..#F] do
          prod*:=F[j,2]*k + 1;
       end for;
       n, prod;
    end for;
    
  • PARI
    a(n)=my(v=factor(n)[,2]*n^n); prod(i=1,#v,v[i]+1) \\ Charles R Greathouse IV, Jul 21 2015
  • Sage
    def A249784(n):
       n_exp_n = n^n
       return mul(exp[1]*n_exp_n + 1 for exp in factor(n))
    [A249784(n) for n in (1..16)] # Peter Luschny, Nov 08 2014
    

Formula

a(n) = A000005(A002488(n)).
a(n) = Product_{j=1..m} (e_j * n^n + 1)
where m = number of distinct prime factors of n
and e_j = multiplicity of the j-th prime factor.
If n is a prime p, then m=1 and e_1=1, so
a(p) = p^p + 1 = A000312(p) + 1 = A014566(p).
If n=10^L, then m=2 and e_1=e_2=L, so
a(10^L) = (L * 10^(L * 10^L) + 1)^2.
Previous Showing 21-30 of 43 results. Next