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-9 of 9 results.

A132153 Largest prime <= square root of 10^n.

Original entry on oeis.org

3, 7, 31, 97, 313, 997, 3137, 9973, 31607, 99991, 316223, 999983, 3162277, 9999991, 31622743, 99999989, 316227731, 999999937, 3162277633, 9999999967, 31622776589, 99999999977, 316227766003, 999999999989, 3162277660153, 9999999999971, 31622776601657
Offset: 1

Views

Author

Anthony C Robin, Nov 01 2007

Keywords

Comments

To check if an (n+1)-digit number is prime, a(n) is the largest prime which one needs to check is not a factor of the (n+1)-th digit number. For example, to check that a general four-digit number is not prime, we need to test its divisibility by all the primes up to and including 97.

Crossrefs

Programs

  • Mathematica
    Table[NextPrime[Sqrt[10^n],-1],{n,27}] (* James C. McMahon, Mar 04 2025 *)
  • PARI
    a(n)=precprime(sqrtint(10^n)) \\ Charles R Greathouse IV, Aug 18 2011
    
  • Python
    from sympy import prevprime, integer_nthroot
    def a(n): return prevprime(integer_nthroot(10**n, 2)[0]+1)
    print([a(n) for n in range(1, 28)]) # Michael S. Branicky, Dec 23 2021

Formula

a(n) = A000040(A122121(n)). a(2n) = A003618(n). - R. J. Mathar, Nov 06 2007 [Corrected by Jaroslav Krizek, Jul 12 2010]
a(n) = sqrt(A175734(n)). - Jaroslav Krizek, Aug 24 2010

Extensions

More terms from N. J. A. Sloane, Jan 05 2008

A062940 Number of squares (including 0) with n digits.

Original entry on oeis.org

4, 6, 22, 68, 217, 683, 2163, 6837, 21623, 68377, 216228, 683772, 2162278, 6837722, 21622777, 68377223, 216227767, 683772233, 2162277661, 6837722339, 21622776602, 68377223398, 216227766017, 683772233983, 2162277660169
Offset: 1

Views

Author

Amarnath Murthy, Jul 07 2001

Keywords

Comments

Sum of first 2n terms = 10^n. - Zak Seidov, Aug 05 2006
a(n)/a(n-1) ~ 10^(1/2). For the sequence giving the number of members of the sequence a(k)=k^r with n digits we have a(n)/a(n-1) ~ 10^(1/r). - Ctibor O. Zizka, Mar 09 2008

Examples

			a(1)=4 because there are 4 one-digit squares: 0,1,4,9. - _Zak Seidov_, Aug 05 2006
a(2)=6 because there are 6 two-digit squares: 16,25,36,49,64,81. - _Zak Seidov_, Aug 05 2006
22 squares (100=10^2, 121=11^2, ..., 961=31^2) have 3 digits, hence a(3)=22.
		

Crossrefs

A variant of A049415. A049415(n) = A017936(n+1) - A017936(n) = A049416(n+1) - A049416(n). Cf. A000290, A062941.
Column k=2 of A216653.

