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

A094117 Partial sums of A093349.

Original entry on oeis.org

0, 1, 1, 2, 2, 3, 3, 10, 16, 23, 29, 36, 42, 49, 49, 50, 50, 51, 51, 52, 52, 59, 65, 72, 78, 85, 91, 98, 98, 99, 99, 100, 100, 101, 101, 108, 114, 121, 127, 134, 140, 147, 147, 148, 148, 149, 149, 150, 150, 199, 247, 296, 344, 393, 441, 490, 532, 575, 617, 660, 702, 745
Offset: 1

Views

Author

Benoit Cloitre, May 03 2004

Keywords

Programs

  • PARI
    a(n)=sum(k=1,n,-sum(i=1,k-1,(-1)^i*7^valuation(i,7)))

Formula

a(7^k)=(49^k-1)/16

A093347 A 3-fractal "castle" starting with 0.

Original entry on oeis.org

0, 1, 0, 3, 2, 3, 0, 1, 0, 9, 8, 9, 6, 7, 6, 9, 8, 9, 0, 1, 0, 3, 2, 3, 0, 1, 0, 27, 26, 27, 24, 25, 24, 27, 26, 27, 18, 19, 18, 21, 20, 21, 18, 19, 18, 27, 26, 27, 24, 25, 24, 27, 26, 27, 0, 1, 0, 3, 2, 3, 0, 1, 0, 9, 8, 9, 6, 7, 6, 9, 8, 9, 0, 1, 0, 3, 2, 3, 0, 1, 0, 81, 80, 81, 78, 79, 78, 81
Offset: 1

Views

Author

Benoit Cloitre, Apr 26 2004

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Sum[(-1)^(i+1) * 3^IntegerExponent[i, 3], {i, 1, n-1}]; Array[a, 100] (* Amiram Eldar, Jun 17 2022 *)
  • PARI
    a(n)=if(n<2,0,3^floor(log(n-1)/log(3))-a(n-3^floor(log(n-1)/log(3))))
    
  • PARI
    a(n) = my(s=-1); fromdigits([if(d==1,s=-s) |d<-digits(n-1,3)], 3); \\ Kevin Ryde, Jan 01 2024

Formula

a(1) = 0 then a(n) = w(n) - a(n-w(n)) where w(n) = 3^floor(log(n-1)/log(3)).
a(3^n) = 0, a(3^n+1) = 3^n, a(3^n+2) = 3^n-1, a(3^n+3) = 3^n, etc.
a(n) = Sum_{i=1..n-1} (-1)^(i-1)*3^valuation(i, 3).

A093348 A 5-fractal "castle" starting with 0.

Original entry on oeis.org

0, 1, 0, 1, 0, 5, 4, 5, 4, 5, 0, 1, 0, 1, 0, 5, 4, 5, 4, 5, 0, 1, 0, 1, 0, 25, 24, 25, 24, 25, 20, 21, 20, 21, 20, 25, 24, 25, 24, 25, 20, 21, 20, 21, 20, 25, 24, 25, 24, 25, 0, 1, 0, 1, 0, 5, 4, 5, 4, 5, 0, 1, 0, 1, 0, 5, 4, 5, 4, 5, 0, 1, 0, 1, 0, 25, 24, 25, 24, 25, 20, 21, 20, 21, 20, 25, 24
Offset: 1

Views

Author

Benoit Cloitre, Apr 26 2004

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Sum[(-1)^(i+1) * 5^IntegerExponent[i, 5], {i, 1, n-1}]; Array[a, 100] (* Amiram Eldar, Jun 17 2022 *)
  • PARI
    a(n)=if(n<2,0,5^floor(log(n-1)/log(5))-a(n-5^floor(log(n-1)/log(5))))

Formula

a(1) = 0, then a(n) = w(n) - a(n-w(n)) where w(n) = 5^floor(log(n-1)/log(5)).
a(n) = Sum_{i=1..n-1} (-1)^(i-1)*5^valuation(i, 5).
Conjecture: a(n+1) = (n mod 2) + Sum_{k=0..infinity} (4*5^k*(floor(n/5^(k+1)) mod 2)). - Charlie Neder, May 25 2019
Showing 1-3 of 3 results.