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-10 of 25 results. Next

A334638 Three-column array pPT read by rows: subsequence of primitive Pythagorean triples (x, y, z) with x = A153893^2 - A000079^2, y = 2*A153893*A000079, z = A153893^2 + A000079^2, ordered by increasing z.

Original entry on oeis.org

3, 4, 5, 21, 20, 29, 105, 88, 137, 465, 368, 593, 1953, 1504, 2465, 8001, 6080, 10049, 32385, 24448, 40577, 130305, 98048, 163073, 522753, 392704, 653825, 2094081, 1571840, 2618369, 8382465, 6289408, 10479617, 33542145, 25161728, 41930753, 134193153, 100655104, 167747585, 536821761, 402636800, 671039489, 2147385345, 1610579968, 2684256257
Offset: 0

Views

Author

Ralf Steiner, May 07 2020

Keywords

Comments

Let [h21] = {{1, 3}, {0, 2}} be the matrix [h_2]*[h_1] in Firstov's notation, from eqs. (24) and (39). Then primitive Pythagorean triples (pPT) (x(n), y(n), z(n)) = (u(n)^2 - v(n)^2, 2*u(n)*v(n), u(n)^2 + v(n)^2), with u(n) and v(n) of different parity, gcd(u(n), v(n)) = 1, and u(n) > v(n) > 0, are generated by (u(n), v(n))^T = [h21]^n*(2,1)^T (T for transpose).
For n > 0: (x(n), y(n), z(n)) = (1, 0, 1) (mod 4). Thus some z are Pythagorean primes (A002144).
The triples converge to the proportion (4:3:5) with:
lim_{n->infinity} x(n)/y(n) = 4/3, lim_{n->infinity} y(n)/z(n) = 3/5.
Altitude h(n) = x(n)*y(n)/z(n) is an irreducible fraction because of primitivity.
From Wolfdieter Lang, Jun 13 2020: (Start)
[h21]^n = sqrt(2)^n*(S(n, 3/sqrt(2))*[1_3] + S(n-1, 3/sqrt(2))*(1/sqrt(2))*([h21] - 3*[1_3])) with the Chebyshev S polynomials (A049310).
u(n) = sqrt(2)^n*(2*S(n, 3/sqrt(2)) - (1/sqrt(2))*S(n-1, 3/sqrt(2)))
= A153893(n),
v(n) = sqrt(2)^n*(S(n, 3/sqrt(2)) - (1/sqrt(2))*S(n-1, 3/sqrt(2)))
= A000079(n). Proof from the recurrence, using the Cayley-Hamilton theorem.
With the monic Chebyshev T polynomials, called R in A127672:
x(n)/3 = 2^(n+1)*(R(2*(n+1), 3/sqrt(2)) - (sqrt(2)/3)*R(2*n+1,3/sqrt(2)) - 1) = A171477(n),
y(n)/4 = 3*2^(n-1)*(sqrt(2)*R(2*n+1,3/sqrt(2)) - R(2*n,3/sqrt(2)) - 1/3)
= A010036(n),
z(n) = 3*2^(n+1)*((3/sqrt(2))*R(2*n+1, 3/sqrt(2)) - (4/3)*R(2*n,3/sqrt(2)) - 1).
Using 2^n*Rnx(2*n, 3/sqrt(2)) = A052539(n) = 2^(2*n) + 1, and
2^(n)*(sqrt(2)/3)*Rnx(2*n+1, 3/sqrt(2)) = A007583(n) = (2^(2*n + 1) + 1)/3,
produces the explicit formulas given by the author in the formula section.
G.f.s for {x(n)} G0(x) = 3/((1 - 4*x)*(1 - 2*x)*(1 - x)), for {y(n)} G1(x) = 4*(1-x)/((1 - 4*x)*(1 - 2*x)), and for {z(n)} = (5 - 6*x + 4*x^2)/((1 - 4*x)*(1 - 2*x)*(1 - x)). This produces the g.f. for the array, read as sequence {a(n)}: G(x) = G0(x^3) + x*G1(x^3) + x^2*G2(x^3) given in the formula section by Colin Barker.
(End)

Examples

			The three-column array pPT(n,k) begins:
