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

A083097 a(n) = A083096(n)/6.

Original entry on oeis.org

0, 2, 5, 6, 14, 15, 18, 20, 41, 42, 45, 47, 54, 56, 59, 60, 122, 123, 126, 128, 135, 137, 140, 141, 162, 164, 167, 168, 176, 177, 180, 182, 365, 366, 369, 371, 378, 380, 383, 384, 405, 407, 410, 411, 419, 420, 423, 425, 486, 488, 491, 492, 500
Offset: 1

Views

Author

Benoit Cloitre, Apr 22 2003

Keywords

Comments

Is this the same as A083095? - Andrew S. Plewe, May 30 2007
Apparently (2*a(n)) mod 3 = A010060(n-1), the Thue-Morse sequence.

Crossrefs

Programs

A005836 Numbers whose base-3 representation contains no 2.

Original entry on oeis.org

0, 1, 3, 4, 9, 10, 12, 13, 27, 28, 30, 31, 36, 37, 39, 40, 81, 82, 84, 85, 90, 91, 93, 94, 108, 109, 111, 112, 117, 118, 120, 121, 243, 244, 246, 247, 252, 253, 255, 256, 270, 271, 273, 274, 279, 280, 282, 283, 324, 325, 327, 328, 333, 334, 336, 337, 351, 352
Offset: 1

Views

Author

Keywords

Comments

3 does not divide binomial(2s, s) if and only if s is a member of this sequence, where binomial(2s, s) = A000984(s) are the central binomial coefficients.
This is the lexicographically earliest increasing sequence of nonnegative numbers that contains no arithmetic progression of length 3. - Robert Craigen (craigenr(AT)cc.umanitoba.ca), Jan 29 2001
In the notation of A185256 this is the Stanley Sequence S(0,1). - N. J. A. Sloane, Mar 19 2010
Complement of A074940. - Reinhard Zumkeller, Mar 23 2003
Sums of distinct powers of 3. - Ralf Stephan, Apr 27 2003
Numbers n such that central trinomial coefficient A002426(n) == 1 (mod 3). - Emeric Deutsch and Bruce E. Sagan, Dec 04 2003
A039966(a(n)+1) = 1; A104406(n) = number of terms <= n.
Subsequence of A125292; A125291(a(n)) = 1 for n>1. - Reinhard Zumkeller, Nov 26 2006
Also final value of n - 1 written in base 2 and then read in base 3 and with finally the result translated in base 10. - Philippe LALLOUET (philip.lallouet(AT)wanadoo.fr), Jun 23 2007
a(n) modulo 2 is the Thue-Morse sequence A010060. - Dennis Tseng, Jul 16 2009
Also numbers such that the balanced ternary representation is the same as the base 3 representation. - Alonso del Arte, Feb 25 2011
Fixed point of the morphism: 0 -> 01; 1 -> 34; 2 -> 67; ...; n -> (3n)(3n+1), starting from a(1) = 0. - Philippe Deléham, Oct 22 2011
It appears that this sequence lists the values of n which satisfy the condition sum(binomial(n, k)^(2*j), k = 0..n) mod 3 <> 0, for any j, with offset 0. See Maple code. - Gary Detlefs, Nov 28 2011
Also, it follows from the above comment by Philippe Lallouet that the sequence must be generated by the rules: a(1) = 0, and if m is in the sequence then so are 3*m and 3*m + 1. - L. Edson Jeffery, Nov 20 2015
Add 1 to each term and we get A003278. - N. J. A. Sloane, Dec 01 2019

Examples

			12 is a term because 12 = 110_3.
This sequence regarded as a triangle with rows of lengths 1, 1, 2, 4, 8, 16, ...:
   0
   1
   3,  4
   9, 10, 12, 13
  27, 28, 30, 31, 36, 37, 39, 40
  81, 82, 84, 85, 90, 91, 93, 94, 108, 109, 111, 112, 117, 118, 120, 121
... - _Philippe Deléham_, Jun 06 2015
		

References

  • Richard K. Guy, Unsolved Problems in Number Theory, 3rd Edition, Springer, 2004, Section E10, pp. 317-323.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A039966 (characteristic function).