Programs

  • Maple
    r:= proc(n, k) local b; b:= iroot(n, k); b+`if`(b^k r(10^n, 2) -r(10^(n-1), 2) +`if`(n=1, 1, 0):
    seq(a(n), n=1..40);  # Alois P. Heinz, Sep 12 2012
  • PARI
    je=[4]; for(n=2, 45, je=concat(je, ceil(sqrt(10^n))-ceil(sqrt(10^(n-1))))); je
    
  • PARI
    { default(realprecision, 200); for (n=1, 200, b=ceil(10^(n/2)); if (n>1, a=b - c, a=4); c=b; write("b062940.txt", n, " ", a) ) } \\ Harry J. Smith, Aug 14 2009

Formula

a(n) = ceiling(sqrt(10^n)) - ceiling(sqrt(10^(n-1))), n > 1.
a(n) = A017934(n) - A017934(n-1) - (-1)^n, n >= 2. - R. J. Mathar, Mar 17 2008

Extensions

Corrected and extended by Dean Hickerson and Jason Earls, Jul 10 2001
Edited by R. J. Mathar, Aug 07 2008

A136582 Sqrt(10)-primes: primes obtained by concatenating the first digits in the decimal expansion of sqrt(10).

Original entry on oeis.org

3, 31, 3162277, 316227766016837933, 316227766016837933199889354443271
Offset: 1

Views

Author

Lekraj Beedassy, Jan 09 2008

Keywords

Comments

n such that floor(sqrt(10^(2*n-1))) is prime (1, 2, 7, 18, 33, ...) are given in A136583.
This sequence is the list of prime terms in A017934.
The next term has 206 digits. - Harvey P. Dale, Dec 06 2023

Crossrefs

Programs

  • Magma
    // by Jason Kimberley, Aug 2011
    for n in [1..499 by 2] do
      f := Isqrt(10^n);
      if IsPrime(f) then
        printf "%o,", f;
      end if;
    end for;
  • Mathematica
    Module[{nn=50,sq10},sq10=RealDigits[Sqrt[10],10,nn][[1]];Select[FromDigits/@Table[Take[sq10,n],{n,nn}],PrimeQ]] (* Harvey P. Dale, Dec 06 2023 *)

Formula

a(n) = A017934(2*A136583(n)-1).

A018072 Powers of fourth root of 10 rounded down.

Original entry on oeis.org

1, 1, 3, 5, 10, 17, 31, 56, 100, 177, 316, 562, 1000, 1778, 3162, 5623, 10000, 17782, 31622, 56234, 100000, 177827, 316227, 562341, 1000000, 1778279, 3162277, 5623413, 10000000, 17782794, 31622776, 56234132, 100000000, 177827941, 316227766, 562341325, 1000000000, 1778279410
Offset: 0

Views

Author

Keywords

Examples

			a(2) = 3 because 10^(2/4) = 10^(1/2) = sqrt(10) = 3.16228...
a(3) = 5 because 10^(3/4) = 5.62341...
a(4) = 10 because 10^(4/4) = 10^1 = 10.
a(5) = 17 because 10^(5/4) = 17.78279...
		

Crossrefs

Programs

Extensions

A few additional terms from Alonso del Arte, Jan 26 2013

A091100 Number of Gaussian primes whose norm is less than 10^n.

Original entry on oeis.org

16, 100, 668, 4928, 38404, 313752, 2658344, 23046512, 203394764, 1820205436, 16472216912, 150431552012, 1384262129028, 12819767598972, 119378281788240, 1116953361826164
Offset: 1

Views

Author

T. D. Noe, Dec 19 2003

Keywords

Crossrefs

Cf. A091098 (number of primes of the form 4k+1 less than 10^n), A091099 (number of primes of the form 4k+3 less than 10^n), A091101, A091102.
Cf. A091134 (number of Gaussian primes whose modulus is less than 10^n).

Programs

  • Mathematica
    Table[lim2=10^n; lim1=Floor[Sqrt[lim2]]; cnt=0; Do[If[x^2+y^2True], cnt++ ], {x, -lim1, lim1}, {y, -lim1, lim1}]; cnt, {n, 6}]

Formula

a(2n) = 8*A091098(2n) + 4*A091099(n) + 4.
a(n) ~ 4 Li(10^n) ~ k/n * 10^n, where k = 4/log(10) = 1.737.... - Charles R Greathouse IV, Oct 24 2012

Extensions

a(10)-a(16) from Seiichi Manyama using the data in A091098, Dec 03 2017

A136583 n such that floor(sqrt(10^(2*n-1))) is (probably) prime.

Original entry on oeis.org

1, 2, 7, 18, 33, 206, 468, 1061, 6831, 40377
Offset: 1

Views

Author

Lekraj Beedassy, Jan 09 2008

Keywords

Comments

Number of digits of sqrt(10)-primes (A136582).
The n such that A017934(2*n-1) is (probably) prime.

Crossrefs

