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.

Previous Showing 11-20 of 33 results. Next

A214282 Largest Euler characteristic of a downset on an n-dimensional cube.

Original entry on oeis.org

1, 1, 1, 3, 6, 10, 15, 35, 70, 126, 210, 462, 924, 1716, 3003, 6435, 12870, 24310, 43758, 92378, 184756, 352716, 646646, 1352078, 2704156, 5200300, 9657700, 20058300, 40116600, 77558760, 145422675, 300540195, 601080390, 1166803110, 2203961430, 4537567650, 9075135300, 17672631900
Offset: 1

Views

Author

Terence Tao, Jul 09 2012

Keywords

Comments

An m-downset is a set of subsets of 1..m such that if S is in the set, so are all subsets of S. The Euler characteristic of a downset is the number of sets in the downset with an even cardinality, minus the number with an odd cardinality.

Examples

			G.f. = x + x^2 + x^3 + 3*x^4 + 6*x^5 + 10*x^6 + 15*x^7 + 35*x^8 + ...
		

Crossrefs

Cf. A214283.

Programs

  • Haskell
    a214282 n = a007318 (n - 1) (a004524 (n - 1))
    -- Reinhard Zumkeller, Jul 14 2012
    
  • Mathematica
    Table[{Binomial[n - 1, n/2], Binomial[n, n/2], Binomial[n + 1, n/2 + 1], Binomial[n + 2, n/2 + 2]}, {n, 0, 28, 4}] (* Alonso del Arte, Jul 09 2012 *)
  • PARI
    a(n)=binomial(n-1,if(n%2,(n+1)\4*2,n/2)) \\ Charles R Greathouse IV, Jul 09 2012
    
  • PARI
    {a(n) = if( n<1, 0, vecmax( Vec((1 - x)^(n-1))))}; /* Michael Somos, Apr 21 2014 */
    
  • Python
    from math import comb
    def A214282(n): return comb(n-1, (n+1>>1)&(-1^(n&1))) # Chai Wah Wu, Jan 31 2024

Formula

a(n) = binomial(n - 1, n/2) when n is even, a(n) = binomial(n - 1, (n + 1)/2) when n is 3 mod 4, and a(n) = binomial(n - 1, (n - 1)/2) when n is 1 mod 4.
a(2n) = A001700(n-1). a(4n+1) = A001448(n). a(4n+3) = A186231(n).
a(n) = A214283(n) + A001405(n). - Reinhard Zumkeller, Jul 14 2012
a(n) = A007318(n-1, A004524(n-1)). - Reinhard Zumkeller, Jul 14 2012
a(n+1) = A000108([n/2])*A215495(n). - M. F. Hasler, Aug 25 2012
A214282(n) - A214283(n) is A056040(n) if n is even and A056040(n)/((n+1)/2) otherwise. - Peter Luschny, Jul 08 2016

A039823 a(n) = ceiling( (n^2 + n + 2)/4 ).

Original entry on oeis.org

1, 2, 4, 6, 8, 11, 15, 19, 23, 28, 34, 40, 46, 53, 61, 69, 77, 86, 96, 106, 116, 127, 139, 151, 163, 176, 190, 204, 218, 233, 249, 265, 281, 298, 316, 334, 352, 371, 391, 411, 431, 452, 474, 496, 518, 541, 565, 589, 613, 638, 664, 690, 716, 743, 771, 799, 827
Offset: 1

Views

Author

Keywords

Comments

Equals the number of different coefficient values in the expansion of Product_{i=1..n} (1 + q^1 + ... + q^i). Proof by Lawrence Sze: The Gaussian polynomial Prod_{k=1..n} Sum_{j=0..k} q^j is the q-version of n! and strictly unimodal with constant term 1. It has degree Sum_{k=1..n} k = n(n+1)/2, and thus n(n+1)/2+1 nonzero terms.
a(n) is equivalently the number of different absolute values obtained when summing the first n integers with all possible 2^n sign combinations. - Olivier Gérard, Mar 22 2010
Numbers in ascending order on the central axes (starting with 1) of Ulam's Spiral. - Bob Selcoe, Sep 25 2015