n\k        0        1         2
-------------------------------
0:         3        4         5
1:        21       20        29
2:       105       88       137
3:       465      368       593
4:      1953     1504      2465
5:      8001     6080     10049
6:     32385    24448     40577
7:    130305    98048    163073
8:    522753   392704    653825
9:   2094081  1571840   2618369
10:  8382465  6289408  10479617
... - _Wolfdieter Lang_, Jun 13 2020
		

Crossrefs

Programs

  • Mathematica
    h21={{1, 3}, {0, 2}}; l = {}; Do[v = MatrixPower[h21, n, {2, 1}]; p = v[[1]]; q = v[[2]];
    a = p^2 - q^2; b = 2 p q; c = p^2 + q^2; l = AppendTo[l, {a, b, c}], {n, 0, 14}]; l // Flatten
  • PARI
    Vec((3 + 4*x + 5*x^2 - 8*x^4 - 6*x^5 + 4*x^7 + 4*x^8) / ((1 - x)*(1 + x + x^2)*(1 - 2*x^3)*(1 - 4*x^3)) + O(x^35)) \\ Colin Barker, Jun 12 2020

Formula

The three-column array PT(n, k) is for k = 0, 1, 2: x(n), y(n), z(n), for n >= 0, with
x(n) = a(3*n + 0) = A153893(n)^2 - A000079(n)^2 = 1 - 3*2^(n+1) + 2^(2*n+3) = binomial(2^(n+2) - 1, 2) = 3*A171477(n),
y(n) = a(3*n + 1) = 2*A153893(n)*A000079(n) = 2^(n+1)*(-1 + 3*2^n) = 4*A010036(n),
z(n) = a(3*n + 2) = A153893(n)^2 + A000079(n)^2 = 1 - 6*2^n + 10*2^(2*n).
From Colin Barker, May 08 2020: (Start)
G.f. (read as sequence {a(n)}): (3 + 4*x + 5*x^2 - 8*x^4 - 6*x^5 + 4*x^7 + 4*x^8) / ((1 - x)*(1 + x + x^2)*(1 - 2*x^3)*(1 - 4*x^3)).
a(n) = 7*a(n-3) - 14*a(n-6) + 8*a(n-9), for n > 8.
(End)

Extensions

Edited, and corrected proportion by Wolfdieter Lang, Jun 13 2020
Minor grammatical edits. - N. J. A. Sloane, Sep 12 2020

A033484 a(n) = 3*2^n - 2.

Original entry on oeis.org

1, 4, 10, 22, 46, 94, 190, 382, 766, 1534, 3070, 6142, 12286, 24574, 49150, 98302, 196606, 393214, 786430, 1572862, 3145726, 6291454, 12582910, 25165822, 50331646, 100663294, 201326590, 402653182, 805306366, 1610612734, 3221225470
Offset: 0

Views

Author

Keywords

Comments

