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.

User: Chinmaya Dash

Chinmaya Dash's wiki page.

Chinmaya Dash has authored 1 sequences.

A338852 a(n) = (7*floor(a(n-1)/3)) + (a(n-1) mod 3) with a(1) = 3.

Original entry on oeis.org

3, 7, 15, 35, 79, 183, 427, 995, 2319, 5411, 12623, 29451, 68719, 160343, 374131, 872971, 2036931, 4752839, 11089955, 25876559, 60378635, 140883479, 328728115, 767032267, 1789741955, 4176064559, 9744150635, 22736351479, 53051486783
Offset: 1

Author

Chinmaya Dash, Nov 12 2020

Keywords

Comments

Maximum reduction height sequence for a (7,3) counter.

Examples

			a(6) = 7*floor(79/3) + mod(79/3) = 183.
		

Crossrefs

Cf. A061418.

Programs

  • C
    int a(int n) {
            int t1 = 3, nextTerm;
            for (int i = 2; i <= n; ++i) {
                nextTerm = 7*(t1/3) + t1%3;
                t1 = nextTerm;
            }
            return t1;
        }
    
  • Mathematica
    NestList[7 Floor[#/3] + Mod[#, 3] &, 3, 28] (* Michael De Vlieger, Nov 12 2020 *)
  • PARI
    a(n) = if (n==1, 3, my(x=divrem(a(n-1), 3)); 7*x[1] + x[2]); \\ Michel Marcus, Nov 12 2020