Examples

			Possible absolute values of sums of consecutive integers with any sign combination for n = 4 and n=5 are {0, 2, 4, 6, 8, 10} and {1, 3, 5, 7, 9, 11, 13, 15} respectively. - _Olivier Gérard_, Mar 22 2010
		

Crossrefs

Programs

  • Magma
    [Ceiling((n^2+n+2)/4) : n in [1..80]]; // Wesley Ivan Hurt, Sep 25 2015
    
  • Magma
    I:=[1,2,4,6,8]; [n le 5 select I[n] else 3*Self(n-1)-4*Self(n-2)+4*Self(n-3)-3*Self(n-4)+Self(n-5): n in [1..60]]; // Vincenzo Librandi, Sep 26 2015
  • Maple
    A039823:=n->ceil((n^2+n+2)/4): seq(A039823(n), n=1..100); # Wesley Ivan Hurt, Sep 25 2015
  • Mathematica
    Table[Floor[((n*(n+1)+2)/2+1)/2],{n,5!}] (* Vladimir Joseph Stephan Orlovsky, Apr 26 2010 *)
    LinearRecurrence[{3, -4, 4, -3, 1}, {1, 2, 4, 6, 8}, 70] (* Vincenzo Librandi, Sep 26 2015 *)
  • Maxima
    makelist((n*(n+1)+%i^(n*(n+1))+3)/4,n,1,57); /* Bruno Berselli, Jul 25 2012 */
    
  • PARI
    a(n) = ceil((n^2+n+2)/4);
    vector(80, n, a(n)) \\ Altug Alkan, Sep 25 2015
    

Formula

a(n) = floor(binomial(n+1, 2)/2) + 1 = A011848(n+1) + 1.
G.f.: x*(x^4-2*x^3+2*x^2-x+1)/((1+x^2)*(1-x)^3).
a(n) = (n*(n+1)+i^(n*(n+1))+3)/4, where i=sqrt(-1). - Bruno Berselli, Jul 25 2012
a(n) = a(n-1) + A004524(n+1). - Bob Selcoe, Sep 25 2015
a(n) = 3*a(n-1)-4*a(n-2)+4*a(n-3)-3*a(n-4)+a(n-5) for n>5. - Wesley Ivan Hurt, Sep 25 2015
a(n) = ceiling( (n^2+n+1)/4 ). - Bob Selcoe, Sep 26 2015

Extensions

Edited by Ralf Stephan, Nov 15 2004

A300358 Array read by antidiagonals: T(m,n) = total domination number of the grid graph P_m X P_n.

Original entry on oeis.org

1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 4, 3, 4, 3, 4, 4, 4, 4, 4, 4, 4, 4, 5, 6, 5, 4, 4, 4, 6, 6, 8, 8, 6, 6, 4, 5, 6, 7, 8, 9, 8, 7, 6, 5, 6, 6, 8, 10, 10, 10, 10, 8, 6, 6, 6, 8, 9, 12, 12, 12, 12, 12, 9, 8, 6, 6, 8, 10, 12, 14, 14, 14, 14, 12, 10, 8, 6, 7, 8, 11, 14, 15, 16, 15, 16, 15, 14, 11, 8, 7
Offset: 1

Views

Author

Andrew Howroyd, Apr 20 2018

Keywords

Examples

			Table begins:
=======================================================
m\n| 1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16
---+---------------------------------------------------
1  | 1  2  2  2  3  4  4  4  5  6  6  6  7  8  8  8 ...
2  | 2  2  2  4  4  4  6  6  6  8  8  8 10 10 10 12 ...
3  | 2  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 ...
4  | 2  4  4  6  8  8 10 12 12 14 14 16 18 18 20 20 ...
5  | 3  4  5  8  9 10 12 14 15 16 18 20 21 22 24 26 ...
6  | 4  4  6  8 10 12 14 16 18 20 20 24 24 26 28 30 ...
7  | 4  6  7 10 12 14 15 18 20 22 24 26 27 30 32 34 ...
8  | 4  6  8 12 14 16 18 20 22 24 28 30 32 34 36 38 ...
9  | 5  6  9 12 15 18 20 22 25 28 30 32 35 38 40 42 ...
...
		