Number of nodes in rooted tree of height n in which every node (including the root) has valency 3.
Pascal diamond numbers: reflect Pascal's n-th triangle vertically and sum all elements. E.g., a(3)=1+(1+1)+(1+2+1)+(1+1)+1. - Paul Barry, Jun 23 2003
Number of 2 X n binary matrices avoiding simultaneously the right-angled numbered polyomino patterns (ranpp) (00;1), (10;0) and (11;0). An occurrence of a ranpp (xy;z) in a matrix A=(a(i,j)) is a triple (a(i1,j1), a(i1,j2), a(i2,j1)) where i1 < i2 and j1 < j2 and these elements are in the same relative order as those in the triple (x,y,z). - Sergey Kitaev, Nov 11 2004
Binomial and inverse binomial transform are in A001047 (shifted) and A122553. - R. J. Mathar, Sep 02 2008
a(n) = (Sum_{k=0..n-1} a(n)) + (2*n + 1); e.g., a(3) = 22 = (1 + 4 + 10) + 7. - Gary W. Adamson, Jan 21 2009
Let P(A) be the power set of an n-element set A and R be a relation on P(A) such that for all x, y of P(A), xRy if either 0) x is a proper subset of y or y is a proper subset of x and x and y are disjoint, or 1) x equals y. Then a(n) = |R|. - Ross La Haye, Mar 19 2009
Equals the Jacobsthal sequence A001045 convolved with (1, 3, 4, 4, 4, 4, 4, ...). - Gary W. Adamson, May 24 2009
Equals the eigensequence of a triangle with the odd integers as the left border and the rest 1's. - Gary W. Adamson, Jul 24 2010
An elephant sequence, see A175655. For the central square four A[5] vectors, with decimal values 58, 154, 178 and 184, lead to this sequence. For the corner squares these vectors lead to the companion sequence A097813. - Johannes W. Meijer, Aug 15 2010
a(n+2) is the integer with bit string "10" * "1"^n * "10".
a(n) = A027383(2n). - Jason Kimberley, Nov 03 2011
a(n) = A153893(n)-1 = A083416(2n+1). - Philippe Deléham, Apr 14 2013
a(n) = A082560(n+1,A000079(n)) = A232642(n+1,A128588(n+1)). - Reinhard Zumkeller, May 14 2015
a(n) is the sum of the entries in the n-th and (n+1)-st rows of Pascal's triangle minus 2. - Stuart E Anderson, Aug 27 2017
Also the number of independent vertex sets and vertex covers in the complete tripartite graph K_{n,n,n}. - Eric W. Weisstein, Sep 21 2017
Apparently, a(n) is the least k such that the binary expansion of A000045(k) ends with exactly n+1 ones. - Rémy Sigrist, Sep 25 2021
a(n) is the number of root ancestral configurations for a pair consisting of a matching gene tree and species tree with the modified lodgepole shape and n+1 cherry nodes. - Noah A Rosenberg, Jan 16 2025

Examples

			Binary: 1, 100, 1010, 10110, 101110, 1011110, 10111110, 101111110, 1011111110, 10111111110, 101111111110, 1011111111110, 10111111111110,
G.f. = 1 + 4*x + 10*x^2 + 22*x^3 + 46*x^4 + 94*x^5 + 190*x^6 + 382*x^7 + ...
		

References

  • J. Riordan, Series-parallel realization of the sum modulo 2 of n switching variables, in Claude Elwood Shannon: Collected Papers, edited by N. J. A. Sloane and A. D. Wyner, IEEE Press, NY, 1993, pp. 877-878.

Crossrefs

Programs

  • GAP
    List([0..35], n-> 3*2^n -2); # G. C. Greubel, Nov 18 2019
  • Haskell
    a033484 = (subtract 2) . (* 3) . (2 ^)
    a033484_list = iterate ((subtract 2) . (* 2) . (+ 2)) 1
    -- Reinhard Zumkeller, Apr 23 2013
    
  • Magma
    [3*2^n-2: n in [1..36]]; // Vincenzo Librandi, Nov 22 2010
    
  • Maple
    with(combinat):a:=n->stirling2(n,2)+stirling2(n+1,2): seq(a(n), n=1..35); # Zerinvary Lajos, Oct 07 2007
    a[0]:=0:a[1]:=1:for n from 2 to 50 do a[n]:=(a[n-1]+1)*2 od: seq(a[n], n=1..35); # Zerinvary Lajos, Feb 22 2008
  • Mathematica
    Table[3 2^n - 2, {n, 0, 35}] (* Vladimir Joseph Stephan Orlovsky, Dec 16 2008 *)
    (* Start from Eric W. Weisstein, Sep 21 2017 *)
    3*2^Range[0, 35] - 2
    LinearRecurrence[{3, -2}, {1, 4}, 36]
    CoefficientList[Series[(1+x)/(1-3x+2x^2), {x, 0, 35}], x] (* End *)
  • PARI
    a(n) = 3<Charles R Greathouse IV, Nov 02 2011
    
  • Sage
    [3*2^n -2 for n in (0..35)] # G. C. Greubel, Nov 18 2019
    

Formula

