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.

A111710 Consider the triangle shown below in which the n-th row contains the n smallest numbers greater than those in the previous row such that the arithmetic mean is an integer. Sequence contains the leading diagonal.

Original entry on oeis.org

1, 4, 7, 13, 18, 27, 34, 46, 55, 70, 81, 99, 112, 133, 148, 172, 189, 216, 235, 265, 286, 319, 342, 378, 403, 442, 469, 511, 540, 585, 616, 664, 697, 748, 783, 837, 874, 931, 970, 1030, 1071, 1134, 1177, 1243, 1288, 1357, 1404, 1476, 1525, 1600, 1651, 1729
Offset: 1

Views

Author

Amarnath Murthy, Aug 24 2005

Keywords

Examples

			The fourth row is 8,9,10 and 13,(8+9+10 +13)/4 = 10.
Triangle begins:
1
2 4
5 6 7
8 9 10 13
14 15 16 17 18
19 20 21 22 23 27
28 29 30 31 32 33 34
		

Crossrefs

Cf. A085787. - R. J. Mathar, Aug 15 2008

Programs

  • Mathematica
    LinearRecurrence[{1, 2, -2, -1, 1}, {1, 4, 7, 13, 18}, 100] (* Paolo Xausa, Feb 09 2024 *)
  • PARI
    Vec(x*(1+3*x+x^2)/((1-x)^3*(1+x)^2) + O(x^100)) \\ Colin Barker, Jan 26 2016

Formula

a(1)=1, a(2n) = a(2n-1)+3n, a(2n+1)=a(2n)+2n+1. - Franklin T. Adams-Watters, May 01 2006
G.f.: -x*(1+3*x+x^2) / ( (1+x)^2*(x-1)^3 ). a(n+1)-a(n) = A080512(n+1). - R. J. Mathar, May 02 2013
From Colin Barker, Jan 26 2016: (Start)
a(n) = (10*n^2+2*(-1)^n*n+10*n+(-1)^n-1)/16.
a(n) = (5*n^2+6*n)/8 for n even.
a(n) = (5*n^2+4*n-1)/8 for n odd. (End)

Extensions

More terms from Franklin T. Adams-Watters, May 01 2006

A111712 Arithmetic mean of the n-th row of triangle mentioned in A111710.

Original entry on oeis.org

1, 3, 6, 10, 16, 22, 31, 39, 51, 61, 76, 88, 106, 120, 141, 157, 181, 199, 226, 246, 276, 298, 331, 355, 391, 417, 456, 484, 526, 556, 601, 633, 681, 715, 766, 802, 856, 894, 951, 991, 1051, 1093, 1156, 1200, 1266, 1312, 1381, 1429, 1501, 1551, 1626, 1678
Offset: 1

Views

Author

Amarnath Murthy, Aug 24 2005

Keywords

Examples

			a(4) = (8+9+10+13)/4 =10
		

Crossrefs

Partial sums of A195013 prepended with 1.

Programs

  • Haskell
    a111712 n = a111712_list !! (n-1)
    a111712_list = scanl (+) 1 a195013_list
    -- Reinhard Zumkeller, Apr 06 2015
  • Mathematica
    With[{r = Range[50]}, Accumulate[Join[{1}, Riffle[2*r, 3*r]]]] (* or *)
    LinearRecurrence[{1, 2, -2, -1, 1}, {1, 3, 6, 10, 16}, 100] (* Paolo Xausa, Feb 09 2024 *)

Formula

a(1)=1, a(2n) = a(2n-1)+2n, a(2n+1)=a(2n)+3n. a(n) = A111711(n)+floor(n/2). - Franklin T. Adams-Watters, May 01 2006

Extensions

More terms from Franklin T. Adams-Watters, May 01 2006

A257143 a(2*n) = 3*n if n>0, a(2*n + 1) = 2*n + 1, a(0) = 1.

Original entry on oeis.org

1, 1, 3, 3, 6, 5, 9, 7, 12, 9, 15, 11, 18, 13, 21, 15, 24, 17, 27, 19, 30, 21, 33, 23, 36, 25, 39, 27, 42, 29, 45, 31, 48, 33, 51, 35, 54, 37, 57, 39, 60, 41, 63, 43, 66, 45, 69, 47, 72, 49, 75, 51, 78, 53, 81, 55, 84, 57, 87, 59, 90, 61, 93, 63, 96, 65, 99
Offset: 0

Views

Author

Michael Somos, Apr 16 2015

Keywords

Examples

			G.f. = 1 + x + 3*x^2 + 3*x^3 + 6*x^4 + 5*x^5 + 9*x^6 + 7*x^7 + 12*x^8 + ...
		

Crossrefs

Cf. A080512, A111711 (partial sums), A188626.

Programs

  • Haskell
    import Data.List (transpose)
    a257143 n = a257143_list !! n
    a257143_list = concat $ transpose [a008486_list, a005408_list]
    -- Reinhard Zumkeller, Apr 17 2015
  • Mathematica
    a[ n_] := Which[ n < 1, Boole[n == 0], OddQ[n], n, True, 3 n/2];
    a[ n_] := SeriesCoefficient[ (1 + x + x^2 + x^3 + x^4) / (1 - 2*x^2 + x^4), {x, 0, n}];
  • PARI
    {a(n) = if( n<1, n==0, n%2, n, 3*n/2)};
    
  • PARI
    {a(n) = if( n<0, 0, polcoeff( (1 - x^5) / ((1 - x) * (1 - x^2)^2) + x * O(x^n), n))};
    

Formula

a(n) is multiplicative with a(2^e) = 3 * 2^(e-1) if e>0, a(p^e) = p^e otherwise and a(0) = 1.
Euler transform of length 5 sequence [ 1, 2, 0, 0, -1].
G.f.: (1 - x^5) / ((1 - x) * (1 - x^2)^2).
G.f.: (1 + x + x^2 + x^3 + x^4) / (1 - 2*x^2 + x^4).
a(n) = A080512(n) if n>0.
First difference of A111711.
A188626(n) = p(-1) where p(x) is the unique degree-n polynomial such that p(k) = a(k) for k = 0, 1, ..., n.
From Amiram Eldar, Jan 03 2023: (Start)
Dirichlet g.f.: zeta(s-1)*(1+1/2^s).
Sum_{k=1..n} a(k) ~ (5/8) * n^2. (End)
Showing 1-3 of 3 results.