For generating functions Product_{k>=0} (1+a*x^(b^k)) for the following values of (a,b) see: (1,2) A000012 and A000027, (1,3) A039966 and A005836, (1,4) A151666 and A000695, (1,5) A151667 and A033042, (2,2) A001316, (2,3) A151668, (2,4) A151669, (2,5) A151670, (3,2) A048883, (3,3) A117940, (3,4) A151665, (3,5) A151671, (4,2) A102376, (4,3) A151672, (4,4) A151673, (4,5) A151674.
Row 3 of array A104257.
Summary of increasing sequences avoiding arithmetic progressions of specified lengths (the second of each pair is obtained by adding 1 to the first):
3-term AP: A005836 (>=0), A003278 (>0);
4-term AP: A005839 (>=0), A005837 (>0);
5-term AP: A020654 (>=0), A020655 (>0);
6-term AP: A020656 (>=0), A005838 (>0);
7-term AP: A020657 (>=0), A020658 (>0);
8-term AP: A020659 (>=0), A020660 (>0);
9-term AP: A020661 (>=0), A020662 (>0);
10-term AP: A020663 (>=0), A020664 (>0).
See also A000452.

Programs

  • Haskell
    a005836 n = a005836_list !! (n-1)
    a005836_list = filter ((== 1) . a039966) [0..]
    -- Reinhard Zumkeller, Jun 09 2012, Sep 29 2011
    
  • Julia
    function a(n)
        m, r, b = n, 0, 1
        while m > 0
            m, q = divrem(m, 2)
            r += b * q
            b *= 3
        end
    r end; [a(n) for n in 0:57] |> println # Peter Luschny, Jan 03 2021
  • Maple
    t := (j, n) -> add(binomial(n,k)^j, k=0..n):
    for i from 1 to 400 do
        if(t(4,i) mod 3 <>0) then print(i) fi
    od; # Gary Detlefs, Nov 28 2011
    # alternative Maple program:
    a:= proc(n) option remember: local k, m:
    if n=1 then 0 elif n=2 then 1 elif n>2 then k:=floor(log[2](n-1)): m:=n-2^k: procname(m)+3^k: fi: end proc:
    seq(a(n), n=1.. 20); # Paul Weisenhorn, Mar 22 2020
    # third Maple program:
    a:= n-> `if`(n=1, 0, irem(n-1, 2, 'q')+3*a(q+1)):
    seq(a(n), n=1..100);  # Alois P. Heinz, Jan 26 2022
  • Mathematica
    Table[FromDigits[IntegerDigits[k, 2], 3], {k, 60}]
    Select[Range[0, 400], DigitCount[#, 3, 2] == 0 &] (* Harvey P. Dale, Jan 04 2012 *)
    Join[{0}, Accumulate[Table[(3^IntegerExponent[n, 2] + 1)/2, {n, 57}]]] (* IWABUCHI Yu(u)ki, Aug 01 2012 *)
    FromDigits[#,3]&/@Tuples[{0,1},7] (* Harvey P. Dale, May 10 2019 *)
  • PARI
    A=vector(100);for(n=2,#A,A[n]=if(n%2,3*A[n\2+1],A[n-1]+1));A \\ Charles R Greathouse IV, Jul 24 2012
    
  • PARI
    is(n)=while(n,if(n%3>1,return(0));n\=3);1 \\ Charles R Greathouse IV, Mar 07 2013
    
  • PARI
    a(n) = fromdigits(binary(n-1),3);  \\ Gheorghe Coserea, Jun 15 2018
    
  • Python
    def A005836(n):
        return int(format(n-1,'b'),3) # Chai Wah Wu, Jan 04 2015
    

Formula

a(n) = A005823(n)/2 = A003278(n)-1 = A033159(n)-2 = A033162(n)-3.
Numbers n such that the coefficient of x^n is > 0 in prod (k >= 0, 1 + x^(3^k)). - Benoit Cloitre, Jul 29 2003
a(n+1) = Sum_{k=0..m} b(k)* 3^k and n = Sum( b(k)* 2^k ).
a(2n+1) = 3a(n+1), a(2n+2) = a(2n+1) + 1, a(0) = 0.
a(n+1) = 3*a(floor(n/2)) + n - 2*floor(n/2). - Ralf Stephan, Apr 27 2003
G.f.: (x/(1-x)) * Sum_{k>=0} 3^k*x^2^k/(1+x^2^k). - Ralf Stephan, Apr 27 2003
a(n) = Sum_{k = 1..n-1} (1 + 3^A007814(k)) / 2. - Philippe Deléham, Jul 09 2005
From Reinhard Zumkeller, Mar 02 2008: (Start)
A081603(a(n)) = 0.
If the offset were changed to zero, then: a(0) = 0, a(n+1) = f(a(n)+1, a(n)+1) where f(x, y) = if x < 3 and x <> 2 then y else if x mod 3 = 2 then f(y+1, y+1) else f(floor(x/3), y). (End)
With offset a(0) = 0: a(n) = Sum_{k>=0} A030308(n,k)*3^k. - Philippe Deléham, Oct 15 2011
a(2^n) = A003462(n). - Philippe Deléham, Jun 06 2015
We have liminf_{n->infinity} a(n)/n^(log(3)/log(2)) = 1/2 and limsup_{n->infinity} a(n)/n^(log(3)/log(2)) = 1. - Gheorghe Coserea, Sep 13 2015
a(2^k+m) = a(m) + 3^k with 1 <= m <= 2^k and 1 <= k, a(1)=0, a(2)=1. - Paul Weisenhorn, Mar 22 2020
Sum_{n>=2} 1/a(n) = 2.682853110966175430853916904584699374821677091415714815171756609672281184705... (calculated using Baillie and Schmelzer's kempnerSums.nb, see Links). - Amiram Eldar, Feb 12 2022
A065361(a(n)) = n-1. - Rémy Sigrist, Feb 06 2023
a(n) ≍ n^k, where k = log 3/log 2 = 1.5849625007. (I believe the constant varies from 1/2 to 1.) - Charles R Greathouse IV, Mar 29 2024

Extensions

Offset corrected by N. J. A. Sloane, Mar 02 2008
Edited by the Associate Editors of the OEIS, Apr 07 2009

A066796 a(n) = Sum_{i=1..n} binomial(2*i,i).

Original entry on oeis.org

2, 8, 28, 98, 350, 1274, 4706, 17576, 66196, 250952, 956384, 3660540, 14061140, 54177740, 209295260, 810375650, 3143981870, 12219117170, 47564380970, 185410909790, 723668784230, 2827767747950, 11061198475550, 43308802158650
Offset: 1

Views

Author

Benoit Cloitre, Jan 18 2002

Keywords

Comments

Comments from Alexander Adamchuk, Jul 02 2006: (Start)
Every a(n) is divisible by prime 2, a(n)/2 = A079309(n).
a(n) is divisible by prime 3 only for n=12,30,36,84,90,108,120,... A083096.
a(p) is divisible by p^2 for primes p=5,11,17,23,29,41,47,... Primes of form 6n-1. A007528.
a(p-1) is divisible by p^2 for primes p=7,13,19,31,37,43,... Primes of form 6n+1. A002476.
Every a(n) from a((p-1)/2) to a(p-1) is divisible by prime p for p=7,13,19,31,37,43,... Primes of form 6n+1. A002476.
Every a(n) from a((p^2-1)/2) to a(p^2-1) is divisible by prime p>3.
a(p^2-1), a(p^2-2) and a(p^2-3) are divisible by p^2 for prime p>3.
a(p^2-4) is divisible by p^2 for prime p>5.
a(p^2-5) is divisible by p^2 for prime p>7.
a(p^2-6) is divisible by p^2 for prime p>7.
a(p^2-7) is divisible by p^2 for prime p>11.
a(p^2-8) is divisible by p^2 for prime p>13.
a(p^3) is divisible by p^2 for prime 2 and prime p=5,11,... Primes of form 6n-1. A007528.
a(p^3-1) is divisible by p^2 for prime p=7,13,... Primes of form 6n+1. A002476.
a(p^4-1) is divisible by p^2 for prime p>3. (End)
Mod[ a(3^k), 9 ] = 1 for integer k>0. Smallest number k such that 2^n divides a(k) is k(n) = {1,2,2,11,11,46,46,707,707,707,...}. Smallest number k such that 3^n divides a(k) is k(n) = {12,822,2466,...}. a(2(p-1)/3) is divisible by p^2 for prime p = {7,13,19,31,37,43,61,...} = A002476 Primes of form 6n+1. Every a(n) from a(p^2-(p+1)/2) to a(p^2-1) is divisible by p^2 for prime p>3. Every a(n) from a((4p+3)(p-1)/6) to a((2p+3)(p-1)/3) is divisible by p^2 for prime p = {7,13,19,31,37,43,61,...} = A002476 Primes of form 6n+1. - Alexander Adamchuk, Jan 04 2007

Crossrefs

Essentially the same as A079309 and A054114.
Equals A006134 - 1.

Programs

  • Mathematica
    Table[Sum[(2k)!/(k!)^2,{k,1,n}],{n,1,50}] (* Alexander Adamchuk, Jul 02 2006 *)
    Table[Sum[Binomial[2k,k],{k,1,n}],{n,1,30}] (* Alexander Adamchuk, Jan 04 2007 *)
  • PARI
    { a=0; for (n=1, 200, write("b066796.txt", n, " ", a+=binomial(2*n, n)) ) } \\ Harry J. Smith, Mar 27 2010
    
  • PARI
    a(n) = sum(i=1, n, binomial(2*i,i)); \\ Michel Marcus, Jan 04 2016

Formula

a(n) = A006134(n) - 1; generating function: (sqrt(1-4*x)-1)/(sqrt(1-4*x)*(x-1)) - Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Feb 11 2003, corrected by Vaclav Kotesovec, Nov 06 2012
a(n) = Sum_{k=1..n}(2k)!/(k!)^2. - Alexander Adamchuk, Jul 02 2006
a(n) = Sum_{k=1..n}binomial(2k,k). - Alexander Adamchuk, Jan 04 2007
a(n) ~ 2^(2*n+2)/(3*sqrt(Pi*n)). - Vaclav Kotesovec, Nov 06 2012

A081601 Numbers m such that 3 does not divide Sum_{k=0..m} binomial(2k,k) = A006134(m).

Original entry on oeis.org

0, 3, 9, 12, 27, 30, 36, 39, 81, 84, 90, 93, 108, 111, 117, 120, 243, 246, 252, 255, 270, 273, 279, 282, 324, 327, 333, 336, 351, 354, 360, 363, 729, 732, 738, 741, 756, 759, 765, 768, 810, 813, 819, 822, 837, 840, 846, 849, 972, 975, 981, 984, 999, 1002, 1008, 1011
Offset: 1

Views

Author

Benoit Cloitre, Apr 22 2003

Keywords

Comments

Apparently a(n)/3 mod 2 = A010060(n-1), the Thue-Morse sequence.
a(n+1) is the smallest number with exactly n+1 partitions into distinct powers of 2 or of 3: A131996(a(n+1)) = n+1 and A131996(m) < n+1 for m < a(n+1). - Reinhard Zumkeller, Aug 06 2007

Examples

			For n=0, A006134(0) = 1, hence 0 is a term.
		

Crossrefs

Equals A089118(n-2) + 1, n > 1.

Programs

  • Mathematica
    Select[Range[0, 1020], Mod[Sum[Binomial[2 k, k], {k, 0, #}], 3] != 0 &] (* Michael De Vlieger, Nov 28 2015 *)
  • PARI
    for(n=0, 1e3, if(sum(k=0, n, binomial(2*k, k)) % 3 > 0, print1(n,", "))) \\ Altug Alkan, Nov 26 2015

Formula

Apparently a(n) = 3*A005836(n).
G.f.: (x/(1 - x))*Sum_{k>=0} 3^(k+1)*x^(2^k)/(1 + x^(2^k)) (conjecture). - Ilya Gutkovskiy, Jul 23 2017

Extensions

Zero prepended to the sequence and formulas modified accordingly by L. Edson Jeffery, Nov 25 2015

A122485 Values of A083097(k) such that A083097(k) = A083097(k+1) - 1.

Original entry on oeis.org

5, 14, 41, 59, 122, 140, 167, 176, 365, 383, 410, 419, 491, 500, 527, 545, 1094, 1112, 1139, 1148, 1220, 1229, 1256, 1274, 1463, 1472, 1499, 1517, 1580, 1598, 1625, 1634, 3281, 3299, 3326, 3335, 3407, 3416, 3443, 3461, 3650, 3659, 3686, 3704, 3767, 3785, 3812
Offset: 1

Views

Author

Alexander Adamchuk, Sep 15 2006

Keywords

Comments

A083097(n) = A083095(n) = A083096(n)/6 = A083094(n)/4, where A083096 are the Numbers k such that 3 divides Sum_{j=1..k} C(2*j,j) = A066796(k).
All terms are of the form 9*m + 5 and belong to A017221 with m = {0, 1, 4, 6, 13, 15, 18, 19, 40, 42, ...}.
Corresponding numbers m such that a(m) = A083097(m) are A129771 (evil odd numbers).

Examples

			A083097 begins {0, 2, 5, 6, 14, 15, 18, 20, 41, 42, 45, 47, 54, 56, 59, 60, ...}.
So a(1) = 5 because 5 = A083097(3) = A083097(3+1) - 1.
a(2) = 14 because 14 = A083097(5) = A083097(5+1) - 1.
		

Crossrefs

Formula

a(n) = A083097(A129771(n)).

Extensions

More terms from R. J. Mathar, Jan 17 2008
More terms from Jinyuan Wang, Jan 22 2022
Edited by Michel Marcus, Jan 22 2022

A167912 a(n) = (1/(3^n)^2) * Sum_{k=0..(3^n-1)} binomial(2k,k).

Original entry on oeis.org

1, 217, 913083596083, 18744974860247264575032720770000376335095039
Offset: 1

Views

Author

Alexander Adamchuk, Nov 15 2009

Keywords

Comments

Note that a(n) mod 27 = a(n) mod 9 = a(n) mod 3 = 1.
The Maple program yields the first seven terms; easily adjustable for obtaining more terms. However, a(4) has 44 digits, a(5) has 140 digits, a(6) has 432 digits and a(7) has 1308 digits. - Emeric Deutsch, Nov 22 2009

Crossrefs

Programs

  • Maple
    a := proc (n) options operator, arrow: (sum(binomial(2*k, k), k = 0 .. 3^n-1))/3^(2*n) end proc: seq(a(n), n = 1 .. 7); # Emeric Deutsch, Nov 22 2009
  • Mathematica
    Table[(1/3^n)^2 * Sum[Binomial[2 k, k], {k, 0, 3^n - 1}], {n, 1, 5}] (* G. C. Greubel, Jul 01 2016 *)

Extensions

a(4) from Emeric Deutsch, Nov 22 2009

A086743 Numbers n such that the coefficient of x^n equals 0 in Product_{k>=1} (1 - x^(3^k)).

Original entry on oeis.org

1, 2, 4, 5, 6, 7, 8, 10, 11, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 28, 29, 31, 32, 33, 34, 35, 37, 38, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79
Offset: 1

Views

Author

Benoit Cloitre, Jul 29 2003

Keywords

Crossrefs

A181990 a(n) = Sum_{0 <= k <= m < p} (binomial(m, k)^(p-1))/p, where p is the n-th prime.

Original entry on oeis.org

3, 399, 12708885, 124515078454872901983423, 39212583445587381894247266262023061, 43487633454143579523135045521112077473364484383507327790688372131, 157851796824901989964381293031623545741924564754192453966085327785455257503133278729
Offset: 2

Views

Author

Alexander Adamchuk, Apr 04 2012

Keywords

Comments

a(n) is a sum of all elements in the first p rows of Pascal's triangle each raised to the (p-1) power and divided by p, where p is the n-th prime.
For p = 3 and 7 (and their powers like 3, 9, 27, ... and 7, 49, ...) the sums of all elements in n = p^k top rows of Pascal's triangle each raised to the (n-1) = (p^k-1) power are divisible by n^2 = p^(2k) for all k > 0.

Crossrefs

Programs

  • Mathematica
    Table[(Sum[Binomial[m, k]^(Prime[n] - 1), {m, 0, Prime[n] - 1}, {k, 0, m}])/Prime[n], {n, 2, 10}]
  • PARI
    a(n) = my(p=prime(n)); sum(m=0, p-1, sum(k=0, m, binomial(m,k)^(p-1))/p); \\ Michel Marcus, Dec 03 2018
Showing 1-8 of 8 results.