G.f.: (1+x)/(1-3*x+2*x^2).
a(n) = 2*(a(n-1) + 1) for n>0, with a(0)=1.
a(n) = A007283(n) - 2.
G.f. is equivalent to (1-2*x-3*x^2)/((1-x)*(1-2*x)*(1-3*x)). - Paul Barry, Apr 28 2004
From Reinhard Zumkeller, Oct 09 2004: (Start)
A099257(a(n)) = A099258(a(n)) = a(n).
a(n) = 2*A055010(n) = (A068156(n) - 1)/2. (End)
Row sums of triangle A130452. - Gary W. Adamson, May 26 2007
Row sums of triangle A131110. - Gary W. Adamson, Jun 15 2007
Binomial transform of (1, 3, 3, 3, ...). - Gary W. Adamson, Oct 17 2007
Row sums of triangle A051597 (a triangle generated from Pascal's rule given right and left borders = 1, 2, 3, ...). - Gary W. Adamson, Nov 04 2007
Equals A132776 * [1/1, 1/2, 1/3, ...]. - Gary W. Adamson, Nov 16 2007
a(n) = Sum_{k=0..n} A112468(n,k)*3^k. - Philippe Deléham, Feb 23 2014
a(n) = -(2^n) * A036563(1-n) for all n in Z. - Michael Somos, Jul 04 2017
E.g.f.: 3*exp(2*x) - 2*exp(x). - G. C. Greubel, Nov 18 2019

A036044 BCR(n): write in binary, complement, reverse.

Original entry on oeis.org

1, 0, 2, 0, 6, 2, 4, 0, 14, 6, 10, 2, 12, 4, 8, 0, 30, 14, 22, 6, 26, 10, 18, 2, 28, 12, 20, 4, 24, 8, 16, 0, 62, 30, 46, 14, 54, 22, 38, 6, 58, 26, 42, 10, 50, 18, 34, 2, 60, 28, 44, 12, 52, 20, 36, 4, 56, 24, 40, 8, 48, 16, 32, 0, 126, 62, 94, 30, 110, 46, 78, 14, 118, 54, 86
Offset: 0

Views

Author

Keywords

Comments

a(0) could be considered to be 0 if the binary representation of zero were chosen to be the empty string. - Jason Kimberley, Sep 19 2011
From Bernard Schott, Jun 15 2021: (Start)
Except for a(0) = 1, every term is even.
For each q >= 0, there is one and only one odd number h such that a(n) = 2*q iff n = h*2^m-1 for m >= 1 when q = 0, and for m >= 0 when q >= 1 (see A345401 and some examples below).
a(n) = 0 iff n = 2^m-1 for m >= 1 (Mersenne numbers) (A000225).
a(n) = 2 iff n = 3*2^m-1 for m >= 0 (A153893).
a(n) = 4 iff n = 7*2^m-1 for m >= 0 (A086224).
a(n) = 6 iff n = 5*2^m-1 for m >= 0 (A153894).
a(n) = 8 iff n = 15*2^m-1 for m >= 0 (A196305).
a(n) = 10 iff n = 11*2^m-1 for m >= 0 (A086225).
a(n) = 12 iff n = 13*2^m-1 for m >= 0 (A198274).
For k >= 1, a(n) = 2^k iff n = (2^(k+1)-1)*2^m - 1 for m >= 0.
Explanation for a(n) = 2:
For m >= 0, A153893(m) = 3*2^m-1 -> 1011...11 -> 0100...00 -> 10 -> 2 where 1011...11_2 is 10 followed by m 1's. (End)

Examples

			4 -> 100 -> 011 -> 110 -> 6.
		

Crossrefs

Cf. A035928 (fixed points), A195063, A195064, A195065, A195066.
Indices of terms 0, 2, 4, 6, 8, 10, 12, 14, 18, 22, 26, 30: A000225 \ {0}, A153893, A086224, A153894, A196305, A086225, A198274, A052996\{1,3}, A291557, A198276, A171389, A198275.

Programs

  • Haskell
    import Data.List (unfoldr)
    a036044 0 = 1
    a036044 n = foldl (\v d -> 2 * v + d) 0 (unfoldr bc n) where
       bc 0 = Nothing
       bc x = Just (1 - m, x') where (x',m) = divMod x 2
    -- Reinhard Zumkeller, Sep 16 2011
    
  • Magma
    A036044:=func; // Jason Kimberley, Sep 19 2011
    
  • Maple
    A036044 := proc(n)
        local bcr ;
        if n = 0 then
            return 1;
        end if;
        convert(n,base,2) ;
        bcr := [seq(1-i,i=%)] ;
        add(op(-k,bcr)*2^(k-1),k=1..nops(bcr)) ;
    end proc:
    seq(A036044(n),n=0..200) ; # R. J. Mathar, Nov 06 2017
  • Mathematica
    dtn[ L_ ] := Fold[ 2#1+#2&, 0, L ]; f[ n_ ] := dtn[ Reverse[ 1-IntegerDigits[ n, 2 ] ] ]; Table[ f[ n ], {n, 0, 100} ]
    Table[FromDigits[Reverse[IntegerDigits[n,2]/.{1->0,0->1}],2],{n,0,80}] (* Harvey P. Dale, Mar 08 2015 *)
  • PARI
    a(n)=fromdigits(Vecrev(apply(n->1-n,binary(n))),2) \\ Charles R Greathouse IV, Apr 22 2015
    
  • Python
    def comp(s): z, o = ord('0'), ord('1'); return s.translate({z:o, o:z})
    def BCR(n): return int(comp(bin(n)[2:])[::-1], 2)
    print([BCR(n) for n in range(75)]) # Michael S. Branicky, Jun 14 2021
    
  • Python
    def A036044(n): return -int((s:=bin(n)[-1:1:-1]),2)-1+2**len(s) # Chai Wah Wu, Feb 04 2022

Formula

a(2n) = 2*A059894(n), a(2n+1) = a(2n) - 2^floor(log_2(n)+1). - Ralf Stephan, Aug 21 2003
Conjecture: a(n) = (-1)^A023416(n)*b(n) for n > 0 with a(0) = 1 where b(2^m) = (-1)^m*(2^(m+1) - 2) for m >= 0, b(2n+1) = b(n) for n > 0, b(2n) = b(n) + b(n - 2^f(n)) + b(2n - 2^f(n)) for n > 0 and where f(n) = A007814(n) (see A329369). - Mikhail Kurkov, Dec 13 2024

A086224 a(n) = 7*2^n - 1.

Original entry on oeis.org

6, 13, 27, 55, 111, 223, 447, 895, 1791, 3583, 7167, 14335, 28671, 57343, 114687, 229375, 458751, 917503, 1835007, 3670015, 7340031, 14680063, 29360127, 58720255, 117440511, 234881023, 469762047, 939524095, 1879048191, 3758096383, 7516192767, 15032385535, 30064771071
Offset: 0

Views

Author

Marco Matosic, Jul 27 2003

Keywords

Comments

a(n) = A164874(n+2,2); subsequence of A030130. - Reinhard Zumkeller, Aug 29 2009
Let A be the Hessenberg matrix of order n, defined by: A[1,j]=1, A[i,i]:=-3, A[i,i-1]=-1, and A[i,j]=0 otherwise. Then, for n>=1, a(n-1)=(-1)^n*charpoly(A,-5). - Milan Janjic, Jan 27 2010

Crossrefs

Other sequences with recurrence a(n+1) = 2*a(n) + 1 are:
a(0) = 2 gives A153893, a(0)=3 essentially A126646.
a(0) = 4 gives A153894, a(0)=5 essentially A153893.
a(0) = 7 gives essentially A000225.
a(0) = 8 gives A052996 except for some initial terms,
a(0) = 9 is essentially A153894.
a(0) = 10 gives A086225,
a(0) = 11 is essentially A153893.
a(0) = 13 is essentially A086224.

Programs

  • Mathematica
    7*2^Range[0,30]-1 (* Harvey P. Dale, May 09 2018 *)
  • PARI
    a(n)=7<Charles R Greathouse IV, Sep 24 2015

Formula

a(n+1) = 2*a(n) + 1.
G.f.: (6-5*x)/((1-x)*(1-2*x)). - Jaume Oliver Lafont, Sep 14 2009
a(n-1)^2 + a(n) = (7*2^(n-1))^2. - Vincenzo Librandi, Aug 08 2010
a(n) = (A052940(n+1) + A000225(n+3))/2. - Gennady Eremin, Aug 31 2023
From Elmo R. Oliveira, Apr 22 2025: (Start)
E.g.f.: exp(x)*(7*exp(x) - 1).
a(n) = 3*a(n-1) - 2*a(n-2). (End)

Extensions

More terms from David Wasserman, Feb 22 2005

A181490 Numbers k such that 3*2^k-1 and 3*2^k+1 are twin primes (A001097).

Original entry on oeis.org

1, 2, 6, 18
Offset: 1

Views

Author

M. F. Hasler, Oct 30 2010

Keywords

Comments

Sequences A181491 and A181492 list the corresponding primes.
No more terms below three million. - Charles R Greathouse IV, Mar 14 2011
Intersection of A002235 and A002253. - Jeppe Stig Nielsen, Mar 05 2018

Crossrefs

Programs

  • GAP
    Filtered([1..300],k->IsPrime(3*2^k-1) and IsPrime(3*2^k+1)); # Muniru A Asiru, Mar 11 2018
  • Maple
    a:=k->`if`(isprime(3*2^k-1) and isprime(3*2^k+1),k,NULL); seq(a(k),k=1..1000); # Muniru A Asiru, Mar 11 2018
  • Mathematica
    fQ[n_] := PrimeQ[3*2^n - 1] && PrimeQ[3*2^n + 1]; k = 1; lst= {}; While[k < 15001, If[fQ@k, AppendTo[lst, k]; Print@k]; k++ ] (* Robert G. Wilson v, Nov 05 2010 *)
    Select[Range[20],AllTrue[3*2^#+{1,-1},PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Sep 24 2014 *)
  • PARI
    for( k=1,999, ispseudoprime(3<
    				

Formula

Equals { k | A007283(k) in A014574 } = { k | A153893(k) in A001359 }.

Extensions

Pari program repaired by Charles R Greathouse IV, Mar 14 2011

A075300 Array A read by antidiagonals upwards: A(n, k) = array A054582(n,k) - 1 = 2^n*(2*k+1) - 1 with n,k >= 0.

Original entry on oeis.org

0, 1, 2, 3, 5, 4, 7, 11, 9, 6, 15, 23, 19, 13, 8, 31, 47, 39, 27, 17, 10, 63, 95, 79, 55, 35, 21, 12, 127, 191, 159, 111, 71, 43, 25, 14, 255, 383, 319, 223, 143, 87, 51, 29, 16, 511, 767, 639, 447, 287, 175, 103, 59, 33, 18, 1023, 1535, 1279, 895, 575, 351, 207, 119
Offset: 0

Views

Author

Antti Karttunen, Sep 12 2002

Keywords

Comments

From Philippe Deléham, Feb 19 2014: (Start)
A(0,k) = 2*k = A005843(k),
A(1,k) = 4*k + 1 = A016813(k),
A(2,k) = 8*k + 3 = A017101(k),
A(n,0) = A000225(n),
A(n,1) = A153893(n),
A(n,2) = A153894(n),
A(n,3) = A086224(n),
A(n,4) = A052996(n+2),
A(n,5) = A086225(n),
A(n,6) = A198274(n),
A(n,7) = A238087(n),
A(n,8) = A198275(n),
A(n,9) = A198276(n),
A(n,10) = A171389(n). (End)
A permutation of the nonnegative integers. - Alzhekeyev Ascar M, Jun 05 2016
The values in array row n, when expressed in binary, have n trailing 1-bits. - Ruud H.G. van Tol, Mar 18 2025

Examples

			The array A begins:
   0    2    4    6    8   10   12   14   16   18 ...
   1    5    9   13   17   21   25   29   33   37 ...
   3   11   19   27   35   43   51   59   67   75 ...
   7   23   39   55   71   87  103  119  135  151 ...
  15   47   79  111  143  175  207  239  271  303 ...
  31   95  159  223  287  351  415  479  543  607 ...
  ... - _Philippe Deléham_, Feb 19 2014
From _Wolfdieter Lang_, Jan 31 2019: (Start)
The triangle T begins:
   n\k   0    1    2   3   4   5   6   7  8  9 10 ...
   0:    0
   1:    1    2
   2:    3    5    4
   3:    7   11    9   6
   4:   15   23   19  13   8
   5    31   47   39  27  17  10
   6:   63   95   79  55  35  21  12
   7:  127  191  159 111  71  43  25  14
   8:  255  383  319 223 143  87  51  29 16
   9:  511  767  639 447 287 175 103  59 33 18
  10: 1023 1535 1279 895 575 351 207 119 67 37 20
  ...
T(3, 1) = 2^2*(2*1+1) - 1 = 12 - 1 = 11.  (End)
		

Crossrefs

Inverse permutation: A075301. Transpose: A075302. The X-projection is given by A007814(n+1) and the Y-projection A025480.

Programs

  • Maple
    A075300bi := (x,y) -> (2^x * (2*y + 1))-1;
    A075300 := n -> A075300bi(A025581(n), A002262(n));
    A002262 := n -> n - binomial(floor((1/2)+sqrt(2*(1+n))),2);
    A025581 := n -> binomial(1+floor((1/2)+sqrt(2*(1+n))),2) - (n+1);
  • Mathematica
    Table[(2^# (2 k + 1)) - 1 &[m - k], {m, 0, 10}, {k, 0, m}] (* Michael De Vlieger, Jun 05 2016 *)

Formula

From Wolfdieter Lang, Jan 31 2019: (Start)
Array A(n, k) = 2^n*(2*k+1) - 1, for n >= 0 and m >= 0.
The triangle is T(n, k) = A(n-k, k) = 2^(n-k)*(2*k+1) - 1, n >= 0, k=0..n.
See also A054582 after subtracting 1. (End)
From Ruud H.G. van Tol, Mar 17 2025: (Start)
A(0, k) is even. For n > 0, A(n, k) is odd and (3 * A(n, k) + 1) / 2 = A(n-1, 3*k+1).
A(n, k) = 2^n - 1 (mod 2^(n+1)) (equivalent to the comment about trailing 1-bits). (End)

A083416 Add 1, double, add 1, double, etc.

Original entry on oeis.org

1, 2, 4, 5, 10, 11, 22, 23, 46, 47, 94, 95, 190, 191, 382, 383, 766, 767, 1534, 1535, 3070, 3071, 6142, 6143, 12286, 12287, 24574, 24575, 49150, 49151, 98302, 98303, 196606, 196607, 393214, 393215, 786430, 786431, 1572862, 1572863, 3145726, 3145727, 6291454
Offset: 1

Views

Author

N. J. A. Sloane, Jun 10 2003

Keywords

Crossrefs

Programs

  • Haskell
    a083416 n = a083416_list !! (n-1)
    a083416_list = 1 : f 2 1 where
       f x y = z : f (x+1) z where z = (1 + x `mod` 2) * y + 1 - x `mod` 2
    -- Reinhard Zumkeller, Feb 27 2012
  • Magma
    [Floor(3*2^((2*n-(-1)^n-3)/4)+((-1)^n-3)/2): n in [1..50]]; // Vincenzo Librandi, Aug 17 2011
    
  • Maple
    A083416 := proc(n) if type(n,'even') then 3*2^(n/2-1)-1 ; else 3*2^((n-1)/2)-2 ; end if; end proc: # R. J. Mathar, Feb 16 2011
  • Mathematica
    a=0; b=0; lst={a,b}; Do[z=a+b+1; AppendTo[lst,z]; a=b; b=z; z=b+1; AppendTo[lst,z]; a=b; b=z,{n,50}]; lst (* Vladimir Joseph Stephan Orlovsky, Feb 16 2010 *)
    LinearRecurrence[{0,3,0,-2},{1,2,4,5},40] (* Harvey P. Dale, Nov 18 2014 *)

Formula

G.f.: x*(1+2*x+x^2-x^3)/(1-x^2)/(1-2*x^2).
a(2*n) = 3*2^(n-1)-1, a(2*n+1) = 3*2^n-2.
a(n) = A081026(n+1)-1.
a(n) = 3*2^((2*n-(-1)^n-3)/4)+((-1)^n-3)/2. - Bruno Berselli, Feb 17 2011
For n > 1: a(n) = (1 + n mod 2) * a(n-1) + 1 - n mod 2. - Reinhard Zumkeller, Feb 27 2012
a(2n+1) = A033484(n), a(2n) = A153893(n). - Philippe Deléham, Apr 14 2013
E.g.f.: (3*cosh(sqrt(2)*x) - 4*sinh(x) + 3*sqrt(2)*sinh(sqrt(2)*x) - 2*cosh(x) - 1)/2. - Stefano Spezia, Jul 11 2023

Extensions

More terms from Donald Sampson (marsquo(AT)hotmail.com), Dec 04 2003
Corrected by T. D. Noe, Nov 02 2006

A182464 a(n) = 3a(n-1) - 2a(n-2) with a(0)=24 and a(1)=60.

Original entry on oeis.org

24, 60, 132, 276, 564, 1140, 2292, 4596, 9204, 18420, 36852, 73716, 147444, 294900, 589812, 1179636, 2359284, 4718580, 9437172, 18874356, 37748724, 75497460, 150994932, 301989876, 603979764, 1207959540, 2415919092, 4831838196, 9663676404, 19327352820, 38654705652
Offset: 0

Views

Author

Odimar Fabeny, Apr 30 2012

Keywords

Comments

Number of vertices into building blocks of 3d objects with 6 vertices.

Examples

			a(0) = 6+12+6;
a(1) = 6+12+24+12+6;
a(2) = 6+12+24+48+24+12+6;
a(3) = 6+12+24+48+96+48+24+12+6.
		

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[-((12 (x - 2))/(2 x^2 - 3 x + 1)), {x, 0, 40}], x] (* Vincenzo Librandi, Jun 01 2014 *)
    LinearRecurrence[{3,-2},{24,60},40] (* Harvey P. Dale, May 27 2018 *)

Formula

a(n) = a(n-1)*2 + 12.
a(n) = 12*A153893(n). - Michel Marcus, Jun 01 2014
G.f.: -((12*(x-2))/(2*x^2-3*x+1)). - Vincenzo Librandi, Jun 01 2014

A182467 a(n) = 3a(n-1) - 2a(n-2) with a(0)=36 and a(1)=90.

Original entry on oeis.org

36, 90, 198, 414, 846, 1710, 3438, 6894, 13806, 27630, 55278, 110574, 221166, 442350, 884718, 1769454, 3538926, 7077870, 14155758, 28311534, 56623086, 113246190, 226492398, 452984814, 905969646, 1811939310, 3623878638, 7247757294, 14495514606, 28991029230
Offset: 0

Views

Author

Odimar Fabeny, Apr 30 2012

Keywords

Comments

Number of vertices into building blocks of 3d objects with 9 vertices.

Examples

			a(0) = 9+18+9;
a(1) = 9+18+36+18+9;
a(2) = 9+18+36+72+36+18+9;
a(3) = 9+18+36+72+144+72+36+18+9.
		

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{3,-2},{36,90},30] (* or *) CoefficientList[Series[(-18(x-2))/(1-3x+2x^2),{x,0,30}],x] (* Harvey P. Dale, Apr 29 2013 *)

Formula

a(n) = a(n-1)*2 + 18
G.f.: -((18*(x-2))/(2*x^2-3*x+1)). - Harvey P. Dale, Apr 29 2013
a(n) = 18*A153893(n). - Michel Marcus, Jun 01 2014

A182462 a(n) = 3a(n-1) - 2a(n-2) with a(0)=20 and a(1)=50.

Original entry on oeis.org

20, 50, 110, 230, 470, 950, 1910, 3830, 7670, 15350, 30710, 61430, 122870, 245750, 491510, 983030, 1966070, 3932150, 7864310, 15728630, 31457270, 62914550, 125829110, 251658230, 503316470, 1006632950, 2013265910, 4026531830, 8053063670, 16106127350
Offset: 0

Views

Author

Odimar Fabeny, Apr 30 2012

Keywords

Comments

Number of vertices into building blocks of 3d objects with 5 vertices.

Examples

			a(0) = 5+10+5;
a(1) = 5+10+20+10+5;
a(2) = 5+10+20+40+20+10+5;
a(3) = 5+10+20+40+80+40+20+10+5.
		

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[-((10 (x - 2))/(2 x^2 - 3 x + 1)), {x, 0, 40}], x] (* Vincenzo Librandi, Jun 02 2014 *)

Formula

a(n) = a(n-1)*2 + 10.
a(n) = 10*A153893(n). - Michel Marcus, Jun 01 2014
G.f.: -((10*(x - 2))/(2*x^2 - 3*x + 1)). - Vincenzo Librandi, Jun 02 2014
Showing 1-10 of 25 results. Next