Crossrefs

Rows 1..2 are A004524(n+2), A302402.
Main diagonal is A302488.

A365171 The number of divisors d of n such that gcd(d, n/d) is a square.

Original entry on oeis.org

1, 2, 2, 2, 2, 4, 2, 2, 2, 4, 2, 4, 2, 4, 4, 3, 2, 4, 2, 4, 4, 4, 2, 4, 2, 4, 2, 4, 2, 8, 2, 4, 4, 4, 4, 4, 2, 4, 4, 4, 2, 8, 2, 4, 4, 4, 2, 6, 2, 4, 4, 4, 2, 4, 4, 4, 4, 4, 2, 8, 2, 4, 4, 4, 4, 8, 2, 4, 4, 8, 2, 4, 2, 4, 4, 4, 4, 8, 2, 6, 3, 4, 2, 8, 4, 4, 4
Offset: 1

Views

Author

Amiram Eldar, Aug 25 2023

Keywords

Comments

The sum of these divisors is A365172(n).

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := Floor[(e + 3)/4] + Floor[(e + 4)/4]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    a(n) = vecprod(apply(x -> (x+3)\4 + (x+4)\4, factor(n)[, 2]));
    
  • PARI
    for(n=1, 100, print1(direuler(p=2, n, 1/((1 - X)^2 * (1 + X^2)))[n], ", ")) \\ Vaclav Kotesovec, Jan 20 2024

Formula

