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 218 results. Next

A014601 Numbers congruent to 0 or 3 mod 4.

Original entry on oeis.org

0, 3, 4, 7, 8, 11, 12, 15, 16, 19, 20, 23, 24, 27, 28, 31, 32, 35, 36, 39, 40, 43, 44, 47, 48, 51, 52, 55, 56, 59, 60, 63, 64, 67, 68, 71, 72, 75, 76, 79, 80, 83, 84, 87, 88, 91, 92, 95, 96, 99, 100, 103, 104, 107, 108, 111, 112, 115, 116, 119, 120, 123, 124
Offset: 0

Views

Author

Eric Rains (rains(AT)caltech.edu)

Keywords

Comments

Discriminants of orders in imaginary quadratic fields (negated). [Comment corrected by Christopher E. Thompson, Dec 11 2016]
Numbers such that Langford-Skolem problem has a solution - see A014552.
Complement of A042963. - Reinhard Zumkeller, Oct 04 2004
Also called skew amenable numbers; a number k is skew amenable if there exist a set {a(i)} of integers satisfying the relations k = Sum_{i=1..k} a(i) = -Product_{i=1..k} a(i). Thus we have 8 = 1 + 1 + 1 + 1 + 1 + 1 - 2 + 4 = -(1*1*1*1*1*1*(-2)*4). - Lekraj Beedassy, Jan 07 2005
Possible nonpositive discriminants of quadratic equation a*x^2 + b*x + c or discriminants of binary quadratic forms a*x^2 + b*x*y + c*y^2. - Artur Jasinski, Apr 28 2008
Also, disregarding the 0 term, positive integers m such that, equivalently,
(i) +-1 +-2 +-... +-m is even for all choices of signs,
(ii) +-1 +-2 +-... +-m = 0 for some choices of signs,
(iii) for all -m <= k <= m, k = +-1 +-2 +-... +-(k-1) +-(k+1) +-(k+2) +-... +-m for at least one choice of signs. - Rick L. Shepherd, Oct 29 2008
A145768(a(n)) is even. - Reinhard Zumkeller, Jun 05 2012
Multiples of 4 interleaved with 1 less than multiples of 4. - Wesley Ivan Hurt, Nov 08 2013
((2*k+0) + (2*k+1) + ... + (2*k+m-1) + (2*k+m)) is even if and only if m = a(n) for some n where k is any nonnegative integer. - Gionata Neri, Jul 24 2015
Numbers whose binary reflected Gray code (A014550) ends with 0. - Amiram Eldar, May 17 2021

Examples

			G.f. = 3*x + 4*x^2 + 7*x^3 + 8*x^4 + 11*x^5 + 12*x^6 + 15*x^7 + 16*x^8 + ...
		

References

  • H. Cohen, Course in Computational Alg. No. Theory, Springer, 1993, pp. 514-5.
  • A. Scholz and B. Schoeneberg, Einführung in die Zahlentheorie, 5. Aufl., de Gruyter, Berlin, New York, 1973, p. 108.

Crossrefs

Cf. A274406. - Bruno Berselli, Jun 26 2016

