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 41-50 of 92 results. Next

A172035 Smallest exponent k > 1 that sum of digits of k-th power of the n-th prime is a prime (n=1,2,...) or 0 if no such k exists.

Original entry on oeis.org

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

Views

Author

Ulrich Krug (leuchtfeuer37(AT)gmx.de), Jan 23 2010

Keywords

Comments

k = 1 is the "trivial" case: sod(prime(n)) = prime(m)
n = 2, prime(2) = 3: 3^k is for k > 1 a multiple of 3^2.

Examples

			sod(2^5)=5, sod(5^2)=7, sod(7^2)=13, sod(11^9)=53, sod(13^3)=19, sod(17^2)=19, sod(19^5)=37, sod(23^3)=17, sod(29^2)=13, sod(31^7)=31, sod(37^2)=19, sod(41^4)=31, sod(43^5)=31, sod(47^2)=13, sod(53^2)=19, sod(59^5)=47, sod(61^2)=13, sod(67^3)=19, sod(71^6)=37, sod(73^2)=19, sod(79^2)=13, sod(83^2)=31, sod(89^2)=19, sod(97^4)=43, sod(101^8)=67, sod(103^4)=31, sod(107^2)=19, sod(109^2)=19, sod(113^4)=31, sod(127^2)=19, sod(131^8)=61, sod(137^2)=31, sod(139^3)=37, sod(149^2)=7, sod(151^2)=13, sod(157^4)=31, sod(163^4)=37, sod(167^6)=73, sod(173^2)=31, sod(179^4)=37, sod(181^2)=19, sod(191^10)=97, sod(193^3)=37, sod(197^4)=37, sod(199^2)=19, sod(211^3)=37, sod(223^2)=31, sod(227^4)=43, sod(229^3)=37.
		

References

  • M. Fujiwara, Y. Ogawa: Introduction to truly beautiful Mathematics, Chikuma Shobo, Tokyo 2005.
  • Theo Kempermann, Zahlentheoretische Kostproben, Harri Deutsch, 2. aktualisierte Auflage 2005.
  • Hans Schubart: Einfuehrung in die klassische und moderne Zahlentheorie, Vieweg, Braunschweig 1974.

Crossrefs

Cf. A172216. - Klaus Brockhaus, Jan 29 2010

Programs

  • Magma
    S:=[ 5, 0 ]; for n in [3..103] do j:=2; while not IsPrime(&+Intseq(NthPrime(n)^j)) do j+:=1; end while; Append(~S, j); end for; S; // Klaus Brockhaus, Jan 29 2010

Extensions

More terms from Klaus Brockhaus, Jan 29 2010
Edited by Charles R Greathouse IV, Aug 02 2010

A184328 Primes whose digital product is a positive square.

Original entry on oeis.org

11, 19, 41, 149, 191, 199, 229, 263, 281, 313, 331, 419, 433, 449, 491, 499, 661, 683, 797, 821, 829, 863, 881, 911, 919, 941, 977, 991, 1229, 1289, 1433, 1499, 1559, 1669, 1747, 1889, 1933, 1949, 1999, 2129, 2383, 2693, 2819, 2833, 2963, 3319, 3391, 3413
Offset: 1

Views

Author

Dario Piazzalunga, Dec 24 2012

Keywords

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(4000) | not IsZero(t) and IsSquare(t) where t is &*Intseq(p)]; // Bruno Berselli, Dec 25 2012
  • Mathematica
    fQ[n_] := Module[{d = Times @@ IntegerDigits[n]}, d > 0 && IntegerQ[Sqrt[d]]];Select[Prime[Range[1000]], fQ] (* T. D. Noe, Dec 24 2012 *)

Extensions

Corrected and extended by T. D. Noe, Dec 24 2012

A230222 Smallest of four consecutive palindromic primes with equal digital sum.

Original entry on oeis.org

185595581, 317565713, 10832723801, 10875857801, 16831813861, 16832623861, 33396769333, 36215951263, 39003830093, 1069319139601, 1075309035701, 1181969691811, 1221739371221, 1269056509621, 1270668660721, 1292808082921, 1320348430231, 1385647465831
Offset: 1

