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

A026209 Duplicate of A026185.

Original entry on oeis.org

1, 4, 2, 8, 3, 12, 5, 16, 6, 20, 7, 24, 9, 28, 10, 32, 11, 36, 13, 40, 14, 44, 15, 48, 17, 52, 18, 56, 19, 60, 21, 64, 22, 68, 23, 72, 25, 76, 26, 80, 27, 84, 29, 88, 30, 92, 31, 96, 33, 100, 34, 104, 35, 108, 37, 112, 38, 116, 39, 120, 41
Offset: 1

Views

Author

Keywords

A198473 Duplicate of A026185.

Original entry on oeis.org

0, 1, 4, 2, 8, 3, 12, 5, 16, 6, 20, 7, 24, 9, 28, 10, 32, 11, 36, 13, 40, 14, 44, 15, 48, 17, 52, 18, 56, 19, 60, 21, 64, 22, 68, 23, 72, 25, 76, 26, 80, 27, 84, 29, 88, 30, 92, 31, 96, 33, 100, 34, 104, 35, 108, 37, 112, 38, 116, 39, 120, 41, 124, 42, 128
Offset: 0

Views

Author

Ray Chandler, May 01 2023

Keywords

A026184 a(n) = (1/3)*s(n), where s(n) is the n-th multiple of 3 in A026136.

Original entry on oeis.org

1, 3, 5, 2, 7, 9, 11, 4, 13, 15, 17, 6, 19, 21, 23, 8, 25, 27, 29, 10, 31, 33, 35, 12, 37, 39, 41, 14, 43, 45, 47, 16, 49, 51, 53, 18, 55, 57, 59, 20, 61, 63, 65, 22, 67, 69, 71, 24, 73, 75, 77, 26, 79, 81, 83, 28, 85, 87, 89, 30, 91, 93, 95
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Block[{a, r, s, nn = 141}, a[1] = 1; Do[If[! IntegerQ[a[#1]], Set[a[#1], i], Set[a[#2], i]] & @@ {i - #, i + #} &@ Floor[i/2], {i, 2 nn}]; Select[TakeWhile[Array[a[#] &, nn], IntegerQ], Mod[#, 3] == 0 &]/3] (* Michael De Vlieger, Aug 27 2021 *)
    LinearRecurrence[{0,0,0,2,0,0,0,-1},{1,3,5,2,7,9,11,4},70] (* Harvey P. Dale, Sep 25 2024 *)

Formula

a(4*n) = 2*n, a(4*n+1) = 6*n+1, a(4*n+2) = 6*n+3, a(4*n+3) = 6*n+5 . - Philippe Deléham, Nov 02 2023

Extensions

Edited by N. J. A. Sloane, Jan 31 2020

A317613 Permutation of the nonnegative integers: lodumo_4 of A047247.

Original entry on oeis.org

2, 3, 0, 1, 4, 5, 6, 7, 10, 11, 8, 9, 12, 13, 14, 15, 18, 19, 16, 17, 20, 21, 22, 23, 26, 27, 24, 25, 28, 29, 30, 31, 34, 35, 32, 33, 36, 37, 38, 39, 42, 43, 40, 41, 44, 45, 46, 47, 50, 51, 48, 49, 52, 53, 54, 55, 58, 59, 56, 57, 60, 61, 62, 63, 66, 67, 64
Offset: 0

Views

Author

Keywords

Comments

Write n in base 8, then apply the following substitution to the rightmost digit: '0'->'2, '1'->'3', and vice versa. Convert back to decimal.
A self-inverse permutation: a(a(n)) = n.
Array whose columns are, in this order, A047463, A047621, A047451 and A047522, read by rows.

Examples

			a(25) = a('3'1') = '3'3' = 27.
a(26) = a('3'2') = '3'0' = 24.
a(27) = a('3'3') = '3'1' = 25.
a(28) = a('3'4') = '3'4' = 28.
a(29) = a('3'5') = '3'5' = 29.
The sequence as array read by rows:
  A047463, A047621, A047451, A047522;
        2,       3,       0,       1;
        4,       5,       6,       7;
       10,      11,       8,       9;
       12,      13,      14,      15;
       18,      19,      16,      17;
       20,      21,      22,      23;
       26,      27,      24,      25;
       28,      29,      30,      31;
  ...
		

Crossrefs

Programs

  • Magma
    m:=100; R:=PowerSeriesRing(Integers(), m); Coefficients(R!((x^7+x^5+3*x^3-2*x^2-x+2)/((1-x)^2*(x^6+x^4+ x^2+1)))); // G. C. Greubel, Sep 25 2018
  • Mathematica
    Table[(4*(Floor[1/4 Mod[2*n + 4, 8]] - Floor[1/4 Mod[n + 2, 8]]) + 2*n)/2, {n, 0, 100}]
    f[n_] := Block[{id = IntegerDigits[n, 8]}, FromDigits[ Join[Most@ id /. {{} -> {0}}, {id[[-1]] /. {0 -> 2, 1 -> 3, 2 -> 0, 3 -> 1}}], 8]]; Array[f, 67, 0] (* or *)
    CoefficientList[ Series[(x^7 + x^5 + 3x^3 - 2x^2 - x + 2)/((x - 1)^2 (x^6 + x^4 + x^2 + 1)), {x, 0, 70}], x] (* or *)
    LinearRecurrence[{2, -2, 2, -2, 2, -2, 2, -1}, {2, 3, 0, 1, 4, 5, 6, 7}, 70] (* Robert G. Wilson v, Aug 01 2018 *)
  • Maxima
    makelist((4*(floor(mod(2*n + 4, 8)/4) - floor(mod(n + 2, 8)/4)) + 2*n)/2, n, 0, 100);
    
  • PARI
    my(x='x+O('x^100)); Vec((x^7+x^5+3*x^3-2*x^2-x+2)/((1-x)^2*(x^6+x^4+ x^2+1))) \\ G. C. Greubel, Sep 25 2018
    

Formula

a(n) = 2*a(n-1) - 2*a(n-2) + 2*a(n-3) - 2*a(n-4) + 2*a(n-5) - 2*a(n-6) + 2*a(n-7) - a(n-8), n > 7.
a(n) = (4*(floor(((2*n + 4) mod 8)/4) - floor(((n + 2) mod 8)/4)) + 2*n)/2.
a(n) = lod_4(A047247(n+1)).
a(4*n) = A047463(n+1).
a(4*n+1) = A047621(n+1).
a(4*n+2) = A047451(n+1).
a(4*n+3) = A047522(n+1).
a(A042948(n)) = A047596(n+1).
a(A042964(n+1)) = A047551(n+1).
G.f.: (x^7 + x^5 + 3*x^3 - 2*x^2 - x + 2)/((x-1)^2 * (x^2+1) * (x^4+1)).
E.g.f.: x*exp(x) + cos(x) + sin(x) + cos(x/sqrt(2))*cosh(x/sqrt(2)) + (sqrt(2)*cos(x/sqrt(2)) - sin(x/sqrt(2)))*sinh(x/sqrt(2)).
a(n+8) = a(n) + 8 . - Philippe Deléham, Mar 09 2023
Sum_{n>=3} (-1)^(n+1)/a(n) = 1/6 + log(2). - Amiram Eldar, Mar 12 2023
Showing 1-4 of 4 results.