Programs

  • Haskell
    a014601 n = a014601_list !! n
    a014601_list = [x | x <- [0..], mod x 4 `elem` [0, 3]]
    -- Reinhard Zumkeller, Jun 05 2012
  • Magma
    [n: n in [0..200]|n mod 4 in {0,3}]; // Vincenzo Librandi, Dec 24 2010
    
  • Maple
    A014601:=n->3*n-2*floor(n/2); seq(A014601(k), k=0..100); # Wesley Ivan Hurt, Nov 08 2013
  • Mathematica
    aa = {}; Do[Do[Do[d = b^2 - 4 a c; If[d <= 0, AppendTo[aa, -d]], {a, 0, 50}], {b, 0, 50}], {c, 0, 50}]; Union[aa] (* Artur Jasinski, Apr 28 2008 *)
    Select[Range[0, 124], Or[Mod[#, 4] == 0, Mod[#, 4] == 3] &] (* Ant King, Nov 18 2010 *)
    CoefficientList[Series[2 x/(1 - x)^2 + (1/(1 - x) + 1/(1 + x)) x/2, {x, 0, 100}], x] (* Vincenzo Librandi, May 18 2014 *)
    a[ n_] := 2 n + Mod[n, 2]; (* Michael Somos, Jul 24 2015 *)
  • PARI
    {a(n) = 2*n + n%2}; /* Michael Somos, Dec 27 2010 */
    

Formula

a(n) = (n + 1)*2 + 1 - n mod 2. - Reinhard Zumkeller, Apr 21 2003
A014494(n) = A000217(a(n)). - Reinhard Zumkeller, Oct 04 2004
a(n) = Sum_{k=1..n} (2 - (-1)^k). - William A. Tedeschi, Mar 20 2008
A139131(a(n)) = A078636(a(n)). - Reinhard Zumkeller, Apr 10 2008
From R. J. Mathar, Sep 25 2009: (Start)
a(n) = a(n-1) + a(n-2) - a(n-3) for n > 2.
G.f.: x*(3+x)/((1+x)*(x-1)^2). (End)
a(n) = 2*n + (n mod 2). - Paolo Valzasina (p.valzasina(AT)gmail.com), Nov 24 2009
a(n) = (4*n - (-1)^n + 1)/2. - Bruno Berselli, Oct 06 2010
a(n) = 4*n - a(n-1) - 1 (with a(0) = 0). - Vincenzo Librandi, Dec 24 2010
a(n) = -A042948(-n) for all n in Z. - Michael Somos, Dec 27 2010
G.f.: 2*x / (1 - x)^2 + (1 / (1 - x) + 1 / (1 + x)) * x/2. - Michael Somos, Dec 27 2010
a(n) = Sum_{k>=0} A030308(n,k)*b(k) with b(0) = 3 and b(k) = 2^(k+1) for k > 0. - Philippe Deléham, Oct 17 2011
a(n) = ceiling((4/3)*ceiling(3*n/2)). - Clark Kimberling, Jul 04 2012
a(n) = 3n - 2*floor(n/2). - Wesley Ivan Hurt, Nov 08 2013
a(n) = A042948(n+1) - 1 for all n in Z. - Michael Somos, Jul 24 2015
a(n) + a(n+1) = A004767(n) for all n in Z. - Michael Somos, Jul 24 2015
Sum_{n>=1} (-1)^(n+1)/a(n) = 3*log(2)/4 - Pi/8. - Amiram Eldar, Dec 05 2021
E.g.f.: ((4*x + 1)*exp(x) - exp(-x))/2. - David Lovler, Aug 04 2022

A008545 Quadruple factorial numbers: Product_{k=0..n-1} (4*k + 3).

Original entry on oeis.org

1, 3, 21, 231, 3465, 65835, 1514205, 40883535, 1267389585, 44358635475, 1729986783525, 74389431691575, 3496303289504025, 178311467764705275, 9807130727058790125, 578620712896468617375, 36453104912477522894625, 2442358029135994033939875
Offset: 0

Views

Author

Joe Keane (jgk(AT)jgk.org)

Keywords

Comments

a(n-1), n >= 1, enumerates increasing plane (a.k.a. ordered) trees with n vertices (one of them a root labeled 1) with one version of a vertex with out-degree r = 0 (a leaf or a root) and each vertex with out-degree r >= 1 comes in binomial(r + 2, 2) types (like a binomial(r + 2, 2)-ary vertex). See the increasing tree comments under A001498. For example, a(1) = 3 from the three trees with n = 2 vertices (a root (out-degree r = 1, label 1) and a leaf (r = 0), label 2). There are three such trees because of the three types of out-degree r = 1 vertices. - Wolfdieter Lang, Oct 05 2007 [corrected by Karen A. Yeats, Jun 17 2013]
a(n) is the product of the positive integers less than or equal to 4n that have modulo 4 = 3. - Peter Luschny, Jun 23 2011

Examples

			G.f. = 1 + 3*x + 21*x^2 + 231*x^3 + 3465*x^4 + 65835*x^5 + 1514205*x^6 + ...
a(3) = sigma[4,3]^{3}_3 = 3*7*11 = 231. See the name. - _Wolfdieter Lang_, May 29 2017
		

Crossrefs

a(n)= A000369(n+1, 1) (first column of triangle).
Partial products of A004767.
Cf. A007696, A014601, A225471 (first column).

Programs

  • GAP
    List([0..20], n-> Product([0..n-1], k-> 4*k+3) ); # G. C. Greubel, Aug 18 2019
  • Haskell
    a008545 n = a008545_list !! n
    a008545_list = scanl (*) 1 a004767_list
    -- Reinhard Zumkeller, Oct 25 2013
    
  • Magma
    [1] cat [(&*[4*k+3: k in [0..n-1]]): n in [1..20]]; // G. C. Greubel, Aug 18 2019
    
  • Maple
    f := n->product( (4*k-1),k=0..n);
    A008545 := n -> mul(k, k = select(k-> k mod 4 = 3, [$1 .. 4*n])): seq(A008545(n), n=0..15); # Peter Luschny, Jun 23 2011
  • Mathematica
    FoldList[Times, 1, 4 Range[0, 20] + 3] (* Harvey P. Dale, Jan 19 2013 *)
    a[n_]:= Pochhammer[3/4, n] 4^n; (* Michael Somos, Jan 17 2014 *)
    a[n_]:= If[n < 0, 1 / Product[ -k, {k, 1, -4 n - 3, 4}], Product[k, {k, 3, 4 n - 1, 4}]]; (* Michael Somos, Jan 17 2014 *)
  • PARI
    a(n)=prod(k=0,n-1,4*k+3) \\ Charles R Greathouse IV, Jun 23 2011
    
  • PARI
    {a(n) = if( n<0, 1 / prod(k=1, -n, 3 - 4*k), prod(k=1, n, 4*k - 1))}; /* Michael Somos, Jan 17 2014 */
    
  • Sage
    [product(4*k+3 for k in (0..n-1)) for n in (0..20)] # G. C. Greubel, Aug 18 2019
    

Formula

a(n) = 3*A034176(n) = (4*n-1)(!^4), n >= 1, a(0) := 1.
E.g.f.: (1-4*x)^(-3/4).
a(n) ~ 2^(1/2)*Pi^(1/2)*Gamma(3/4)^(-1)*n^(1/4)*2^(2*n)*e^(-n)*n^n*{1 - 1/96*n^(-1) + ...}. - Joe Keane (jgk(AT)jgk.org), Nov 23 2001
G.f.: 1/(1 - 3x/(1 - 4x/(1 - 7x/(1 - 8x/(1 - 11x/(1 - 12x/(1 - 15x/(1 - 16x/(1 - 19x/(1 - 20x/(1 - 23x/(1 - 24x/(1 - ...))))))))))))) (continued fraction). - Paul Barry, Dec 03 2009
a(n) = (-1)^n*Sum_{k = 0..n} 4^k*s(n + 1, n + 1 - k), where s(n, k) are the Stirling numbers of the first kind, A048994. - Mircea Merca, May 03 2012
D-finite with recurrence: a(n) + (-4*n + 1)*a(n-1) = 0. - R. J. Mathar, Dec 04 2012
G.f.: 1/x - G(0)/(2*x), where G(k)= 1 + 1/(1 - x*(4*k-1)/(x*(4*k-1) + 1/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 04 2013
a(-n) = (-1)^n / A007696(n). - Michael Somos, Jan 17 2014
G.f.: 1/(1 - b(1)*x / (1 - b(2)*x / ...)) where b = A014601. - Michael Somos, Jan 17 2014
a(n) = 4^n * Gamma(n+3/4) / Gamma(3/4). - Vaclav Kotesovec, Jan 28 2015
G.f.: 1/(1 - 3*x - 12*x^2/(1 - 11*x - 56*x^2/(1 - 19*x - 132*x^2/(1 - 27*x - 240*x^2/(1 - ...))))) (Jacobi continued fraction). - Nikolaos Pantelidis, Feb 28 2020
Sum_{n>=0} 1/a(n) = 1 + exp(1/4)*(Gamma(3/4) - Gamma(3/4, 1/4))/sqrt(2). - Amiram Eldar, Dec 18 2022

A004771 a(n) = 8*n + 7. Or, numbers whose binary expansion ends in 111.

Original entry on oeis.org

7, 15, 23, 31, 39, 47, 55, 63, 71, 79, 87, 95, 103, 111, 119, 127, 135, 143, 151, 159, 167, 175, 183, 191, 199, 207, 215, 223, 231, 239, 247, 255, 263, 271, 279, 287, 295, 303, 311, 319, 327, 335, 343, 351, 359, 367, 375, 383, 391, 399, 407, 415, 423, 431
Offset: 0

Views

Author

Keywords

Comments

These numbers cannot be expressed as the sum of 3 squares. - Artur Jasinski, Nov 22 2006
These numbers cannot be perfect squares. - Cino Hilliard, Sep 03 2006
a(n-2), n >= 2, appears in the second column of triangle A239126 related to the Collatz problem. - Wolfdieter Lang, Mar 14 2014
The initial terms 7, 15, 23, 31 are the generating set for the rest of the sequence in the sense that, by Lagrange's Four Square Theorem, any number n of the form 8*k+7 can always be written as a sum of no fewer than four squares, and if n = a^2 + b^2 + c^2 + d^2, then (a mod 4)^2 + (b mod 4)^2 + (c mod 4)^2 + (d mod 4)^2 must be one of 7, 15, 23, 31. - Walter Kehowski, Jul 07 2014
Define a set of consecutive positive odd numbers {1, 3, 5, ..., 12*n + 9} and skip the number 6*n + 5. Then the contraharmonic mean of that set gives this sequence. For example, ContraharmonicMean[{1, 3, 7, 9}] = 7. - Hilko Koning, Aug 27 2018
Jacobi symbol (2, a(n)) = Kronecker symbol (a(n), 2) = 1. - Jianing Song, Aug 28 2018

References

  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, page 246.

Crossrefs

Cf. A007522 (primes), subsequence of A047522.

Programs

Formula

O.g.f: (7 + x)/(1 - x)^2 = 8/(1 - x)^2 - 1/(1 - x). - R. J. Mathar, Nov 30 2007
a(n) = 2*a(n-1) - a(n-2) for n >= 2. - Vincenzo Librandi, May 28 2011
A056753(a(n)) = 7. - Reinhard Zumkeller, Aug 23 2009
a(n) = t(t(t(n))), where t(i) = 2*i + 1.
a(n) = A004767(2*n+1), for n >= 0. See also A004767(2*n) = A017101(n). - Wolfdieter Lang, Feb 03 2022
From Elmo R. Oliveira, Apr 11 2024: (Start)
E.g.f.: exp(x)*(7 + 8*x).
a(n) = A033954(n+1) - A033954(n). (End)

A084849 a(n) = 1 + n + 2*n^2.

Original entry on oeis.org

1, 4, 11, 22, 37, 56, 79, 106, 137, 172, 211, 254, 301, 352, 407, 466, 529, 596, 667, 742, 821, 904, 991, 1082, 1177, 1276, 1379, 1486, 1597, 1712, 1831, 1954, 2081, 2212, 2347, 2486, 2629, 2776, 2927, 3082, 3241, 3404, 3571, 3742, 3917, 4096, 4279, 4466
Offset: 0

Views

Author

Paul Barry, Jun 09 2003

Keywords

Comments

Equals (1, 2, 3, ...) convolved with (1, 2, 4, 4, 4, ...). a(3) = 22 = (1, 2, 3, 4) dot (4, 4, 2, 1) = (4 + 8 + 6 + 4). - Gary W. Adamson, May 01 2009
a(n) is also the number of ways to place 2 nonattacking bishops on a 2 X (n+1) board. - Vaclav Kotesovec, Jan 29 2010
Partial sums are A174723. - Wesley Ivan Hurt, Apr 16 2016
Also the number of irredundant sets in the n-cocktail party graph. - Eric W. Weisstein, Aug 09 2017

Crossrefs

Programs

Formula

a(n) = A058331(n) + A000027(n).
G.f.: (1 + x + 2*x^2)/(1 - x)^3.
a(n) = A014105(n) + 1; A100035(a(n)) = 1. - Reinhard Zumkeller, Oct 31 2004
a(n) = ceiling((2*n + 1)^2/2) - n = A001844(n) - n. - Paul Barry, Jul 16 2006
From Gary W. Adamson, Oct 07 2007: (Start)
Row sums of triangle A131901.
(a(n): n >= 0) is the binomial transform of (1, 3, 4, 0, 0, 0, ...). (End)
Equals A134082 * [1,2,3,...]. -
a(n) = (1 + A000217(2*n-1) + A000217(2*n+1))/2. - Enrique Pérez Herrero, Apr 02 2010
a(n) = (A177342(n+1) - A177342(n))/2, with n > 0. - Bruno Berselli, May 19 2010
a(n) - 3*a(n-1) + 3*a(n-2) - a(n-3) = 0, with n > 2. - Bruno Berselli, May 24 2010
a(n) = 4*n + a(n-1) - 1 (with a(0) = 1). - Vincenzo Librandi, Aug 08 2010
With an offset of 1, the polynomial a(t-1) = 2*t^2 - 3*t + 2 is the Alexander polynomial (with negative powers cleared) of the 3-twist knot. The associated Seifert matrix S is [[-1,-1], [0,-2]]. a(n-1) = det(transpose(S) - n*S). Cf. A060884. - Peter Bala, Mar 14 2012
E.g.f.: (1 + 3*x + 2*x^2)*exp(x). - Ilya Gutkovskiy, Apr 16 2016

A017101 a(n) = 8n + 3.

Original entry on oeis.org

3, 11, 19, 27, 35, 43, 51, 59, 67, 75, 83, 91, 99, 107, 115, 123, 131, 139, 147, 155, 163, 171, 179, 187, 195, 203, 211, 219, 227, 235, 243, 251, 259, 267, 275, 283, 291, 299, 307, 315, 323, 331, 339, 347, 355, 363, 371, 379, 387, 395, 403, 411, 419, 427
Offset: 0

Views

Author

Keywords

Comments

Apart from initial term(s), dimension of the space of weight 2n cusp forms for Gamma_0( 47 ).
Also numbers of the form x^2 + y^2 + z^2, where x,y,z are odd integers. - Alexander Adamchuk, Dec 01 2006
Conjecture: 2*a(n) is the half-period of oscillation of a Langton's ant colony that is n basic blocks in length. To construct such blocks use a pair of ants facing north at (x,y) and (x+1,y+2) (using Golly's coordinate system). Each successive block is placed 1 cell away from the previous one, i.e., the x coordinate shifts by 3, so we have (x+3k,y) and (x+3k+1,y+2). Also, because of the symmetry of the oscillation pattern, 4*a(n) is the length of the whole period (see MathOverflow link for details). - Mikhail Kurkov, Nov 20 2019

References

  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, page 247.

Crossrefs

Programs

Formula

a(n) = A001969(2*n+1) + A001969(2*n) = A000069(2*n+1) + A000069(2*n). - Philippe Deléham, Feb 04 2004
G.f.: (3+5*x)/(1-x)^2. - R. J. Mathar, Mar 30 2011
a(n) = 2*a(n-1) - a(n-2) for n>1. - Vincenzo Librandi, May 28 2011
a(A002265(n)) = A004442(n) + A004443(n). - Wesley Ivan Hurt, Apr 06 2016
E.g.f.: exp(x)*(3 + 8*x). - Stefano Spezia, Nov 20 2019
a(n) = A004767(2*n), for n >= 0. See also A004767(2*n+1) = A004771(n). - Wolfdieter Lang, Feb 03 2022

A191667 Dispersion of A016813 (4k+1, k>1), by antidiagonals.

Original entry on oeis.org

1, 5, 2, 21, 9, 3, 85, 37, 13, 4, 341, 149, 53, 17, 6, 1365, 597, 213, 69, 25, 7, 5461, 2389, 853, 277, 101, 29, 8, 21845, 9557, 3413, 1109, 405, 117, 33, 10, 87381, 38229, 13653, 4437, 1621, 469, 133, 41, 11, 349525, 152917, 54613, 17749, 6485, 1877, 533
Offset: 1

Views

Author

Clark Kimberling, Jun 11 2011

Keywords

Comments

For a background discussion of dispersions, see A191426.
...
Each of the sequences (4n, n>2), (4n+1, n>0), (3n+2, n>=0), generates a dispersion. Each complement (beginning with its first term >1) also generates a dispersion. The six sequences and dispersions are listed here:
...
A191452=dispersion of A008586 (4k, k>=1)
A191667=dispersion of A016813 (4k+1, k>=1)
A191668=dispersion of A016825 (4k+2, k>=0)
A191669=dispersion of A004767 (4k+3, k>=0)
A191670=dispersion of A042968 (1 or 2 or 3 mod 4 and >=2)
A191671=dispersion of A004772 (0 or 1 or 3 mod 4 and >=2)
A191672=dispersion of A004773 (0 or 1 or 2 mod 4 and >=2)
A191673=dispersion of A004773 (0 or 2 or 3 mod 4 and >=2)
...
EXCEPT for at most 2 initial terms (so that column 1 always starts with 1):
A191452 has 1st col A042968, all else A008486
A191667 has 1st col A004772, all else A016813
A191668 has 1st col A042965, all else A016825
A191669 has 1st col A004773, all else A004767
A191670 has 1st col A008486, all else A042968
A191671 has 1st col A016813, all else A004772
A191672 has 1st col A016825, all else A042965
A191673 has 1st col A004767, all else A004773
...
Regarding the dispersions A191670-A191673, there is a formula for sequences of the type "(a or b or c mod m)", (as in the Mathematica program below):
If f(n)=(n mod 3), then (a,b,c,a,b,c,a,b,c,...) is given by a*f(n+2)+b*f(n+1)+c*f(n), so that "(a or b or c mod m)" is given by a*f(n+2)+b*f(n+1)+c*f(n)+m*floor((n-1)/3)), for n>=1.

Examples

			Northwest corner:
1....5....21....85....341
2....9....37....149...597
3....13...53....213...853
4....17...69....277...1109
6....25...101...405...1621
		

Crossrefs

Programs

  • Mathematica
    (* Program generates the dispersion array T of the increasing sequence f[n] *)
    r = 40; r1 = 12;  c = 40; c1 = 12;
    f[n_] := 4*n+1
    Table[f[n], {n, 1, 30}]  (* A016813 *)
    mex[list_] := NestWhile[#1 + 1 &, 1, Union[list][[#1]] <= #1 &, 1, Length[Union[list]]]
    rows = {NestList[f, 1, c]};
    Do[rows = Append[rows, NestList[f, mex[Flatten[rows]], r]], {r}];
    t[i_, j_] := rows[[i, j]];
    TableForm[Table[t[i, j], {i, 1, 10}, {j, 1, 10}]] (* A191667 *)
    Flatten[Table[t[k, n - k + 1], {n, 1, c1}, {k, 1, n}]] (* A191667  *)

A042964 Numbers that are congruent to 2 or 3 mod 4.

Original entry on oeis.org

2, 3, 6, 7, 10, 11, 14, 15, 18, 19, 22, 23, 26, 27, 30, 31, 34, 35, 38, 39, 42, 43, 46, 47, 50, 51, 54, 55, 58, 59, 62, 63, 66, 67, 70, 71, 74, 75, 78, 79, 82, 83, 86, 87, 90, 91, 94, 95, 98, 99, 102, 103, 106, 107, 110, 111, 114, 115, 118, 119, 122, 123, 126, 127
Offset: 1

Views

Author

Keywords

Comments

Also numbers m such that binomial(m+2, m) mod 2 = 0. - Hieronymus Fischer, Oct 20 2007
Also numbers m such that floor(1+(m/2)) mod 2 = 0. - Hieronymus Fischer, Oct 20 2007
Partial sums of the sequence 2, 1, 3, 1, 3, 1, 3, 1, 3, 1, ... which has period 2. - Hieronymus Fischer, Oct 20 2007
In groups of four add and divide by two the odd and even numbers. - George E. Antoniou, Dec 12 2001
From Jeremy Gardiner, Jan 22 2006: (Start)
Comments on the "mystery calculator". There are 6 cards.
Card 0: 1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, ... (A005408 sequence).
Card 1: 2, 3, 6, 7, 10, 11, 14, 15, 18, 19, 22, 23, 26, 27, 30, 31, 34, 35, 38, 39, ... (this sequence).
Card 2: 4, 5, 6, 7, 12, 13, 14, 15, 20, 21, 22, 23, 28, 29, 30, 31, 36, 37, 38, 39, ... (A047566).
Card 3: 8, 9, 10, 11, 12, 13, 14, 15, 24, 25, 26, 27, 28, 29, 30, 31, 40, 41, 42, ... (A115419).
Card 4: 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 48, 49, 50, ... (A115420).
Card 5: 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, ... (A115421).
The trick: You secretly select a number between 1 and 63 from one of the cards. You indicate to me the cards on which that number appears; I tell you the number you selected!
The solution: I add together the first term from each of the indicated cards. The total equals the selected number. The numbers in each sequence all have a "1" in the same position in their binary expansion. Example: You indicate cards 1, 3 and 5. Your selected number is 2 + 8 + 32 = 42.
Numbers having a 1 in position 1 of their binary expansion. One of the mystery calculator sequences: A005408, A042964, A047566, A115419, A115420, A115421. (End)
Complement of A042948. - Reinhard Zumkeller, Oct 03 2008
Also the 2nd Witt transform of A040000 [Moree]. - R. J. Mathar, Nov 08 2008
In general, sequences of numbers congruent to {a,a+i} mod k will have a closed form of (k-2*i)*(2*n-1+(-1)^n)/4+i*n+a, from offset 0. - Gary Detlefs, Oct 29 2013
Union of A004767 and A016825; Fixed points of A098180. - Wesley Ivan Hurt, Jan 14 2014, Oct 13 2015

Crossrefs

Programs

  • Magma
    [2*n+((-1)^(n-1)-1)/2 : n in [1..100]]; // Wesley Ivan Hurt, Oct 13 2015
    
  • Magma
    [n: n in [1..150] | n mod 4 in [2, 3]]; // Vincenzo Librandi, Oct 13 2015
    
  • Maple
    A042964:=n->2*n+((-1)^(n-1)-1)/2; seq(A042964(n), n=1..100); # Wesley Ivan Hurt, Jan 07 2014
  • Mathematica
    Flatten[Table[4n + {2, 3}, {n, 0, 31}]] (* Alonso del Arte, Feb 07 2013 *)
    Select[Range[200],MemberQ[{2,3},Mod[#,4]]&] (* or *) LinearRecurrence[ {1,1,-1},{2,3,6},90] (* Harvey P. Dale, Nov 28 2018 *)
  • PARI
    a(n)=2*n+2-n%2
    
  • PARI
    Vec((2+x+x^2)/((1-x)*(1-x^2)) + O(x^100)) \\ Altug Alkan, Oct 13 2015

Formula

a(n) = A047406(n)/2.
From Michael Somos, Jan 12 2000: (Start)
G.f.: x*(2+x+x^2)/((1-x)*(1-x^2)).
a(n) = a(n-1) + 2 + (-1)^n. (End)
a(n) = 2n if n is odd, otherwise n = 2n - 1. - Amarnath Murthy, Oct 16 2003
a(n) = (3 + (-1)^(n-1))/2 + 2*(n-1) = 2n + 2 - (n mod 2). - Hieronymus Fischer, Oct 20 2007
A133872(a(n)) = 0. - Reinhard Zumkeller, Oct 03 2008
a(n) = 4*n - a(n-1) - 3 (with a(1) = 2). - Vincenzo Librandi, Nov 17 2010
a(n) = 2*n + ((-1)^(n-1) - 1)/2. - Gary Detlefs, Oct 29 2013
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi/8 - log(2)/4. - Amiram Eldar, Dec 05 2021
E.g.f.: 1 + ((4*x - 1)*exp(x) - exp(-x))/2. - David Lovler, Aug 08 2022

Extensions

Edited by N. J. A. Sloane, Jun 30 2008 at the suggestion of R. J. Mathar
Corrected by Jaroslav Krizek, Dec 18 2009

A091067 Numbers whose odd part is of the form 4k+3.

Original entry on oeis.org

3, 6, 7, 11, 12, 14, 15, 19, 22, 23, 24, 27, 28, 30, 31, 35, 38, 39, 43, 44, 46, 47, 48, 51, 54, 55, 56, 59, 60, 62, 63, 67, 70, 71, 75, 76, 78, 79, 83, 86, 87, 88, 91, 92, 94, 95, 96, 99, 102, 103, 107, 108, 110, 111, 112, 115, 118, 119, 120, 123, 124, 126, 127, 131
Offset: 1

Views

Author

Ralf Stephan, Feb 22 2004

Keywords

Comments

Either of form 2*a(m) or 4k+3, k >= 0, 0 < m < n.
A000265(a(n)) is an element of A004767.
a(n) such that A038189(a(n)) = 1.
Numbers n such that Kronecker(-n, m) = Kronecker(m, n) for all m. - Michael Somos, Sep 22 2005
From Antti Karttunen, Feb 20-21 2015: (Start)
Gives all n for which A005811(n) - A005811(n-1) = -1, from which follows that a(n) = the least k such that A255070(k) = n.
Gives the positions of even terms in A003602. (End)
Indices of negative terms in A164677. - M. F. Hasler, Aug 06 2015
Indices of the 0's in A014577. - Gabriele Fici, Jun 02 2016
Also indices of -1 in A034947. - Jianing Song, Apr 24 2021
Conjecture: alternate definition of same sequence is that a(1)=3 and a(n) is the smallest number > a(n-1) so that no number that is the sum of at most 2 terms in this sequence is a power of 2. - J. Lowell, Jan 20 2024
The asymptotic density of this sequence is 1/2. - Amiram Eldar, Aug 31 2024

Crossrefs

Essentially one less than A060833.
Characteristic function: A038189.
Complement of A091072.
First differences are in A106836 (from its second term onward).
Sequence A246590 gives the even terms.
Gives the positions of records (after zero) for A255070 (equally, the position of the first n there).
Cf. A106837 (gives n such that both n and n+1 are terms of this sequence).
Cf. A098502 (gives n such that both n and n+2 are, but n+1 is not in this sequence).

Programs

  • Haskell
    import Data.List (elemIndices)
    a091067 n = a091067_list !! (n-1)
    a091067_list = map (+ 1) $ elemIndices 1 a014707_list
    -- Reinhard Zumkeller, Sep 28 2011
    (Scheme, with Antti Karttunen's IntSeq-library, two versions)
    (define A091067 (MATCHING-POS 1 1 (COMPOSE even? A003602)))
    (define A091067 (NONZERO-POS 1 0 A038189))
    ;; Antti Karttunen, Feb 20 2015
  • Mathematica
    Select[Range[150], Mod[# / 2^IntegerExponent[#, 2], 4] == 3 &] (* Amiram Eldar, Aug 31 2024 *)
  • PARI
    for(n=1,200,if(((n/2^valuation(n,2)-1)/2)%2,print1(n",")))
    
  • PARI
    {a(n) = local(m, c); if( n<1, 0, c=0; m=1; while( cMichael Somos, Sep 22 2005 */
    
  • PARI
    is_A091067(n)=bittest(n,valuation(n,2)+1) \\ M. F. Hasler, Aug 06 2015
    
  • PARI
    a(n) = my(t=1); n<<=1; forstep(i=logint(n,2),0,-1, if(bittest(n,i)==t, n++;t=!t)); n; \\ Kevin Ryde, Mar 21 2021
    

Formula

a(n) = A060833(n+1) - 1. [See N. Sato's Feb 12 2013 comment in A060833.]
Other identities. For all n >= 1 it holds that:
A014707(a(n) + 1) = 1. - Reinhard Zumkeller, Sep 28 2011
A055975(a(n)) < 0. - Reinhard Zumkeller, Apr 28 2012
From Antti Karttunen, Feb 20-21 2015: (Start)
a(n) = A246590(n)/2.
A255070(a(n)) = n, or equally, A236840(a(n)) = 2n.
a(n) = 1 + A255068(n-1). (End)

A017137 a(n) = 8*n + 6.

Original entry on oeis.org

6, 14, 22, 30, 38, 46, 54, 62, 70, 78, 86, 94, 102, 110, 118, 126, 134, 142, 150, 158, 166, 174, 182, 190, 198, 206, 214, 222, 230, 238, 246, 254, 262, 270, 278, 286, 294, 302, 310, 318, 326, 334, 342, 350, 358, 366, 374, 382, 390, 398, 406, 414, 422, 430
Offset: 0

Views

Author

N. J. A. Sloane, Dec 11 1996

Keywords

Comments

First differences of A002943. - Aaron David Fairbanks, May 13 2014

Examples

			G.f. = 6 + 14*x + 22*x^2 + 30*x^3 + 38*x^4 + 46*x^5 + 54*x^6 + 62*x^7 + ...
		

Crossrefs

Programs

Formula

a(n) = 2*A004767(n) = A000290(A017245(n)) - A156676(n+1). - Reinhard Zumkeller, Jul 13 2010
a(n) = 2*a(n-1) - a(n-2). - Vincenzo Librandi, Jun 07 2011
A089911(3*a(n)) = 4. - Reinhard Zumkeller, Jul 05 2013
From Michael Somos, May 15 2014: (Start)
G.f.: (6 + 2*x)/(1 - x)^2.
E.g.f.: (6 + 8*x)*exp(x). (End)
Sum_{n>=0} (-1)^n/a(n) = (Pi + log(3-2*sqrt(2)))/(8*sqrt(2)). - Amiram Eldar, Dec 11 2021
a(n) = A016825(2*n+1). - Elmo R. Oliveira, Apr 12 2025

A004773 Numbers congruent to {0, 1, 2} mod 4: a(n) = floor(4*n/3).

Original entry on oeis.org

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

Views

Author

Keywords

Comments

The sequence b(n) = floor((4/3)*(n+2)) appears as an upper bound in Fijavz and Wood.
Binary expansion does not end in 11.
From Guenther Schrack, May 04 2023: (Start)
The sequence is the interleaving of the sequences A008586, A016813, A016825, in that order.
Let S(n) = a(n) + a(n+1) + a(n+2). Then floor(S(n)/3) = A042968(n+1), round(S(n)/3) = a(n+1), ceiling(S(n)/3) = A042965(n+2). (End)

Crossrefs

Cf. A177702 (first differences), A000969 (partial sums).
Cf. A032766, this sequence, A001068, A047226, A047368, A004777.
Cf. similar sequences with formula n+i*floor(n/3) listed in A281899.

Programs

  • Magma
    [n: n in [0..100] | n mod 4 in [0..2]]; // Vincenzo Librandi, Dec 23 2010
    
  • Maple
    seq(floor(n/3)+n,n=0..68); # Gary Detlefs, Mar 20 2010
  • Mathematica
    f[n_] := Floor[4 n/3]; Array[f, 69, 0] (* Robert G. Wilson v, Dec 24 2010 *)
    fQ[n_] := Mod[n, 4] != 3; Select[ Range[0, 90], fQ] (* Robert G. Wilson v, Dec 24 2010 *)
    a[0] = 0; a[n_] := a[n] = a[n - 1] + 2 - If[ Mod[a[n - 1], 4] < 2, 1, 0]; Array[a, 69, 0] (* Robert G. Wilson v, Dec 24 2010 *)
    CoefficientList[ Series[x (1 + x + 2 x^2)/((1 - x) (1 - x^3)), {x, 0, 68}], x] (* Robert G. Wilson v, Dec 24 2010 *)
  • PARI
    a(n)=4*n\3 \\ Charles R Greathouse IV, Sep 27 2012

Formula

G.f.: x*(1+x+2*x^2)/((1-x)*(1-x^3)).
a(0) = 0, a(n+1) = a(n) + a(n) mod 4 + 0^(a(n) mod 4). - Reinhard Zumkeller, Mar 23 2003
a(n) = A004396(n) + A004523(n); complement of A004767. - Reinhard Zumkeller, Aug 29 2005
a(n) = floor(n/3) + n. - Gary Detlefs, Mar 20 2010
a(n) = (12*n-3+3*cos(2*n*Pi/3)+sqrt(3)*sin(2*n*Pi/3))/9. - Wesley Ivan Hurt, Sep 30 2017
E.g.f.: (3*exp(x)*(4*x - 1) + exp(-x/2)*(3*cos((sqrt(3)*x)/2) + sqrt(3)*sin((sqrt(3)*x)/2)))/9. - Stefano Spezia, Jun 09 2021
Sum_{n>=1} (-1)^(n+1)/a(n) = (sqrt(2)-1)*Pi/8 + sqrt(2)*log(sqrt(2)+2)/4 + (2-sqrt(2))*log(2)/8. - Amiram Eldar, Dec 05 2021
From Guenther Schrack, May 04 2023: (Start)
a(n) = (12*n - 3 + w^(2*n)*(w + 2) - w^n*(w - 1))/9 where w = (-1 + sqrt(-3))/2.
a(n) = 2*floor(n/3) + floor((n+1)/3) + floor((n+2)/3).
a(n) = (4*n - n mod 3)/3.
a(n) = a(n-3) + 4.
a(n) = a(n-1) + a(n-3) - a(n-4).
a(n) = 4*A002264(n) + A010872(n).
a(n) = A042968(n+1) - 1.
(End)
Previous Showing 11-20 of 218 results. Next