Programs

  • Magma
    for n in [1..10^6] do if IsPrime(Isqrt(10^(2*n-1))) then printf "%o, ", n; end if; end for; // Jason Kimberley, Sep 03 2011
  • Mathematica
    rd = RealDigits[Sqrt[10], 10, 10^5][[1]]; Do[ If[ PrimeQ@ FromDigits@ Take[rd, n], Print@n], {n, 10^5}] (* Robert G. Wilson v, Jan 20 2008 *)

Extensions

a(6) - a(8) from Robert G. Wilson v, Jan 20 2008
Probable terms a(9) and a(10) from Jason Kimberley, Aug 19 and Sep 03 2011

A255616 Table read by antidiagonals, T(n,k) = floor(sqrt(k^n)), n >= 0, k >=1.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 2, 3, 2, 1, 1, 2, 4, 5, 4, 1, 1, 2, 5, 8, 9, 5, 1, 1, 2, 6, 11, 16, 15, 8, 1, 1, 2, 7, 14, 25, 32, 27, 11, 1, 1, 3, 8, 18, 36, 55, 64, 46, 16, 1, 1, 3, 9, 22, 49, 88, 125, 128, 81, 22, 1, 1, 3, 10, 27, 64, 129, 216, 279, 256, 140, 32, 1, 1, 3, 11, 31, 81, 181, 343, 529, 625, 512, 243, 45, 1
Offset: 0

Views

Author

Kival Ngaokrajang, Feb 28 2015

Keywords

Examples

			See table in the links.
		

Crossrefs

Programs

  • Mathematica
    T[n_, k_] := Floor[Sqrt[k^n]]; Table[T[k, n + 1 - k], {n, 0, 15}, {k, 0, n}] (* G. C. Greubel, Dec 30 2017 *)
  • PARI
    {for(i=1,20,for(n=0,i-1,a=floor(sqrt((i-n)^n));print1(a,", ")))}

Formula

T(n,k) = floor(sqrt(k^n)), n >= 0, k >=1.

Extensions

Terms a(81) onward added by G. C. Greubel, Dec 30 2017

A361612 Decimal expansion of sqrt(10) truncated to n places (after the decimal point).

Original entry on oeis.org

3, 31, 316, 3162, 31622, 316227, 3162277, 31622776, 316227766, 3162277660, 31622776601, 316227766016, 3162277660168, 31622776601683, 316227766016837, 3162277660168379, 31622776601683793, 316227766016837933, 3162277660168379331, 31622776601683793319
Offset: 0

Views

Author

Amit Katz, Mar 17 2023

Keywords

Crossrefs

Programs

  • Mathematica
    Floor[Sqrt[10]*10^Range[0, 20]] (* Paolo Xausa, Jul 25 2024 *)
  • Python
    from math import isqrt
    def A361612(n): return isqrt(10**((n<<1)|1)) # Chai Wah Wu, Mar 26 2023

Formula

a(n) = floor(sqrt(10) * 10^n).
a(n) = A017934(2*n + 1).
a(n-1) mod 10 = A010467(n). - Chai Wah Wu, Mar 26 2023

A069658 a(1) = 1; a(n) = smallest nontrivial n-digit perfect power.

Original entry on oeis.org

1, 16, 121, 1024, 10201, 100489, 1002001, 10004569, 100020001, 1000014129, 10000200001, 100000147984, 1000002000001, 10000002149284, 100000020000001, 1000000025191729, 10000000200000001, 100000000621806289, 1000000002000000001
Offset: 1

Views

Author

Amarnath Murthy, Apr 04 2002

Keywords

Comments

Powers of 10 are not allowed.

Crossrefs

Programs

  • Mathematica
    Join[{1},(Floor[Sqrt[10^Range[20]]]+1)^2] (* Harvey P. Dale, Mar 08 2022 *)

Formula

a(n) = (floor(sqrt(10)^(n-1))+1)^2 = (A017934(n-1)+1)^2. - Vladeta Jovovic, Jun 30 2002

Extensions

More terms from Sascha Kurz, Jan 28 2003
Showing 1-9 of 9 results.