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

A216653 Number A(n,k) of n-digit k-th powers; square array A(n,k), n>=1, k>=1, read by antidiagonals.

Original entry on oeis.org

10, 4, 90, 3, 6, 900, 2, 2, 22, 9000, 2, 2, 5, 68, 90000, 2, 1, 2, 12, 217, 900000, 2, 1, 1, 4, 25, 683, 9000000, 2, 0, 1, 3, 8, 53, 2163, 90000000, 2, 0, 1, 1, 3, 14, 116, 6837, 900000000, 2, 0, 1, 1, 2, 6, 25, 249, 21623, 9000000000
Offset: 1

Views

Author

Alois P. Heinz, Sep 12 2012

Keywords

Examples

			A(1,1) = 10: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9.
A(1,2) = 4: 0, 1, 4, 9.
A(2,2) = 6: 16, 25, 36, 49, 64, 81.
A(3,3) = 5: 125, 216, 343, 512, 729.
A(4,4) = 4: 1296, 2401, 4096, 6561.
A(5,5) = 3: 16807, 32768, 59049.
A(6,6) = 3: 117649, 262144, 531441.
Square array A(n,k) begins:
:n\k|        1:     2:    3:   4:   5:  6:  7:  8
+---+--------------------------------------------
: 1 |       10,     4,    3,   2,   2,  2,  2,  2
: 2 |       90,     6,    2,   2,   1,  1,  0,  0
: 3 |      900,    22,    5,   2,   1,  1,  1,  1
: 4 |     9000,    68,   12,   4,   3,  1,  1,  1
: 5 |    90000,   217,   25,   8,   3,  2,  2,  1
: 6 |   900000,   683,   53,  14,   6,  3,  2,  1
: 7 |  9000000,  2163,  116,  25,  10,  5,  2,  2
: 8 | 90000000,  6837,  249,  43,  14,  7,  4,  2
		

Crossrefs

Main diagonal gives: A102690.