Views

Author

Shyam Sunder Gupta, Oct 12 2013

Keywords

Examples

			185595581 is in the sequence because 185595581, 185676581, 185757581 and 185838581 are consecutive palindromic primes and the sum of the digits of each = 47.
		

Crossrefs

A239694 Base 8 sum of digits of prime(n).

Original entry on oeis.org

2, 3, 5, 7, 4, 6, 3, 5, 9, 8, 10, 9, 6, 8, 12, 11, 10, 12, 4, 8, 3, 9, 6, 5, 6, 10, 12, 9, 11, 8, 15, 5, 4, 6, 9, 11, 10, 9, 13, 12, 11, 13, 16, 4, 8, 10, 8, 13, 10, 12, 9, 15, 10, 13, 5, 11, 10, 12, 11, 8, 10, 13, 13, 17, 12, 16, 9, 8, 11, 13, 10, 16, 17, 16
Offset: 1

Views

Author

Tom Edgar, Mar 24 2014

Keywords

Comments

a(n) is the rank of prime(n) in the base-8 dominance order on the natural numbers.

Examples

			The sixth prime is 13, 13 in base 8 is (1,5) so a(6)=1+5=6.
		

Crossrefs

Programs

  • Magma
    [&+Intseq(NthPrime(n),8): n in [1..100]]; // Vincenzo Librandi, Mar 25 2014
    
  • Mathematica
    Table[Plus @@ IntegerDigits[Prime[n], 8], {n, 1, 100}] (* Vincenzo Librandi, Mar 25 2014 *)
  • PARI
    a(n) = sumdigits(prime(n), 8); \\ Michel Marcus, Mar 04 2023
  • Sage
    [sum(i.digits(base=8)) for i in primes_first_n(200)]
    

Formula

a(n) = A053829(A000040(n)).

A247797 Lexicographically earliest permutation of prime numbers, such that adjacent terms have coprime sums of digits in decimal representation.

Original entry on oeis.org

2, 3, 5, 7, 11, 23, 13, 29, 17, 41, 31, 43, 19, 47, 37, 61, 53, 67, 59, 83, 71, 89, 73, 137, 79, 113, 97, 131, 101, 139, 103, 151, 107, 157, 109, 173, 127, 179, 149, 191, 163, 193, 167, 197, 181, 199, 211, 223, 227, 229, 233, 241, 251, 263, 239, 269, 257
Offset: 1

Views

Author

Reinhard Zumkeller, Nov 25 2014

Keywords

Comments

A049084(a(n)) defines a permutation of the positive integers, cf. A250552.

Crossrefs

Programs

  • Haskell
    import Data.List (delete)
    a247797 n = a247797_list !! (n-1)
    a247797_list = f 1 $ zip a000040_list a007605_list where
       f q' vws = g vws where
         g  ((p,q):pqs) = if gcd q q' == 1
                             then p : f q (delete (p,q) vws) else g pqs

A376714 Sum of squares of the decimal digits of the n-th prime.

Original entry on oeis.org

4, 9, 25, 49, 2, 10, 50, 82, 13, 85, 10, 58, 17, 25, 65, 34, 106, 37, 85, 50, 58, 130, 73, 145, 130, 2, 10, 50, 82, 11, 54, 11, 59, 91, 98, 27, 75, 46, 86, 59, 131, 66, 83, 91, 131, 163, 6, 17, 57, 89, 22, 94, 21, 30, 78, 49, 121, 54, 102, 69, 77, 94, 58, 11
Offset: 1

Views

Author

Katie Khan, Oct 02 2024

Keywords

Examples

			For n=7, the 7th prime = 17 and those digits 1^2 + 7^2 = 50 = a(7).
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Norm[IntegerDigits[Prime[n]]]^2; Array[a,64] (* Stefano Spezia, Oct 03 2024 *)
  • PARI
    a(n) = norml2(digits(prime(n))); \\ Michel Marcus, Oct 03 2024
    
  • Python
    from sympy import prime
    def A376714(n): return sum((0, 1, 4, 9, 16, 25, 36, 49, 64, 81)[int(d)] for d in str(prime(n)) if d>'0') # Chai Wah Wu, Oct 04 2024

