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.

A084545 Alternate number system in base 5.

Original entry on oeis.org

1, 2, 3, 4, 5, 11, 12, 13, 14, 15, 21, 22, 23, 24, 25, 31, 32, 33, 34, 35, 41, 42, 43, 44, 45, 51, 52, 53, 54, 55, 111, 112, 113, 114, 115, 121, 122, 123, 124, 125, 131, 132, 133, 134, 135, 141, 142, 143, 144, 145, 151, 152, 153, 154, 155, 211, 212, 213, 214, 215, 221, 222
Offset: 1

Views

Author

Robert R. Forslund (forslund(AT)tbaytel.net), Jun 27 2003

Keywords

Examples

			From _Hieronymus Fischer_, Jun 06 2012: (Start)
a(100)  = 345.
a(10^3) = 12445.
a(10^4) = 254445.
a(10^5) = 11144445.
a(10^6) = 223444445.
a(10^7) = 4524444445.
a(10^8) = 145544444445.
a(10^9) = 3521444444445. (End)
		

Crossrefs

Programs

  • PARI
    a(n) = my (w=5); while (n>w, n -= w; w *= 5); my (d=digits(w+n-1, 5)); d[1] = 0; fromdigits(d) + (10^(#d-1)-1)/9 \\ Rémy Sigrist, Dec 04 2019

Formula

From Hieronymus Fischer, Jun 06 and Jun 08 2012: (Start)
The formulas are designed to calculate base-10 numbers only using the digits 1..5.
a(n) = Sum_{j=0..m-1} (1 + b(j) mod 5)*10^j, where m = floor(log_5(4*n+1)), b(j) = floor((4*n+1-5^m)/(4*5^j)).
a(k*(5^n-1)/4) = k*(10^n-1)/9, for k = 1,2,3,4,5.
a((9*5^n-5)/4) = (14*10^n-5)/9 = 10^n + 5*(10^n-1)/9.
a((5^n-1)/4 - 1) = 5*(10^(n-1)-1)/9, n>1.
a(n) <= (10^log_5(4*n+1)-1)/9, equality holds for n=(5^k-1)/4, k>0.
a(n) > (5/10)*(10^log_5(4*n+1)-1)/9, n>0.
lim inf a(n)/10^log_5(4*n) = 1/18, for n --> infinity.
lim sup a(n)/10^log_5(4*n) = 1/9, for n --> infinity.
G.f.: g(x) = (x^(1/4)*(1-x))^(-1) sum_{j>=0} 10^j*z(j)^(5/4)*(1 - 6z(j)^5 + 5z(j)^6)/((1-z(j))(1-z(j)^5)), where z(j) = x^5^j.
Also: g(x) = (1/(1-x)) sum_{j>=0} (1-6(x^5^j)^5+5(x^5^j)^6)*x^5^j*f_j(x)/(1-x^5^j), where f_j(x) = 10^j*x^((5^j-1)/4)/(1-(x^5^j)^5). The f_j obey the recurrence f_0(x) = 1/(1-x^5), f_(j+1)(x) = 10x*f_j(x^5).
Also: g(x) = 1/(1-x))*(h_(5,0)(x) + h_(5,1)(x) + h_(5,2)(x) + h_(4,1)(x) + h_(5,4)(x) - 5*h_(5,5)(x)), where h_(5,k)(x) = sum_{j>=0} 10^j*x^((5^(j+1)-1)/4) * (x^5^j)^k/(1-(x^5^j)^5).
(End)

Extensions

Offset set to 1 according to A007931, A007932 and more terms added by Hieronymus Fischer, Jun 06 2012