Programs

  • Maple
    r:= proc(n, k) local b; b:= iroot(n, k); b+`if`(b^k r(10^n, k) -r(10^(n-1), k) +`if`(n=1, 1, 0):
    seq(seq(A(n, 1+d-n), n=1..d), d=1..10);

A049415 Number of squares (of positive integers) with n digits.

Original entry on oeis.org

3, 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

Ulrich Schimke (ulrschimke(AT)aol.com)

Keywords

Comments

a(n) + A180426(n) + A180429(n) + A180347(n) = A052268(n).
Lim_{n->infinity} a(2n)/10^n = 1 - 1/sqrt(10);
lim_{n->infinity} a(2n-1)/10^n = 1/sqrt(10) - 1/10. - Robert G. Wilson v, Aug 29 2012

Examples

			22 squares (100=10^2, 121=11^2, ...., 961=31^2) have 3 digits, hence a(3)=22.
		

Crossrefs

A049415(n) = A017936(n+1) - A017936(n) = A049416(n+1) - A049416(n).
Cf. A062940.

Programs

  • Magma
    [Ceiling(Sqrt(10^n))-Ceiling(Sqrt(10^(n-1))) : n in [1..30]]; // Vincenzo Librandi, Oct 01 2011
  • Mathematica
    f[n_] := Ceiling[Sqrt[10^n - 1]] - Ceiling[Sqrt[10^(n - 1)]]; f[1] = 3; Array[f, 24] (* Robert G. Wilson v, Aug 29 2012 *)

Formula

a(n) = ceiling(sqrt(10^n)) - ceiling(sqrt(10^(n-1))).
From Jon E. Schoenfield, Nov 30 2019: (Start)
a(2n) = floor(10^n * (1 - 1/sqrt(10))), so each even-indexed term a(2n) is given by the first n digits (after the decimal point) of 1 - 1/sqrt(10) = 0.68377223398316...;
a(2n-1) = ceiling(10^n * (1/sqrt(10) - 1/10)), so each odd-indexed term a(2n-1) is given by the first n digits (after the decimal point) of 1/sqrt(10) - 1/10 = 0.21622776601683..., plus 1. (End)

Extensions

More terms from Dean Hickerson, Jul 10 2001

A062941 Number of n-digit cubes (0 is included as a single-digit number).

Original entry on oeis.org

3, 2, 5, 12, 25, 53, 116, 249, 535, 1155, 2487, 5358, 11545, 24871, 53584, 115444, 248715, 535841, 1154435, 2487154, 5358411, 11544347, 24871542, 53584111, 115443470, 248715414, 535841116, 1154434691, 2487154143, 5358411166
Offset: 1

Views

Author

Amarnath Murthy, Jul 07 2001

Keywords

Comments

Sum of first 3n terms = 10^n.

Examples

			a(3) = 5 as there are 5 three-digit cubes: 125, 216, 343, 512 and 729.
		

Crossrefs

Cf. A062940.
Column k=3 of A216653.

Programs

  • Maple
    r:= proc(n, k) local b; b:= iroot(n, k); b+`if`(b^k r(10^n, 3) -r(10^(n-1), 3) +`if`(n=1, 1, 0):
    seq(a(n), n=1..40);  # Alois P. Heinz, Sep 12 2012
  • PARI
    { default(realprecision, 300); p=1; b=-1; for (n=1, 300, p*=10; c=b; b=floor((p - 1)^(1/3)); write("b062941.txt", n, " ", b - c) ) } \\ Harry J. Smith, Aug 14 2009

Extensions

Corrected and extended by Dean Hickerson, Jul 10 2001
Offset changed from 0 to 1 by Harry J. Smith, Aug 14 2009

A126726 Number of squares (of nonnegative integers) that require n binary (base-2) digits.

Original entry on oeis.org

0, 2, 0, 1, 1, 2, 2, 4, 4, 7, 9, 14, 18, 27, 37, 54, 74, 107, 149, 213, 299, 425, 599, 849, 1199, 1697, 2399, 3394, 4798, 6787, 9597, 13573, 19195, 27146, 38390, 54292, 76780, 108584, 153560, 217168, 307120, 434335, 614241, 868669, 1228483, 1737338, 2456966
Offset: 0

Views

Author

Andrew G. West (westa(AT)wlu.edu), Mar 13 2007

Keywords

Comments

Binary equivalent to A062940, which uses decimal representation.

Examples

			21^2 = 441 = 110111001_2, requiring 9 digits.
		

Crossrefs

Cf. A062940.

Programs

  • Maple
    r:= proc(n) local b; b:= isqrt(n); b+`if`(b^2 `if`(n=0, 0, r(2^n) -r(2^(n-1)) +`if`(n=1, 1, 0)):
    seq(a(n), n=0..50);  # Alois P. Heinz, Sep 13 2012

Formula

Conjecture: a(n) = A190568(n)-(-1)^n for n>0. - R. J. Mathar, May 21 2025

A173906 Total number of digits of the squares of all n-digit numbers.

Original entry on oeis.org

16, 338, 5183, 69837, 878377, 10583772, 123837722, 1418377223, 15983772233, 177837722339, 1958377223398, 21383772233983, 231837722339831, 2498377223398316, 26783772233983162, 285837722339831620, 3038377223398316206, 32183772233983162066, 339837722339831620668, 3578377223398316206680
Offset: 1

Views

Author

Robert G. Wilson v, Nov 26 2010

Keywords

Comments

Sequence inspired by Claudio Meller's email to [seqfan] 07:01 a.m., Nov 26 2010, subject: About a problem of Bernardo Recamán Santos found in http://www.mathpuzzle.com/

Crossrefs

Programs

  • Mathematica
    f[n_] := Block[{br = 1+ Floor[10^(n-1)*Sqrt@10]},(2n-1)(br-10^(n-1)) + 2n(10^n-br)]; Array[f, 20]

Formula

Limit_{n->oo} a(n)/(n*10^n) = 9/5. [corrected by Jason Yuen, Feb 07 2025]
From Jason Yuen, Feb 07 2025: (Start)
a(n) = (2*n-1)*A062940(2*n-1) + (2*n)*A062940(2*n).
a(n) = (9/5)*n*10^n - ceiling((sqrt(10)-1)*10^(n-1)) for n > 1. (End)
Showing 1-5 of 5 results.