Formula

a(n) = A003132(A000040(n)).

A380192 Sum mod(10) of digits of n-th prime.

Original entry on oeis.org

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

Views

Author

Enrique Navarrete, Jan 15 2025

Keywords

Comments

All remainders 0,...,9 occur in this sequence.

Crossrefs

Programs

  • Mathematica
    Mod[DigitSum[Prime[Range[100]]], 10] (* Paolo Xausa, Feb 06 2025 *)
  • PARI
    a(n) = sumdigits(prime(n)) % 10; \\ Michel Marcus, Jan 16 2025

Formula

a(n) = A010879(A007605(n)).

A073342 Average digit (rounded to the nearest integer) in the decimal expansion of n-th prime.

Original entry on oeis.org

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

Views

Author

Y. Kelly Itakura (yitkr(AT)mta.ca), Aug 23 2002

Keywords

Examples

			For the prime 107 we have nearest((1+0+7)/3)=nearest(8/3)=3.
		

Crossrefs

Programs

  • Mathematica
    Floor[Mean[IntegerDigits[#]]+1/2]&/@Prime[Range[120]] (* Harvey P. Dale, Nov 22 2011 *)

Formula

a(n)=round(A007605(n)/A097944(n)). - R. J. Mathar, Sep 23 2008

Extensions

Changed offset to 1, added Cf. to A074462 and extended. - R. J. Mathar, Sep 23 2008

A081652 Greatest common divisor of n and sum of decimal digits of n-th prime.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 2, 1, 7, 1, 8, 1, 1, 1, 4, 1, 2, 1, 1, 1, 2, 1, 4, 1, 5, 1, 1, 11, 1, 7, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 11, 1, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 8, 1, 1, 1, 4, 1, 2, 1, 8, 1, 2, 1, 10, 1, 17, 1, 4
Offset: 1

Views

Author

Reinhard Zumkeller, Mar 25 2003

Keywords

Examples

			a(16) = GCD(16, A007953(A000040(16))) = GCD(16, A007953(53)) = GCD(16,5+3) = GCD(8*2,8) = 8.
		

Crossrefs

Programs

  • Mathematica
    Table[GCD[n,Total[IntegerDigits[Prime[n]]]],{n,110}] (* Harvey P. Dale, Jul 12 2012 *)

Formula

a(n) = GCD(n, A007605(n)).

A138828 Sum of digits of n-th even perfect number.

Original entry on oeis.org

6, 10, 19, 19, 28, 64, 55, 73, 190, 235, 289, 352, 1405, 1711, 3520, 5833, 5968, 8821, 11548, 11791, 26317, 27298, 30232, 53740, 58960, 62956, 120898, 233722, 299314, 356860, 585478, 2048248, 2329372, 3405232, 3789352, 8056495, 8186041, 18894079, 36485416, 56880973, 65115946, 70334902, 82384129
Offset: 1

Views

Author

Omar E. Pol, Apr 01 2008

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Block[{e, p, mpe = MersennePrimeExponent@n}, Plus @@ IntegerDigits[(2^mpe - 1) 2^(mpe - 1)]]; Array[a, 44] (* Robert G. Wilson v, Aug 06 2018 *)
    Total[IntegerDigits[#]]&/@Table[PerfectNumber[n],{n,43}] (* Requires Mathematica version 10 or later *) (* The program may take a long time to run *) (* Harvey P. Dale, Feb 07 2019 *)

Formula

a(n) = A007953(A000396(n)). - R. J. Mathar, May 22 2008 [This assumes that all perfect numbers are even. - Ivan Panchenko, Aug 16 2018]

Extensions

More terms from R. J. Mathar, May 22 2008
a(15)-a(38) from Donovan Johnson, Nov 09 2010
Definition changed (inserting the word "even") and a(39)-a(43) added by Ivan Panchenko, Aug 06 2018
Previous Showing 41-50 of 92 results. Next