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

A339255 Leading digit of n in base 5.

Original entry on oeis.org

1, 2, 3, 4, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 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, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3
Offset: 1

Views

Author

Kevin Ryde, Nov 28 2020

Keywords

Crossrefs

Cf. A007091 (base 5), A073851 (partial sums).

Programs

  • Mathematica
    IntegerDigits[#,5][[1]]&/@Range[100] (* Harvey P. Dale, Sep 04 2021 *)
  • PARI
    a(n) = n\5^logint(n,5);

Formula

a(n) = floor(n / 5^floor(log_5(n))).
G.f.: (x + Sum_{k>=0} Sum_{d=2..4} (x^(d*5^k)-x^(5^(k+1))) )/(1-x).

A109804 Cumulative sum of initial digits of (n base 6).

Original entry on oeis.org

0, 1, 3, 6, 10, 15, 16, 17, 18, 19, 20, 21, 23, 25, 27, 29, 31, 33, 36, 39, 42, 45, 48, 51, 55, 59, 63, 67, 71, 75, 80, 85, 90, 95, 100, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131
Offset: 0

Views

Author

Jonathan Vos Post, Aug 30 2005

Keywords

Examples

			  n  Base 6  Initial  Cumulative Sum
  0     0       0           0
  1     1       1           1
  2     2       2           3
  3     3       3           6
  4     4       4          10
  5     5       5          15
		

References

  • A. Cobham, Uniform Tag Sequences, Mathematical Systems Theory, 6 (1972), 164-192.

Crossrefs

Cf. A000030, A007092, A109453, A339256 (first differences).

Programs

  • Mathematica
    Accumulate[Table[First[IntegerDigits[n,6]],{n,0,70}]] (* Harvey P. Dale, Oct 07 2012 *)

Formula

n (base 6) = A007092(n) A007092(0)=0, A007092(n)=10* A007092(n/6) if n==0 (mod 6), A007092(n)= A007092(n-1)+1 otherwise. - Benoit Cloitre, Dec 22 2002
a(n) below is Sum_{i=0..n} first-digit{(i base 6)}.
a(n) = Sum_{i=1..n} floor(n / 6^floor(log_6(n))) where log_6(n) is the logarithm to base 6.
a(n+1) = a(n) + first-digit-of((n+1) (base 6)).
Showing 1-2 of 2 results.