Multiplicative with a(p^e) = floor((e + 3)/4) + floor((e + 4)/4) = A004524(e+3).
a(n) <= A000005(n), with equality if and only if n is squarefree (A005117).
a(n) >= A034444(n), with equality if and only if n is not a biquadrateful number (A046101).
a(n) == 1 (mod 2) if and only if n is a fourth power (A000583).
From Vaclav Kotesovec, Jan 20 2024: (Start)
Dirichlet g.f.: zeta(s)^2 * Product_{p prime} (1 - 1/(p^(2*s) + 1)).
Let f(s) = Product_{p prime} (1 - 1/(p^(2*s) + 1)).
Sum_{k=1..n} a(k) ~ f(1) * n * (log(n) + 2*gamma - 1 + f'(1)/f(1)), where
f(1) = Product_{p prime} (1 - 1/(p^2 + 1)) = Pi^2/15 = A182448,
f'(1) = f(1) * Sum_{p prime} 2*log(p) / (p^2 + 1) = f(1) * 0.8852429263675811068149340172820329246145172848406469350087715037483367369...
and gamma is the Euler-Mascheroni constant A001620. (End)

A054040 a(n) terms of series {1/sqrt(j)} are >= n.

Original entry on oeis.org

1, 3, 5, 7, 10, 14, 18, 22, 27, 33, 39, 45, 52, 60, 68, 76, 85, 95, 105, 115, 126, 138, 150, 162, 175, 189, 202, 217, 232, 247, 263, 280, 297, 314, 332, 351, 370, 389, 409, 430, 451, 472, 494, 517, 540, 563, 587, 612, 637, 662, 688, 715, 741, 769, 797, 825
Offset: 1

Views

Author

Asher Auel, Apr 13 2000

Keywords

Comments

In many cases the first differences have the form {2k, 2k, 2k, 2k+1} (A004524). In such cases the second differences are {0, 0, 1, 1}. See A082915 for the exceptions. In as many as these, the first differences have the form {2k-1, 2k-1, 2k-1, 2k}. - Robert G. Wilson v, Apr 18 2003 [Corrected by Carmine Suriano, Nov 08 2013]
a(100)=2574, a(1000)=250731 & a(10000)=25007302 which differs from Sum{i=4..104}A004524(i)=2625, Sum{i=4..1004}A004524(i)=251250 & Sum{i=4..10004}A004524(i)=25012500. - Robert G. Wilson v, Apr 18 2003
A054040(n) <= A011848(n+2), A054040(10000)=25007302 and A011848(n+2)=25007500. - Robert G. Wilson v, Apr 18 2003

Examples

			Let b(k) = 1 + 1/sqrt(2) + 1/sqrt(3) + ... + 1/sqrt(k):
.k.......1....2.....3.....4.....5.....6.....7
-------------------------------------------------
b(k)...1.00..1.71..2.28..2.78..3.23..3.64..4.01
For A019529 we have:
n=0: smallest k is a(0) = 1 since 1.00 > 0
n=1: smallest k is a(1) = 2 since 1.71 > 1
n=2: smallest k is a(2) = 3 since 2.28 > 2
n=3: smallest k is a(3) = 5 since 3.23 > 3
n=4: smallest k is a(4) = 7 since 4.01 > 4
For this sequence we have:
n=1: smallest k is a(1) = 1 since 1.00 >= 1
n=2: smallest k is a(2) = 3 since 2.28 >= 2
n=3: smallest k is a(3) = 5 since 3.23 >= 3
n=4: smallest k is a(4) = 7 since 4.01 >= 4
		

Crossrefs

See A019529 for a different version.

Programs

  • Mathematica
    f[n_] := Block[{k = 0, s = 0}, While[s < n, k++; s = N[s + 1/Sqrt[k], 50]]; k]; Table[f[n], {n, 1, 60}]
  • PARI
    a(n)=if(n<0,0,t=1;z=1;while(zBenoit Cloitre, Sep 23 2012

Formula

Let f(n) = (1/4)*(n^2-2*zeta(1/2)*n) then we have a(n) = f(n) + O(1). More precisely we claim that for n >= 2 we have a(n) = floor(f(n)+c) where c > Max{a(n)-f(n) : n>=1} = a(153) - f(153) = 1.032880076066608813953... and we believe we can take c = 1.033. - Benoit Cloitre, Sep 23 2012

Extensions

Definition and offset modified by N. J. A. Sloane, Sep 01 2009

A093390 a(n) = floor(n/9) + floor((n+1)/9) + floor((n+2)/9).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 3, 3, 3, 3, 3, 3, 4, 5, 6, 6, 6, 6, 6, 6, 6, 7, 8, 9, 9, 9, 9, 9, 9, 9, 10, 11, 12, 12, 12, 12, 12, 12, 12, 13, 14, 15, 15, 15, 15, 15, 15, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 21, 21, 21, 21, 21, 21, 22, 23, 24, 24, 24, 24, 24, 24, 24, 25
Offset: 0

Views

Author

Reinhard Zumkeller, Mar 28 2004

Keywords

Comments

Half the domination number of the camel's graph (from Tamerlane Chess) on a 2 X (n-6) chessboard. - David Nacin, May 28 2017

Crossrefs

Programs

  • Mathematica
    Array[Total@ Map[Floor[#/9] &, # + Range[0, 2]] &, 80, 0] (* or *)
    CoefficientList[Series[x^7/((x^6 + x^3 + 1) (x - 1)^2), {x, 0, 79}], x] (* Michael De Vlieger, Dec 12 2017 *)
  • PARI
    a(n)=n\9+(n+1)\9+(n+2)\9 \\ Charles R Greathouse IV, Oct 16 2015

Formula

G.f.: x^7 / ( (x^6+x^3+1)*(x-1)^2 ). - R. J. Mathar, Mar 22 2011
a(n) = n/3 + O(1). - Charles R Greathouse IV, Oct 16 2015
a(n) = A287394(n-6)/2. - David Nacin, May 28 2017

A140201 Partial sums of A140081.

Original entry on oeis.org

0, 1, 2, 4, 4, 5, 6, 8, 8, 9, 10, 12, 12, 13, 14, 16, 16, 17, 18, 20, 20, 21, 22, 24, 24, 25, 26, 28, 28, 29, 30, 32, 32, 33, 34, 36, 36, 37, 38, 40, 40, 41, 42, 44, 44, 45, 46, 48, 48, 49, 50, 52, 52, 53, 54, 56, 56, 57, 58, 60, 60, 61, 62, 64, 64, 65, 66, 68, 68, 69, 70, 72, 72, 73, 74
Offset: 0

Views

Author

Nadia Heninger and N. J. A. Sloane, Jun 09 2008

Keywords

Crossrefs

Programs

  • Magma
    I:=[0, 1, 2, 4, 4]; [n le 5 select I[n] else Self(n-1)+Self(n-4)-Self(n-5): n in [1..80]]; // Vincenzo Librandi, Sep 17 2012
  • Maple
    A140201:=n->(4*n+1-I^(2*n)+(-I)^(1+n)+I^(1+n))/4: seq(A140201(n), n=0..100); # Wesley Ivan Hurt, Jun 04 2016
  • Mathematica
    Accumulate[PadRight[{}, 68, {0, 1, 1, 2}]] (* Harvey P. Dale, Aug 19 2011 *)

Formula

a(n) = A047624(n+1) - A042948(A004526(n)). - Reinhard Zumkeller, Feb 21 2010
a(n) = A002265(n+1) + A057353(n+1). - Reinhard Zumkeller, Feb 26 2011
From Bruno Berselli, Jan 27 2011: (Start)
G.f.: x*(1+x+2*x^2)/((1+x)*(1+x^2)*(1-x)^2).
a(n) = a(n-1) + a(n-4) - a(n-5) for n>4.
a(n) = n + A121262(n+1). (End)
a(n) = n when n+1 is not a multiple of 4, and a(n) = n+1 when n+1 is a multiple of 4. - Dennis P. Walsh, Aug 06 2012
a(n) = A004524(n+1) + A004526(n+1). - Arkadiusz Wesolowski, Sep 17 2012
a(n) = (4*n+1-i^(2*n)+(-i)^(1+n)+i^(1+n))/4 where i=sqrt(-1). - Wesley Ivan Hurt, Jun 04 2016
a(n) = n+1-(sign((n+1) mod 4) mod 3). - Wesley Ivan Hurt, Sep 26 2017

A154957 A symmetric (0,1)-triangle.

Original entry on oeis.org

1, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1
Offset: 0

Views

Author

Paul Barry, Jan 18 2009

Keywords

Comments

Parity of A003983. - Jeremy Gardiner, Mar 09 2014

Examples

			Triangle begins
  1;
  1, 1;
  1, 0, 1;
  1, 0, 0, 1;
  1, 0, 1, 0, 1;
  1, 0, 1, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1;
  1, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 1;
		

Crossrefs

Cf. A003983, A004524 (row sums), A154958 (diagonal sums), A158856.

Programs

  • Mathematica
    T[n_, k_]:= Sum[(Mod[j+1,2] - Mod[j,2]), {j,0,Min[k,n-k]}];
    Table[T[n, k], {n,0,20}, {k,0,n}]//Flatten (* G. C. Greubel, Mar 07 2022 *)
  • Sage
    def A154957(n,k): return sum( (j+1)%2 - j%2 for j in (0..min(k,n-k)) )
    flatten([[A154957(n,k) for k in (0..n)] for n in (0..20)]) # G. C. Greubel, Mar 07 2022

Formula

T(n,k) = Sum_{j=0..n} [j<=k]*[j<=n-k]*(mod(j+1,2) - mod(j,2)).
T(2*n, n) - T(2*n, n+1) = (-1)^n.
T(2*n, n) = (n+1) mod 2.
Sum_{k=0..n} T(n, k) = A004524(n+3).
Sum_{k=0..floor(n/2)} T(n-k, k) = A154958(n) (diagonal sums).
From G. C. Greubel, Mar 07 2022: (Start)
T(n, n-k) = T(n, k).
Sum_{k=0..floor(n/2)} T(n, k) = floor((n+4)/4).
T(2*n+1, n) = (1+(-1)^n)/2. (End)

A365173 The number of divisors d of n such that gcd(d, n/d) is an exponentially odd number (A268335).

Original entry on oeis.org

1, 2, 2, 3, 2, 4, 2, 4, 3, 4, 2, 6, 2, 4, 4, 4, 2, 6, 2, 6, 4, 4, 2, 8, 3, 4, 4, 6, 2, 8, 2, 4, 4, 4, 4, 9, 2, 4, 4, 8, 2, 8, 2, 6, 6, 4, 2, 8, 3, 6, 4, 6, 2, 8, 4, 8, 4, 4, 2, 12, 2, 4, 6, 5, 4, 8, 2, 6, 4, 8, 2, 12, 2, 4, 6, 6, 4, 8, 2, 8, 4, 4, 2, 12, 4, 4
Offset: 1

Views

Author

Amiram Eldar, Aug 25 2023

Keywords

Comments

First differs from A252505 at n = 64.
The sum of these divisors is A365174(n).

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := Floor[(e + 5)/4] + Floor[(e + 6)/4]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    a(n) = vecprod(apply(x -> (x+5)\4 + (x+6)\4, factor(n)[, 2]));
    
  • PARI
    for(n=1, 100, print1(direuler(p=2, n, (1 + X^2 - X^4)/((1 - X)^2*(1 + X^2)))[n], ", ")) \\ Vaclav Kotesovec, Jan 20 2024

Formula

Multiplicative with a(p^e) = floor((e+5)/4) + floor((e+6)/4) = A004524(e+5).
a(n) <= A000005(n), with equality if and only if n is not a biquadrateful number (A046101).
a(n) >= A034444(n), with equality if and only if n is squarefree (A005117).
a(n) == 1 (mod 2) if and only if n is a square of an exponentially odd number (i.e., a number whose prime factorization include only exponents e such that e == 2 (mod 4)).
From Vaclav Kotesovec, Jan 20 2024: (Start)
Dirichlet g.f.: zeta(s)^2 * Product_{p prime} (1 - 1/(p^(2*s)*(1 + p^(2*s)))).
Let f(s) = Product_{p prime} (1 - 1/(p^(2*s)*(1 + p^(2*s)))).
Sum_{k=1..n} a(k) ~ f(1) * n * (log(n) + 2*gamma - 1 + f'(1)/f(1)), where
f(1) = Product_{p prime} (1 - 1/(p^2*(1 + p^2))) = 0.937494282731300250789438325050116436995101826036120273493270589183132928...,
f'(1) = f(1) * Sum_{p prime} (4*p^2 + 2) * log(p) / (p^6 + 2*p^4 - 1) = f(1) * 0.192452062257404507109731932640803706644036700262364333369815000973104583...
and gamma is the Euler-Mascheroni constant A001620. (End)

A093391 a(n) = floor(n/16) + floor((n+1)/16) + floor((n+2)/16) + floor((n+3)/16).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 6, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 10, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 14, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 17, 18, 19, 20, 20, 20, 20
Offset: 0

Views

Author

Reinhard Zumkeller, Mar 28 2004

Keywords

Crossrefs

Programs

  • Haskell
    a093391 n = sum $ map ((flip div 16) . (+ n)) [0..3] -- Reinhard Zumkeller, Oct 10 2013
    
  • Magma
    [Floor(n/16)+Floor((n+1)/16)+Floor((n+2)/16)+Floor((n+3)/16): n in [0..100]]; // Vincenzo Librandi, Feb 16 2018
  • Mathematica
    Total/@(Floor/@(Partition[Range[0,90],4,1]/16)) (* Harvey P. Dale, Sep 21 2013 *)
    CoefficientList[Series[x^13 / ((1 + x^4) (x^8 + 1) (x - 1)^2), {x, 0, 100}], x] (* Vincenzo Librandi, Feb 16 2018 *)
  • PARI
    a(n) = n\16 + (n+1)\16 + (n+2)\16 + (n+3)\16 \\ Andrew Howroyd, Feb 15 2018
    

Formula

From R. J. Mathar, Mar 22 2011: (Start)
a(n) = +2*a(n-1) -a(n-2) -a(n-4) +2*a(n-5) -a(n-6) -a(n-8) +2*a(n-9) -a(n-10) -a(n-12) +2*a(n-13) -a(n-14).
G.f.: x^13/ ( (1+x^4)*(x^8+1)*(x-1)^2 ).
(End)
Previous Showing 11-20 of 33 results. Next