[go: up one dir, main page]

login
Search: a053404 -id:a053404
     Sort: relevance | references | number | modified | created      Format: long | short | data
a(2n) = 2*a(2n-1), a(2n+1) = 2*a(2n)+1 (also a(n) is the n-th number without consecutive equal binary digits).
+10
294
0, 1, 2, 5, 10, 21, 42, 85, 170, 341, 682, 1365, 2730, 5461, 10922, 21845, 43690, 87381, 174762, 349525, 699050, 1398101, 2796202, 5592405, 11184810, 22369621, 44739242, 89478485, 178956970, 357913941, 715827882, 1431655765, 2863311530, 5726623061, 11453246122
OFFSET
0,3
COMMENTS
Might be called the "Lichtenberg sequence" after Georg Christoph Lichtenberg, who discussed it in 1769 in connection with the Chinese Rings puzzle (baguenaudier). - Andreas M. Hinz, Feb 15 2017
Number of steps to change from a binary string of n 0's to n 1's using a Gray code. - Jon Stadler (jstadler(AT)coastal.edu)
Popular puzzles such as Spin-Out and The Brain Puzzler are based on the Gray binary system and require a(n) steps to complete for some number n.
Conjecture: {a(n)} also gives all j for which A048702(j) = A000217(j); i.e., if we take the a(n)-th triangular number (a(n)^2 + a(n))/2 and multiply it by 3, we get a(n)-th even-length binary palindrome A048701(a(n)) concatenated from a(n) and its reverse. E.g., a(4) = 10, which is 1010 in binary; the tenth triangular number is 55, and 55*3 = 165 = 10100101 in binary. - Antti Karttunen, circa 1999. (This has been now proved by Paul K. Stockmeyer in his arXiv:1608.08245 paper.) - Antti Karttunen, Aug 31 2016
Number of ways to tie a tie of n or fewer half turns, excluding mirror images. Also number of walks of length n or less on a triangular lattice with the following restrictions; given l, r and c as the lattice axes. 1. All steps are taken in the positive axis direction. 2. No two consecutive steps are taken on the same axis. 3. All walks begin with l. 4. All walks end with rlc or lrc. - Bill Blewett, Dec 21 2000
a(n) is the minimal number of vertices to be selected in a vertex-cover of the balanced tree B_n. - Sen-peng Eu, Jun 15 2002
A087117(a(n)) = A038374(a(n)) = 1 for n > 1; see also A090050. - Reinhard Zumkeller, Nov 20 2003
Intersection of A003754 and A003714; complement of A107907. - Reinhard Zumkeller, May 28 2005
Equivalently, numbers m whose binary representation is effectively, for some number k, both the lazy Fibonacci and the Zeckendorf representation of k (in which case k = A022290(m)). - Peter Munn, Oct 06 2022
a(n+1) gives row sums of Riordan array (1/(1-x), x(1+2x)). - Paul Barry, Jul 18 2005
Total number of initial 01's in all binary words of length n+1. Example: a(3) = 5 because the binary words of length 4 that start with 01 are (01)00, (01)(01), (01)10 and (01)11 and the total number of initial 01's is 5 (shown between parentheses). a(n) = Sum_{k >= 0} k*A119440(n+1, k). - Emeric Deutsch, May 19 2006
In Norway we call the 10-ring puzzle "strikketoy" or "knitwear" (see link). It takes 682 moves to free the two parts. - Hans Isdahl, Jan 07 2008
Equals A002450 and A020988 interlaced. - Zak Seidov, Feb 10 2008
For n > 1, let B_n = the complete binary tree with vertex set V where |V| = 2^n - 1. If VC is a minimum-size vertex cover of B_n, Sen-Peng Eu points out that a(n) = |VC|. It also follows that if IS = V\VC, a(n+1) = |IS|. - K.V.Iyer, Apr 13 2009
Starting with 1 and convolved with [1, 2, 2, 2, ...] = A000295. - Gary W. Adamson, Jun 02 2009
a(n) written in base 2 is sequence A056830(n). - Jaroslav Krizek, Aug 05 2009
This is the sequence A(0, 1; 1, 2; 1) of the family of sequences [a,b:c,d:k] considered by G. Detlefs, and treated as A(a,b;c,d;k) in the W. Lang link given below. - Wolfdieter Lang, Oct 18 2010
From Vladimir Shevelev, Jan 30 2012, Feb 13 2012: (Start)
1) Denote by {n, k} the number of permutations of 1, ..., n with the up-down index k (for definition, see comment in A203827). Then max_k{n, k} = {n, a(n)} = A000111(n).
2) a(n) is the minimal number > a(n-1) with the Hamming distance d_H(a(n-1), a(n)) = n. Thus this sequence is the Hamming analog of triangular numbers 0, 1, 3, 6, 10, ... (End)
From Hieronymus Fischer, Nov 22 2012: (Start)
Represented in binary form each term after the second one contains every previous term as a substring.
The terms a(2) = 2 and a(3) = 5 are the only primes. Proof: For even n we get a(n) = 2*(2^(2*n) - 1)/3, which shows that a(n) is even, too, and obviously a(n) > 2 for all even n > 2. For odd n we have a(n) = (2^(n+1) - 1)/3 = (2^((n+1)/2) - 1) * (2^((n+1)/2) + 1)/3. Evidently, at least one of these factors is divisible by 3, both are greater than 6, provided n > 3. Hence it follows that a(n) is composite for all odd n > 3.
Represented as a binary number, a(n+1) has exactly n prime substrings. Proof: Evidently, a(1) = 1_2 has zero and a(2) = 10_2 has 1 prime substring. Let n > 1. Written in binary, a(n+1) is 101010101...01 (if n + 1 is odd) and is 101010101...10 (if n + 1 is even) with n + 1 digits. Only the 2- and 3-digits substrings 10_2 (=2) and 101_2 (=5) are prime substrings. All the other substrings are nonprime since every substring is a previous term and all terms unequal to 2 and 5 are nonprime. For even n + 1, the number of prime substrings equal to 2 = 10_2 is (n+1)/2, and the number of prime substrings equal to 5 = 101_2 is (n-1)/2, makes a sum of n. For odd n + 1 we get n/2 for both, the number of 2's and 5's prime substrings, in any case, the sum is n.
(End)
Also the number of different 3-colorings for the vertices of all triangulated planar polygons on a base with n+2 vertices if the colors of the two base vertices are fixed. - Patrick Labarque, Feb 09 2013
A090079(a(n)) = a(n) and A090079(m) <> a(n) for m < a(n). - Reinhard Zumkeller, Feb 16 2013
a(n) is the number of length n binary words containing at least one 1 and ending in an even number (possibly zero) of 0's. a(3) = 5 because we have: 001, 011, 100, 101, 111. - Geoffrey Critzer, Dec 15 2013
a(n) is the number of permutations of length n+1 having exactly one descent such that the first element of the permutation is an even number. - Ran Pan, Apr 18 2015
a(n) is the sequence of the last row of the Hadamard matrix H(2^n) obtained via Sylvester's construction: H(2) = [1,1;1,-1], H(2^n) = H(2^(n-1))*H(2), where * is the Kronecker product. - William P. Orrick, Jun 28 2015
Conjectured record values of A264784: a(n) = A264784(A155051(n-1)). - Reinhard Zumkeller, Dec 04 2015. (This is proved by Paul K. Stockmeyer in his arXiv:1608.08245 paper.) - Antti Karttunen, Aug 31 2016
Decimal representation of the x-axis, from the origin to the right edge, of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 131", based on the 5-celled von Neumann neighborhood. See A279053 for references and links. - Robert Price, Dec 05 2016
For n > 4, a(n-2) is the second-largest number in row n of A127824. - Dmitry Kamenetsky, Feb 11 2017
Conjecture: a(n+1) is the number of compositions of n with two kinds of parts, n and n', where the order of the 1 and 1' does not matter. For n=2, a(3) = 5 compositions, enumerated as follows: 2; 2'; 1,1; 1',1 = 1',1; 1',1'. - Gregory L. Simay, Sep 02 2017
Conjecture proved by recognizing the appropriate g.f. is x/(1 - x)(1 - x)(1 - 2*x^2 - 2x^3 - ...) = x/(1 - 2*x - x^2 + 2x^3). - Gregory L. Simay, Sep 10 2017
a(n) = 2^(n-1) + 2^(n-3) + 2^(n-5) + ... a(2*k -1) = A002450(k) is the sum of the powers of 4. a(2*k) = 2*A002450(k). - Gregory L. Simay, Sep 27 2017
a(2*n) = n times the string [10] in binary representation, a(2*n+1) = n times the string [10] followed with [1] in binary representation. Example: a(7) = 85 = (1010101) in binary, a(8) = 170 = (10101010) in binary. - Ctibor O. Zizka, Nov 06 2018
Except for 0, these are the positive integers whose binary expansion has cuts-resistance 1. For the operation of shortening all runs by 1, cuts-resistance is the number of applications required to reach an empty word. Cuts-resistance 2 is A329862. - Gus Wiseman, Nov 27 2019
From Markus Sigg, Sep 14 2020: (Start)
Let s(k) be the length of the Collatz orbit of k, e.g. s(1) = 1, s(2) = 2, s(3) = 5. Then s(a(n)) = n+3 for n >= 3. Proof by induction: s(a(3)) = s(5) = 6 = 3+3. For odd n >= 5 we have s(a(n)) = s(4*a(n-2)+1) = s(12*a(n-2)+4)+1 = s(3*a(n-2)+1)+3 = s(a(n-2))+2 = (n-2)+3+2 = n+3, and for even n >= 4 this gives s(a(n)) = s(2*a(n-1)) = s(a(n-1))+1 = (n-1)+3+1 = n+3.
Conjecture: For n >= 3, a(n) is the second largest natural number whose Collatz orbit has length n+3. (End)
From Gary W. Adamson, May 14 2021: (Start)
With offset 1 the sequence equals the numbers of 1's from n = 1 to 3, 3 to 7, 7 to 15, ...; of A035263; as shown below:
..1 3 7 15...
..1 0 1 1 1 0 1 0 1 0 1 1 1 0 1...
..1.....2...........5......................10...; a(n) = Sum_(k=1..2n-1)A035263(k)
.....1...........2.......................5...; as to zeros.
..1's in the Tower of Hanoi game represent CW moves On disks in the pattern:
..0, 1, 2, 0, 1, 2, ... whereas even numbered disks move in the pattern:
..0, 2, 1, 0, 2, 1, ... (End)
Except for 0, numbers that are repunits in Gray-code representation (A014550). - Amiram Eldar, May 21 2021
From Gus Wiseman, Apr 20 2023: (Start)
Also the number of nonempty subsets of {1..n} with integer median, where the median of a multiset is the middle part in the odd-length case, and the average of the two middle parts in the even-length case. For example, the a(1) = 1 through a(4) = 10 subsets are:
{1} {1} {1} {1}
{2} {2} {2}
{3} {3}
{1,3} {4}
{1,2,3} {1,3}
{2,4}
{1,2,3}
{1,2,4}
{1,3,4}
{2,3,4}
The complement is counted by A005578.
For mean instead of median we have A051293, counting empty sets A327475.
For normal multisets we have A056450, strongly normal A361202.
For partitions we have A325347, strict A359907, complement A307683.
(End)
REFERENCES
Thomas Fink and Yong Mao, The 85 Ways to Tie a Tie, Broadway Books, New York (1999), p. 138.
Clifford A. Pickover, The Math Book, From Pythagoras to the 57th Dimension, 250 Milestones in the History of Mathematics, Sterling Publ., NY, 2009.
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..3300 (terms 0..300 from T. D. Noe)
Thomas Baruchel, Properties of the cumulated deficient binary digit sum, arXiv:1908.02250 [math.NT], 2019.
Sergei L. Bezrukov et al., The congestion of n-cube layout on a rectangular grid, Discrete Mathematics 213.1-3 (2000): 13-19. See Theorem 1.
F. Chapoton and S. Giraudo, Enveloping operads and bicoloured noncrossing configurations, arXiv:1310.4521 [math.CO], 2013. Is the sequence in Table 2 this sequence? - N. J. A. Sloane, Jan 04 2014. (Yes, it is. See Stockmeyer's arXiv:1608.08245 2016 paper for the proof.)
Ji Young Choi, Ternary Modified Collatz Sequences And Jacobsthal Numbers, Journal of Integer Sequences, Vol. 19 (2016), #16.7.5.
Ji Young Choi, A Generalization of Collatz Functions and Jacobsthal Numbers, J. Int. Seq., Vol. 21 (2018), Article 18.5.4.
David Hayes, Kaveh Khodjasteh, Lorenza Viola and Michael J. Biercuk, Reducing sequencing complexity in dynamical quantum error suppression by Walsh modulation, arXiv:1109.6002 [quant-ph], 2011.
Clemens Heuberger and Daniel Krenn, Esthetic Numbers and Lifting Restrictions on the Analysis of Summatory Functions of Regular Sequences, arXiv:1808.00842 [math.CO], 2018. See p. 10.
Clemens Heuberger and Daniel Krenn, Asymptotic Analysis of Regular Sequences, arXiv:1810.13178 [math.CO], 2018. See p. 29.
Andreas M. Hinz, The Lichtenberg sequence, Fib. Quart., 55 (2017), 2-12.
Andreas M. Hinz, Sandi Klavžar, Uroš Milutinović, and Ciril Petr, The Tower of Hanoi - Myths and Maths, Birkhäuser 2013. See page 56. Book's website
Andreas M. Hinz and Paul K. Stockmeyer, Precious Metal Sequences and Sierpinski-Type Graphs, J. Integer Seq., Vol 25 (2022), Article 22.4.8.
Jia Huang, Norton algebras of the Hamming Graphs via linear characters, arXiv:2101.05711 [math.CO], 2021.
Jia Huang and Erkko Lehtonen, Associative-commutative spectra for some varieties of groupoids, arXiv:2401.15786 [math.CO], 2024. See p. 17.
Jia Huang, Madison Mickey, and Jianbai Xu, The Nonassociativity of the Double Minus Operation, Journal of Integer Sequences, Vol. 20 (2017), #17.10.3.
Hans Isdahl, "Knitwear" puzzle
D. E. Knuth and O. P. Lossers, Partitions of a circular set, Problem 11151 in Amer. Math. Monthly 114 (3) (2007) p 265, E_3.
S. Lafortune, A. Ramani, B. Grammaticos, Y. Ohta and K.M. Tamizhmani, Blending two discrete integrability criteria: singularity confinement and algebraic entropy, arXiv:nlin/0104020 [nlin.SI], 2001.
Robert L. Lamphere, A Recurrence Relation in the Spinout Puzzle, The College Mathematics Journal, Vol. 27, Nbr. 4, Page 289, Sep. 96.
Georg Christoph Lichtenberg, Vermischte Schriften, Band 6 (1805). See chapter 6, p. 257.
Saad Mneimneh, Simple Variations on the Tower of Hanoi to Guide the Study of Recurrences and Proofs by Induction, Department of Computer Science, Hunter College, CUNY, 2019.
Richard Moot, Partial Orders, Residuation, and First-Order Linear Logic, arXiv:2008.06351 [cs.LO], 2020.
Gregg Musiker and Son Nguyen, Labeled Chip-firing on Binary Trees, arXiv:2206.02007 [math.CO], 2022.
Ahmet Öteleş, On the sum of Pell and Jacobsthal numbers by the determinants of Hessenberg matrices, AIP Conference Proceedings 1863, 310003 (2017).
Vladimir Shevelev, On the Basis Polynomials in the Theory of Permutations with Prescribed Up-Down Structure, arXiv:0801.0072 [math.CO], 2007-2010. See Example 3.
Chloe E. Shiff and Noah A. Rosenberg, Enumeration of rooted binary perfect phylogenies, arXiv:2410.14915 [q-bio.PE], 2024. See pp. 15, 17.
A. V. Sills and H. Wang, On the maximal Wiener index and related questions, Discrete Applied Mathematics, Volume 160, Issues 10-11, July 2012, Pages 1615-1623 - N. J. A. Sloane, Sep 21 2012
N. J. A. Sloane, Transforms
Paul K. Stockmeyer, An Exploration of Sequence A000975, arXiv:1608.08245 [math.CO], 2016; Fib. Quart. 55 (2017) 174.
Eric Weisstein's World of Mathematics, Baguenaudier
A. K. Whitford, Binet's Formula Generalized, Fibonacci Quarterly, Vol. 15, No. 1, 1979, pp. 21, 24, 29.
FORMULA
a(n) = ceiling(2*(2^n-1)/3).
Alternating sum transform (PSumSIGN) of {2^n - 1} (A000225).
a(n) = a(n-1) + 2*a(n-2) + 1.
a(n) = 2*2^n/3 - 1/2 - (-1)^n/6.
a(n) = Sum_{i = 0..n} A001045(i), partial sums of A001045. - Bill Blewett
a(n) = n + 2*Sum_{k = 1..n-2} a(k).
G.f.: x/((1+x)*(1-x)*(1-2*x)) = x/(1-2*x-x^2+2*x^3). - Paul Barry, Feb 11 2003
a(n) = 2*a(n-1) + a(n-2) - 2*a(n-3). - Paul Barry, Feb 11 2003
a(n) = Sum_{k = 0..floor((n-1)/2)} 2^(n-2*k-1). - Paul Barry, Nov 11 2003
a(n+1) = Sum_{k=0..floor(n/2)} 2^(n-2*k); a(n+1) = Sum_{k = 0..n} Sum_{j = 0..k} (-1)^(j+k)*2^j. - Paul Barry, Nov 12 2003
(-1)^(n+1)*a(n) = Sum_{i = 0..n} Sum_{k = 1..i} k!*k* Stirling2(i, k)*(-1)^(k-1) = (1/3)*(-2)^(n+1)-(1/6)(3*(-1)^(n+1)-1). - Mario Catalani (mario.catalani(AT)unito.it), Dec 22 2003
a(n+1) = (n!/3)*Sum_{i - (-1)^i + j = n, i = 0..n, j = 0..n} 1/(i - (-1)^i)!/j!. - Benoit Cloitre, May 24 2004
a(n) = A001045(n+1) - A059841(n). - Paul Barry, Jul 22 2004
a(n) = Sum_{k = 0..n} 2^(n-k-1)*(1-(-1)^k), row sums of A130125. - Paul Barry, Jul 28 2004
a(n) = Sum_{k = 0..n} binomial(k, n-k+1)2^(n-k); a(n) = Sum_{k = 0..floor(n/2)} binomial(n-k, k+1)2^k. - Paul Barry, Oct 07 2004
a(n) = A107909(A104161(n)); A007088(a(n)) = A056830(n). - Reinhard Zumkeller, May 28 2005
a(n) = floor(2^(n+1)/3) = ceiling(2^(n+1)/3) - 1 = A005578(n+1) - 1. - Paul Barry, Oct 08 2005
Convolution of "Number of fixed points in all 231-avoiding involutions in S_n." (A059570) with "1-n" (A024000), treating the result as if offset was 0. - Graeme McRae, Jul 12 2006
a(n) = A081254(n) - 2^n. - Philippe Deléham, Oct 15 2006
Starting (1, 2, 5, 10, 21, 42, ...), these are the row sums of triangle A135228. - Gary W. Adamson, Nov 23 2007
Let T = the 3 X 3 matrix [1,1,0; 1,0,1; 0,1,1]. Then T^n * [1,0,0] = [A005578(n), A001045(n), a(n-1)]. - Gary W. Adamson, Dec 25 2007
2^n = 2*A005578(n-1) + 2*A001045(n) + 2*a(n-2). - Gary W. Adamson, Dec 25 2007
If we define f(m,j,x) = Sum_{k=j..m} binomial(m,k)*stirling2(k,j)*x^(m-k) then a(n-3) = (-1)^(n-1)*f(n,3,-2), (n >= 3). - Milan Janjic, Apr 26 2009
a(n) + A001045(n) = A166920(n). a(n) + A001045(n+2) = A051049(n+1). - Paul Curtz, Oct 29 2009
a(n) = floor(A051049(n+1)/3). - Gary Detlefs, Dec 19 2010
a(n) = round((2^(n+2)-3)/6) = floor((2^(n+1)-1)/3) = round((2^(n+1)-2)/3); a(n) = a(n-2) + 2^(n-1), n > 1. - Mircea Merca, Dec 27 2010
a(n) = binary XOR of 2^k-1 for k=0..n. - Paul D. Hanna, Nov 05 2011
E.g.f.: 2/3*exp(2*x) - 1/2*exp(x) - 1/6*exp(-x) = 2/3*U(0); U(k) = 1 - 3/(4*(2^k) - 4*(2^k)/(1+3*(-1)^k - 24*x*(2^k)/(8*x*(2^k)*(-1)^k - (k+1)/U(k+1)))); (continued fraction). - Sergei N. Gladkovskii, Nov 21 2011
Starting with "1" = triangle A059260 * [1, 2, 2, 2, ...] as a vector. - Gary W. Adamson, Mar 06 2012
a(n) = 2*(2^n - 1)/3, for even n; a(n) = (2^(n+1) - 1)/3 = (1/3)*(2^((n+1)/2) - 1)*(2^((n+1)/2) + 1), for odd n. - Hieronymus Fischer, Nov 22 2012
a(n) + a(n+1) = 2^(n+1) - 1. - Arie Bos, Apr 03 2013
G.f.: Q(0)/(3*(1-x)), where Q(k) = 1 - 1/(4^k - 2*x*16^k/(2*x*4^k - 1/(1 + 1/(2*4^k - 8*x*16^k/(4*x*4^k + 1/Q(k+1)))))); (continued fraction). - Sergei N. Gladkovskii, May 21 2013
floor(a(n+2)*3/5) = A077854(n), for n >= 0. - Armands Strazds, Sep 21 2014
a(n) = (2^(n+1) - 2 + (n mod 2))/3. - Paul Toms, Mar 18 2015
a(0) = 0, a(n) = 2*(a(n-1)) + (n mod 2). - Paul Toms, Mar 18 2015
Binary: a(n) = (a(n-1) shift left 1) + (a(n-1)) NOR (...11110). - Paul Toms, Mar 18 2015
Binary: for n > 1, a(n) = 2*a(n-1) OR a(n-2). - Stanislav Sykora, Nov 12 2015
a(n) = A266613(n) - 20*2^(n-5), for n > 2. - Andres Cicuttin, Mar 31 2016
From Michael Somos, Jul 23 2017: (Start)
a(n) = -(2^n)*a(-n) for even n; a(n) = -(2^(n+1))*a(-n) + 1 for odd n.
0 = +a(n)*(+2 +4*a(n) -4*a(n+1)) + a(n+1)*(-1 +a(n+1)) for all n in Z. (End)
G.f.: (x^1+x^3+x^5+x^7+...)/(1-2*x). - Gregory L. Simay, Sep 27 2017
a(n+1) = A051049(n) + A001045(n). - Yuchun Ji, Jul 12 2018
a(n) = A153772(n+3)/4. - Markus Sigg, Sep 14 2020
a(4*k+d) = 2^(d+1)*a(4*k-1) + a(d), a(n+4) = a(n) + 2^n*10, a(0..3) = [0,1,2,5]. So the last digit is always 0,1,2,5 repeated. - Yuchun Ji, May 22 2023
EXAMPLE
a(4)=10 since 0001, 0011, 0010, 0110, 0111, 0101, 0100, 1100, 1101, 1111 are the 10 binary strings switching 0000 to 1111.
a(3) = 1 because "lrc" is the only way to tie a tie with 3 half turns, namely, pass the business end of the tie behind the standing part to the left, bring across the front to the right, then behind to the center. The final motion of tucking the loose end down the front behind the "lr" piece is not considered a "step".
a(4) = 2 because "lrlc" is the only way to tie a tie with 4 half turns. Note that since the number of moves is even, the first step is to go to the left in front of the tie, not behind it. This knot is the standard "four in hand", the most commonly known men's tie knot. By contrast, the second most well known tie knot, the Windsor, is represented by "lcrlcrlc".
a(n) = (2^0 - 1) XOR (2^1 - 1) XOR (2^2 - 1) XOR (2^3 - 1) XOR ... XOR (2^n - 1). - Paul D. Hanna, Nov 05 2011
G.f. = x + 2*x^2 + 5*x^3 + 10*x^4 + 21*x^5 + 42*x^6 + 85*x^7 + 170*x^8 + ...
a(9) = 341 = 2^8 + 2^6 + 2^4 + 2^2 + 2^0 = 4^4 + 4^3 + 4^2 + 4^1 + 4^0 = A002450(5). a(10) = 682 = 2*a(9) = 2*A002450(5). - Gregory L. Simay, Sep 27 2017
MAPLE
A000975 := proc(n) option remember; if n <= 1 then n else if n mod 2 = 0 then 2*A000975(n-1) else 2*A000975(n-1)+1 fi; fi; end;
seq(iquo(2^n, 3), n=1..33); # Zerinvary Lajos, Apr 20 2008
f:=n-> if n mod 2 = 0 then (2^n-1)/3 else (2^n-2)/3; fi; [seq(f(n), n=0..40)]; # N. J. A. Sloane, Mar 21 2017
MATHEMATICA
Array[Ceiling[2(2^# - 1)/3] &, 41, 0]
RecurrenceTable[{a[0] == 0, a[1] == 1, a[n] == a[n - 1] + 2a[n - 2] + 1}, a, {n, 40}] (* or *)
LinearRecurrence[{2, 1, -2}, {0, 1, 2}, 40] (* Harvey P. Dale, Aug 10 2013 *)
f[n_] := Block[{exp = n - 2}, Sum[2^i, {i, exp, 0, -2}]]; Array[f, 33] (* Robert G. Wilson v, Oct 30 2015 *)
f[s_List] := Block[{a = s[[-1]]}, Append[s, If[OddQ@ Length@ s, 2a + 1, 2a]]]; Nest[f, {0}, 32] (* Robert G. Wilson v, Jul 20 2017 *)
NestList[2# + Boole[EvenQ[#]] &, 0, 39] (* Alonso del Arte, Sep 21 2018 *)
PROG
(PARI) {a(n) = if( n<0, 0, 2 * 2^n \ 3)}; /* Michael Somos, Sep 04 2006 */
(PARI) a(n)=if(n<=0, 0, bitxor(a(n-1), 2^n-1)) \\ Paul D. Hanna, Nov 05 2011
(PARI) concat(0, Vec(x/(1-2*x-x^2+2*x^3) + O(x^100))) \\ Altug Alkan, Oct 30 2015
(PARI) {a(n) = (4*2^n - 3 - (-1)^n) / 6}; /* Michael Somos, Jul 23 2017 */
(Haskell)
a000975 n = a000975_list !! n
a000975_list = 0 : 1 : map (+ 1)
(zipWith (+) (tail a000975_list) (map (* 2) a000975_list))
-- Reinhard Zumkeller, Mar 07 2012
(Magma) [(2^(n+1) - 2 + (n mod 2))/3: n in [0..40]]; // Vincenzo Librandi, Mar 18 2015
(GAP) List([0..35], n->(2^(n+1)-2+(n mod 2))/3); # Muniru A Asiru, Nov 01 2018
(Python)
def a(n): return (2**(n+1) - 2 + (n%2))//3
print([a(n) for n in range(35)]) # Michael S. Branicky, Dec 19 2021
CROSSREFS
Partial sums of A001045.
Row sums of triangle A013580.
Equals A026644/2.
Union of the bijections A002450 and A020988. - Robert G. Wilson v, Jun 09 2014
Column k=3 of A261139.
Complement of A107907.
Row 3 of A300653.
Other sequences that relate to the binary representation of the terms: A003714, A003754, A007088, A022290, A056830, A104161, A107909.
KEYWORD
nonn,easy,nice,changed
EXTENSIONS
Additional comments from Barry E. Williams, Jan 10 2000
STATUS
approved
Riordan array (1, x(1-x)).
+10
53
1, 0, 1, 0, -1, 1, 0, 0, -2, 1, 0, 0, 1, -3, 1, 0, 0, 0, 3, -4, 1, 0, 0, 0, -1, 6, -5, 1, 0, 0, 0, 0, -4, 10, -6, 1, 0, 0, 0, 0, 1, -10, 15, -7, 1, 0, 0, 0, 0, 0, 5, -20, 21, -8, 1, 0, 0, 0, 0, 0, -1, 15, -35, 28, -9, 1, 0, 0, 0, 0, 0, 0, -6, 35, -56, 36, -10, 1, 0, 0, 0, 0, 0, 0, 1, -21, 70, -84, 45, -11, 1, 0, 0, 0, 0
OFFSET
0,9
COMMENTS
Inverse is Riordan array (1, xc(x)) (A106566).
Triangle T(n,k), 0 <= k <= n, read by rows, given by [0, -1, 1, 0, 0, 0, 0, 0, 0, ...] DELTA [1, 0, 0, 0, 0, 0, 0, 0, ...] where DELTA is the operator defined in A084938.
Modulo 2, this sequence gives A106344. - Philippe Deléham, Dec 18 2008
Coefficient array of the polynomials Chebyshev_U(n, sqrt(x)/2)*(sqrt(x))^n. - Paul Barry, Sep 28 2009
FORMULA
Number triangle T(n, k) = (-1)^(n-k)*binomial(k, n-k).
T(n, k)*2^(n-k) = A110509(n, k); T(n, k)*3^(n-k) = A110517(n, k).
Sum_{k=0..n} T(n,k)*A000108(k)=1. - Philippe Deléham, Jun 11 2007
From Philippe Deléham, Oct 30 2008: (Start)
Sum_{k=0..n} T(n,k)*A144706(k) = A082505(n+1).
Sum_{k=0..n} T(n,k)*A002450(k) = A100335(n).
Sum_{k=0..n} T(n,k)*A001906(k) = A100334(n).
Sum_{k=0..n} T(n,k)*A015565(k) = A099322(n).
Sum_{k=0..n} T(n,k)*A003462(k) = A106233(n). (End)
Sum_{k=0..n} T(n,k)*x^(n-k) = A053404(n), A015447(n), A015446(n), A015445(n), A015443(n), A015442(n), A015441(n), A015440(n), A006131(n), A006130(n), A001045(n+1), A000045(n+1), A000012(n), A010892(n), A107920(n+1), A106852(n), A106853(n), A106854(n), A145934(n), A145976(n), A145978(n), A146078(n), A146080(n), A146083(n), A146084(n) for x = -12,-11,-10,-9,-8,-7,-6,-5,-4,-3,-2,-1,0,1,2,3,4,5,6,7,8,9,10,11,12 respectively. - Philippe Deléham, Oct 27 2008
Sum_{k=0..n} T(n,k)*x^k = A000007(n), A010892(n), A099087(n), A057083(n), A001787(n+1), A030191(n), A030192(n), A030240(n), A057084(n), A057085(n+1), A057086(n) for x = 0,1,2,3,4,5,6,7,8,9,10 respectively. - Philippe Deléham, Oct 28 2008
G.f.: 1/(1-y*x+y*x^2). - Philippe Deléham, Dec 15 2011
T(n,k) = T(n-1,k-1) - T(n-2,k-1), T(n,0) = 0^n. - Philippe Deléham, Feb 15 2012
Sum_{k=0..n} T(n,k)*x^(n-k) = F(n+1,-x) where F(n,x)is the n-th Fibonacci polynomial in x defined in A011973. - Philippe Deléham, Feb 22 2013
Sum_{k=0..n} T(n,k)^2 = A051286(n). - Philippe Deléham, Feb 26 2013
Sum_{k=0..n} T(n,k)*T(n+1,k) = -A110320(n). - Philippe Deléham, Feb 26 2013
For T(0,0) = 0, the signed triangle below has the o.g.f. G(x,t) = [t*x(1-x)]/[1-t*x(1-x)] = L[t*Cinv(x)] where L(x) = x/(1-x) and Cinv(x)=x(1-x) with the inverses Linv(x) = x/(1+x) and C(x)= [1-sqrt(1-4*x)]/2, an o.g.f. for the shifted Catalan numbers A000108, so the inverse o.g.f. is Ginv(x,t) = C[Linv(x)/t] = [1-sqrt[1-4*x/(t(1+x))]]/2 (cf. A124644 and A030528). - Tom Copeland, Jan 19 2016
EXAMPLE
Rows begin:
1;
0, 1;
0, -1, 1;
0, 0, -2, 1;
0, 0, 1, -3, 1;
0, 0, 0, 3, -4, 1;
0, 0, 0, -1, 6, -5, 1;
0, 0, 0, 0, -4, 10, -6, 1;
0, 0, 0, 0, 1, -10, 15, -7, 1;
0, 0, 0, 0, 0, 5, -20, 21, -8, 1;
0, 0, 0, 0, 0, -1, 15, -35, 28, -9, 1;
From Paul Barry, Sep 28 2009: (Start)
Production array is
0, 1,
0, -1, 1,
0, -1, -1, 1,
0, -2, -1, -1, 1,
0, -5, -2, -1, -1, 1,
0, -14, -5, -2, -1, -1, 1,
0, -42, -14, -5, -2, -1, -1, 1,
0, -132, -42, -14, -5, -2, -1, -1, 1,
0, -429, -132, -42, -14, -5, -2, -1, -1, 1 (End)
MATHEMATICA
(* The function RiordanArray is defined in A256893. *)
RiordanArray[1&, #(1-#)&, 13] // Flatten (* Jean-François Alcover, Jul 16 2019 *)
PROG
(Magma) /* As triangle */ [[(-1)^(n-k)*Binomial(k, n-k): k in [0..n]]: n in [0.. 15]]; // Vincenzo Librandi, Jan 14 2016
CROSSREFS
Cf. A026729 (unsigned version), A000108, A030528, A124644.
KEYWORD
easy,sign,tabl
AUTHOR
Philippe Deléham, Aug 28 2005
STATUS
approved
Scaled Chebyshev U-polynomials evaluated at i*sqrt(5)/2. Generalized Fibonacci sequence.
+10
29
1, 5, 30, 175, 1025, 6000, 35125, 205625, 1203750, 7046875, 41253125, 241500000, 1413765625, 8276328125, 48450468750, 283633984375, 1660422265625, 9720281250000, 56903517578125, 333118994140625, 1950112558593750, 11416157763671875, 66831351611328125, 391237546875000000
OFFSET
0,2
COMMENTS
a(n) gives the length of the word obtained after n steps with the substitution rule 0->11111, 1->111110, starting from 0. The number of 1's and 0's of this word is 5*a(n-1) and 5*a(n-2), resp.
a(n) / a(n-1) converges to (5 + (3 * sqrt(5))) / 2 as n approaches infinity. (5 + (3 * sqrt(5))) / 2 can also be written as phi^2 + (2 * phi), phi^3 + phi, phi + sqrt(5) + 2, (3 * phi) + 1, (3 * phi^2) - 2, phi^4 - 1 and (5 + (3 * (L(n) / F(n)))) / 2, where L(n) is the n-th Lucas number and F(n) is the n-th Fibonacci number as n approaches infinity. - Ross La Haye, Aug 18 2003, on another version
Pisano period lengths: 1, 3, 3, 6, 1, 3, 24, 12, 9, 3, 10, 6, 56, 24, 3, 24,288, 9, 18, 6, ... - R. J. Mathar, Aug 10 2012
LINKS
Martin Burtscher, Igor Szczyrba, Rafał Szczyrba, Analytic Representations of the n-anacci Constants and Generalizations Thereof, Journal of Integer Sequences, Vol. 18 (2015), Article 15.4.5.
A. F. Horadam, Special properties of the sequence W_n(a,b; p,q), Fib. Quart., 5.5 (1967), 424-434. Case n->n+1, a=0,b=1; p=5, q=5.
Tanya Khovanova, Recursive Sequences
W. Lang, On polynomials related to powers of the generating function of Catalan's numbers, Fib. Quart. 38 (2000) 408-419. Eqs.(39) and (45),rhs, m=5.
Eric Weisstein's World of Mathematics, Horadam Sequence
FORMULA
a(n) = 5*(a(n-1) + a(n-2)), a(-1)=0, a(0)=1.
a(n) = S(n, i*sqrt(5))*(-i*sqrt(5))^n with S(n, x) := U(n, x/2), Chebyshev's polynomials of the 2nd kind, A049310.
G.f.: 1/(1 - 5*x - 5*x^2).
a(n) = (1/3)*Sum_{k=0..n} binomial(n, k)*Fibonacci(k)*3^k. - Benoit Cloitre, Oct 25 2003
a(n) = ((5 + 3*sqrt(5))/2)^n(1/2 + sqrt(5)/6) + (1/2 - sqrt(5)/6)((5 - 3*sqrt(5))/2)^n. - Paul Barry, Sep 22 2004
(a(n)) appears to be given by the floretion - 0.75'i - 0.5'j + 'k - 0.75i' + 0.5j' + 0.5k' + 1.75'ii' - 1.25'jj' + 1.75'kk' - 'ij' - 0.5'ji' - 0.75'jk' - 0.75'kj' - 1.25e ("jes"). - Creighton Dement, Nov 28 2004
a(n) = Sum_{k=0..n} 4^k*A063967(n,k). - Philippe Deléham, Nov 03 2006
G.f.: G(0)/(2-5*x), where G(k)= 1 + 1/(1 - x*(9*k-5)/(x*(9*k+4) - 2/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 17 2013
From Ehren Metcalfe, Nov 18 2017: (Start)
With F(n) = A000045(n), L(n) = A000032(n), beta = (1-sqrt(5))/2:
a(2*n-1) = 5^n*F(4*n)/3 = (5^(n-1/2)*L(4*n) - 2*5^(n-1/2)*beta^(4*n))/3.
a(2*n) = 5^n*L(4*n+2)/3 = (5^(n+1/2)*F(4*n+2) + 2*5^n*beta^(4*n+2))/3.
a(n) = round 5^((n+1)/2)*F(2*(n+1))/3.
a(n) = round 5^(n/2)*L(2*(n+1))/3. (End)
MAPLE
a[0]:=0:a[1]:=1:for n from 2 to 50 do a[n]:=5*a[n-1]+5*a[n-2]od: seq(a[n], n=1..33); # Zerinvary Lajos, Dec 14 2008
MATHEMATICA
LinearRecurrence[{5, 5}, {1, 5}, 30] (* G. C. Greubel, Jan 16 2018 *)
PROG
(Sage) [lucas_number1(n, 5, -5) for n in range(1, 22)] # Zerinvary Lajos, Apr 24 2009
(PARI) x='x+O('x^30); Vec(1/(1 - 5*x - 5*x^2)) \\ G. C. Greubel, Jan 16 2018
(Magma) I:=[1, 5]; [n le 2 select I[n] else 5*Self(n-1) + 5*Self(n-2): n in [0..30]]; // G. C. Greubel, Jan 16 2018
KEYWORD
nonn,easy
AUTHOR
Wolfdieter Lang, Aug 11 2000
STATUS
approved
Scaled Chebyshev U-polynomials evaluated at i*sqrt(6)/2. Generalized Fibonacci sequence.
+10
15
1, 6, 42, 288, 1980, 13608, 93528, 642816, 4418064, 30365280, 208700064, 1434392064, 9858552768, 67757668992, 465697330560, 3200729997312, 21998563967232, 151195763787264, 1039165966526976, 7142170381885440
OFFSET
0,2
COMMENTS
a(n) gives the length of the word obtained after n steps with the substitution rule 0->1^6, 1->(1^6)0, starting from 0. The number of 1's and 0's of this word is 6*a(n-1) and 6*a(n-2), resp.
LINKS
Martin Burtscher, Igor Szczyrba, and Rafał Szczyrba, Analytic Representations of the n-anacci Constants and Generalizations Thereof, Journal of Integer Sequences, Vol. 18 (2015), Article 15.4.5.
A. F. Horadam, Special properties of the sequence W_n(a,b; p,q), Fib. Quart., 5.5 (1967), 424-434. Case n->n+1, a=0,b=1; p=6, q=6.
Tanya Khovanova, Recursive Sequences
Wolfdieter Lang, On polynomials related to powers of the generating function of Catalan's numbers, Fib. Quart. 38 (2000) 408-419. Eqs.(39) and (45),rhs, m=6.
FORMULA
a(n) = 6*a(n-1) + 6*a(n-2); a(0)=1, a(1)=6.
a(n) = S(n, i*sqrt(6))*(-i*sqrt(6))^n with S(n, x) := U(n, x/2), Chebyshev's polynomials of the 2nd kind, A049310.
G.f.: 1/(1-6*x-6*x^2).
a(n) = Sum_{k=0..n} 5^k*A063967(n,k). - Philippe Deléham, Nov 03 2006
MATHEMATICA
Join[{a=0, b=1}, Table[c=6*b+6*a; a=b; b=c, {n, 100}]] (* Vladimir Joseph Stephan Orlovsky, Jan 16 2011 *)
LinearRecurrence[{6, 6}, {1, 6}, 40] (* Harvey P. Dale, Nov 05 2011 *)
PROG
(Sage) [lucas_number1(n, 6, -6) for n in range(1, 21)] # Zerinvary Lajos, Apr 24 2009
(Magma) I:=[1, 6]; [n le 2 select I[n] else 6*Self(n-1)+6*Self(n-2): n in [1..30]]; // Vincenzo Librandi, Nov 14 2011
(PARI) x='x+O('x^30); Vec(1/(1-6*x-6*x^2)) \\ G. C. Greubel, Jan 24 2018
KEYWORD
nonn,easy
AUTHOR
Wolfdieter Lang, Aug 11 2000
STATUS
approved
Another version of Fibonacci-Pascal triangle A037027.
+10
15
1, 0, 1, 0, 1, 2, 0, 0, 2, 3, 0, 0, 1, 5, 5, 0, 0, 0, 3, 10, 8, 0, 0, 0, 1, 9, 20, 13, 0, 0, 0, 0, 4, 22, 38, 21, 0, 0, 0, 0, 1, 14, 51, 71, 34, 0, 0, 0, 0, 0, 5, 40, 111, 130, 55, 0, 0, 0, 0, 0, 1, 20, 105, 233, 235, 89, 0, 0, 0, 0, 0, 0, 6, 65, 256, 474, 420, 144
OFFSET
0,6
COMMENTS
Triangle T(n,k), 0 <= k <= n, read by rows, given by [0, 1, -1, 0, 0, 0, 0, 0, 0, 0, ...] DELTA [1, 1, -1, 0, 0, 0, 0, 0, 0, ...] where DELTA is the operator defined in A084938.
Row sums are the Jacobsthal numbers A001045(n+1) and column sums form Pell numbers A000129.
Maximal column entries: A038149 = {1, 1, 2, 5, 10, 22, ...}.
T(n,k) gives a convolved Fibonacci sequence (A001629, A001872, ...).
Triangle read by rows: T(n,n-k) is the number of ways to tile a 2 X n rectangle with k pieces of 2 X 2 tiles and n-2k pieces of 1 X 2 tiles (0 <= k <= floor(n/2)). - Philippe Deléham, Feb 17 2014
Diagonal sums are A013979(n). - Philippe Deléham, Feb 17 2014
T(n,k) is the number of ways to tile a 2 X n rectangle with k pieces of 2 X 2 tiles and 1 X 2 tiles. - Emeric Deutsch, Aug 14 2014
FORMULA
T(0, 0) = 1, T(n, k) = 0 for k < 0 or for n < k, T(n, k) = T(n-1, k-1) + T(n-2, k-1) + T(n-2, k-2).
T(n, k) = A037027(k, n-k). T(n, n) = A000045(n+1). T(3n, 2n) = (n+1)*A001002(n+1) = A038112(n).
G.f.: 1/(1-yx(1-x)-x^2*y^2). - Paul Barry, Oct 04 2005
Sum_{k=0..n} x^k*T(n,k) = (-1)^n*A053524(n+1), (-1)^n*A083858(n+1), (-1)^n*A002605(n), A033999(n), A000007(n), A001045(n+1), A083099(n) for x = -4, -3, -2, -1, 0, 1, 2 respectively. - Philippe Deléham, Dec 02 2006
Sum_{k=0..n} T(n,k)*x^(n-k) = A053404(n), A015447(n), A015446(n), A015445(n), A015443(n), A015442(n), A015441(n), A015440(n), A006131(n), A006130(n), A001045(n+1), A000045(n+1) for x = 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0 respectively. - Philippe Deléham, Feb 17 2014
EXAMPLE
Triangle begins:
1;
0, 1;
0, 1, 2;
0, 0, 2, 3;
0, 0, 1, 5, 5;
0, 0, 0, 3, 10, 8;
0, 0, 0, 1, 9, 20, 13;
0, 0, 0, 0, 4, 22, 38, 21;
0, 0, 0, 0, 1, 14, 51, 71, 34;
0, 0, 0, 0, 0, 5, 40, 111, 130, 55;
0, 0, 0, 0, 0, 1, 20, 105, 233, 235, 89;
0, 0, 0, 0, 0, 0, 6, 65, 256, 474, 420, 144;
PROG
(Haskell)
a111006 n k = a111006_tabl !! n !! k
a111006_row n = a111006_tabl !! n
a111006_tabl = map fst $ iterate (\(us, vs) ->
(vs, zipWith (+) (zipWith (+) ([0] ++ us ++ [0]) ([0, 0] ++ us))
([0] ++ vs))) ([1], [0, 1])
-- Reinhard Zumkeller, Aug 15 2013
CROSSREFS
Cf. A000045, A000129, A001045, A037027, A038112, A038149, A084938, A128100 (reversed version).
Some other Fibonacci-Pascal triangles: A027926, A036355, A037027, A074829, A105809, A109906, A114197, A162741, A228074.
KEYWORD
easy,nonn,tabl
AUTHOR
Philippe Deléham, Oct 02 2005
STATUS
approved
Expansion of x/(1 - 5*x - 4*x^2).
+10
14
0, 1, 5, 29, 165, 941, 5365, 30589, 174405, 994381, 5669525, 32325149, 184303845, 1050819821, 5991314485, 34159851709, 194764516485, 1110461989261, 6331368012245, 36098688018269, 205818912140325, 1173489312774701, 6690722212434805
OFFSET
0,3
COMMENTS
First differences give A122690(n) = {1, 4, 24, 136, 776, 4424, 25224, ...}. Partial sums of a(n) are {0, 1, 6, 35, 200, ...} = (A123270(n) - 1)/8. - Alexander Adamchuk, Nov 03 2006
For n >= 2, a(n) equals the permanent of the (n-1) X (n-1) tridiagonal matrix with 5's along the main diagonal, and 2's along the superdiagonal and the subdiagonal. - John M. Campbell, Jul 19 2011
Pisano period lengths: 1, 1, 8, 1, 4, 8, 48, 1, 24, 4, 40, 8, 42, 48, 8, 2, 72, 24, 360, 4, ... - R. J. Mathar, Aug 10 2012
LINKS
Lucyna Trojnar-Spelina and Iwona Włoch, On Generalized Pell and Pell-Lucas Numbers, Iranian Journal of Science and Technology, Transactions A: Science (2019), 1-7.
FORMULA
a(n) = 5*a(n-1) + 4*a(n-2).
a(n) = Sum_{k=0..floor((n-1)/2)} C(n-k-1, k)*4^k*5^(n-2*k-1). - Paul Barry, Apr 23 2005
a(n) = Sum_{k=0..(n-1)} A122690(k). - Alexander Adamchuk, Nov 03 2006
a(n) = 2^(n-1)*Fibonacci(n, 5/2) = (2/i)^(n-1)*ChebyshevU(n-1, 5*i/4). - G. C. Greubel, Dec 26 2019
MAPLE
seq( simplify((2/I)^(n-1)*ChebyshevU(n-1, 5*I/4)), n=0..20); # G. C. Greubel, Dec 26 2019
MATHEMATICA
LinearRecurrence[{5, 4}, {0, 1}, 30] (* Vincenzo Librandi, Nov 12 2012 *)
Table[2^(n-1)*Fibonacci[n, 5/2], {n, 0, 30}] (* G. C. Greubel, Dec 26 2019 *)
PROG
(Sage) [lucas_number1(n, 5, -4) for n in range(0, 22)] # Zerinvary Lajos, Apr 24 2009
(Magma) [n le 2 select n-1 else 5*Self(n-1)+4*Self(n-2): n in [1..30]]; // Vincenzo Librandi, Nov 12 2012
(PARI) x='x+O('x^30); concat([0], Vec(x/(1-5*x-4*x^2))) \\ G. C. Greubel, Jan 01 2018
(GAP) a:=[0, 1];; for n in [3..30] do a[n]:=5*a[n-1]+4*a[n-2]; od; a; # G. C. Greubel, Dec 26 2019
KEYWORD
nonn,easy
STATUS
approved
a(n) = 4*a(n-1) + 10*a(n-2), with a(1)=0 and a(2)=1.
+10
11
0, 1, 4, 26, 144, 836, 4784, 27496, 157824, 906256, 5203264, 29875616, 171535104, 984896576, 5654937344, 32468715136, 186424233984, 1070384087296, 6145778689024, 35286955629056, 202605609406464, 1163291993916416, 6679224069730304, 38349816218085376
OFFSET
1,3
FORMULA
a(n) = ((2+sqrt(14))^(n-1) - (2-sqrt(14))^(n-1))/(2*sqrt(14)). - Rolf Pleisch, May 14 2011
G.f.: x^2/(1-4*x-10*x^2).
MATHEMATICA
Join[{a=0, b=1}, Table[c=4*b+10*a; a=b; b=c, {n, 100}]]
LinearRecurrence[{4, 10}, {0, 1}, 30] (* G. C. Greubel, Jan 16 2018 *)
PROG
(PARI) x='x+O('x^30); concat([0], Vec(x^2/(1-4*x-10*x^2))) \\ G. C. Greubel, Jan 16 2018
(Magma) I:=[0, 1]; [n le 2 select I[n] else 4*Self(n-1) + 10*Self(n-2): n in [1..30]]; // G. C. Greubel, Jan 16 2018
KEYWORD
nonn,easy
AUTHOR
STATUS
approved
Generalized Fibonacci numbers: a(n) = 6*a(n-1) + 2*a(n-2).
+10
9
0, 1, 6, 38, 240, 1516, 9576, 60488, 382080, 2413456, 15244896, 96296288, 608267520, 3842197696, 24269721216, 153302722688, 968355778560, 6116740116736, 38637152257536, 244056393778688, 1541612667187200
OFFSET
0,3
COMMENTS
For n>0, a(n) equals the number of words of length n-1 over {0,1,...,7} in which 0 and 1 avoid runs of odd lengths. - Milan Janjic, Jan 08 2017
LINKS
Joshua Zucker and Robert Israel, Table of n, a(n) for n = 0..1000 (n=0..51 from Joshua Zucker).
FORMULA
a(0) = 0; a(1) = 1; a(n) = 2*(3*a(n-1) + a(n-2)).
a(n) = 1/(2*sqrt(11))*( (3 + sqrt(11))^n - (3 - sqrt(11))^n ).
G.f.: x/(1 - 6*x - 2*x^2). - Harvey P. Dale, Jun 20 2011
a(n+1) = Sum_{k=0..n} A099097(n,k)*2^k. - Philippe Deléham, Sep 16 2014
E.g.f.: (1/sqrt(11))*exp(3*x)*sinh(sqrt(11)*x). - G. C. Greubel, Sep 17 2016
MAPLE
A:= gfun:-rectoproc({a(0) = 0, a(1) = 1, a(n) = 2*(3*a(n-1) + a(n-2))}, a(n), remember):
seq(A(n), n=1..30); # Robert Israel, Sep 16 2014
MATHEMATICA
Join[{a=0, b=1}, Table[c=6*b+2*a; a=b; b=c, {n, 100}]] (* Vladimir Joseph Stephan Orlovsky, Jan 16 2011 *)
LinearRecurrence[{6, 2}, {0, 1}, 30] (* or *) CoefficientList[Series[ -(x/(2x^2+6x-1)), {x, 0, 30}], x] (* Harvey P. Dale, Jun 20 2011 *)
PROG
(Sage) [lucas_number1(n, 6, -2) for n in range(0, 21)] # Zerinvary Lajos, Apr 24 2009
(Magma) [n le 2 select n-1 else 6*Self(n-1) + 2*Self(n-2): n in [1..35]]; // Vincenzo Librandi, Sep 18 2016
(PARI) a(n)=([0, 1; 2, 6]^n*[0; 1])[1, 1] \\ Charles R Greathouse IV, Oct 03 2016
KEYWORD
nonn,easy
AUTHOR
Rolf Pleisch, Feb 10 2008, Feb 14 2008
EXTENSIONS
More terms from Joshua Zucker, Feb 23 2008
STATUS
approved
Array T(k,n), read by antidiagonals: T(k,n) = ((k+1)^(n+1)-(-k)^(n+1))/(2k+1).
+10
8
1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 7, 5, 1, 1, 1, 13, 13, 11, 1, 1, 1, 21, 25, 55, 21, 1, 1, 1, 31, 41, 181, 133, 43, 1, 1, 1, 43, 61, 461, 481, 463, 85, 1, 1, 1, 57, 85, 991, 1281, 2653, 1261, 171, 1, 1, 1, 73, 113, 1891, 2821, 10501, 8425, 4039, 341, 1, 1, 1, 91, 145, 3305
OFFSET
0,9
COMMENTS
Square array of solutions of a family of recurrences.
Rows of the array give solutions to the recurrences a(n)=a(n-1)+k(k-1)a(n-2), a(0)=a(1)=1.
Subarray of array in A072024. - Philippe Deléham, Nov 24 2013
LINKS
FORMULA
T(k, n) = ((k+1)^(n+1)-(-k)^(n+1))/(2k+1).
Rows of the array have g.f. 1/((1+kx)(1-(k+1)x)).
EXAMPLE
Rows begin
1, 1, 1, 1, 1, 1, ...
1, 1, 3, 5, 11, 21, ...
1, 1, 7, 13, 55, 133, ...
1, 1, 13, 25, 181, 481, ...
1, 1, 21, 41, 461, 1281, ...
MATHEMATICA
T[n_, k_]:=((n + 1)^(k + 1) - (-n)^(k + 1)) / (2n + 1); Flatten[Table[T[n - k, k], {n, 0, 10}, {k, 0, n}]] (* Indranil Ghosh, Mar 27 2017 *)
PROG
(PARI)
for(k=0, 10, for(n=0, 9, print1(((k+1)^(n+1)-(-k)^(n+1))/(2*k+1), ", "); ); print(); ) \\ Andrew Howroyd, Mar 26 2017
(Python)
def T(n, k): return ((n + 1)**(k + 1) - (-n)**(k + 1)) // (2*n + 1)
for n in range(11):
print([T(n - k, k) for k in range(n + 1)]) # Indranil Ghosh, Mar 27 2017
CROSSREFS
Columns include A002061, A001844, A072025.
Diagonals include A081298, A081299, A081300, A081301, A081302.
KEYWORD
easy,nonn,tabl
AUTHOR
Paul Barry, Mar 17 2003
EXTENSIONS
Name clarified by Andrew Howroyd, Mar 27 2017
STATUS
approved
a(n) = a(n-1) + 20*a(n-2), n >= 2; a(0)=1, a(1)=1.
+10
7
1, 1, 21, 41, 461, 1281, 10501, 36121, 246141, 968561, 5891381, 25262601, 143090221, 648342241, 3510146661, 16476991481, 86679924701, 416219754321, 2149818248341, 10474213334761, 53470578301581, 262954844996801
OFFSET
0,3
COMMENTS
Hankel transform is 1,20,0,0,0,0,0,0,0,0,0,0,... - Philippe Deléham, Nov 02 2008
Zero followed by this sequence gives the inverse binomial transform of A080424. - Paul Curtz, Jun 07 2011
REFERENCES
A. H. Beiler, Recreations in the Theory of Numbers, Dover, N.Y., 1964, pp. 194-196.
LINKS
F. P. Muga II, Extending the Golden Ratio and the Binet-de Moivre Formula, March 2014; Preprint on ResearchGate.
A. K. Whitford, Binet's Formula Generalized, Fibonacci Quarterly, Vol. 15, No. 1, 1979, pp. 21, 24, 29.
FORMULA
a(n) = ((5^(n+1)) - (-4)^(n+1))/9.
G.f.: 1/((1+4*x)*(1-5*x)). - R. J. Mathar, Nov 16 2007
MATHEMATICA
Join[{a=1, b=1}, Table[c=b+20*a; a=b; b=c, {n, 60}]] (* Vladimir Joseph Stephan Orlovsky, Feb 01 2011 *)
PROG
(Magma) [((5^(n+1))-(-4)^(n+1)) div 9: n in [0..40]]; // Vincenzo Librandi, Jun 07 2011
(PARI) a(n)=((5^(n+1))-(-4)^(n+1))/9 \\ Charles R Greathouse IV, Jun 10 2011
KEYWORD
easy,nonn
AUTHOR
Barry E. Williams, Jan 10 2000
EXTENSIONS
More terms from James A. Sellers, Feb 02 2000
STATUS
approved

Search completed in 0.049 seconds