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 10 results.

A092526 Decimal expansion of (2/3)*cos( (1/3)*arccos(29/2) ) + 1/3, the real root of x^3 - x^2 - 1.

Original entry on oeis.org

1, 4, 6, 5, 5, 7, 1, 2, 3, 1, 8, 7, 6, 7, 6, 8, 0, 2, 6, 6, 5, 6, 7, 3, 1, 2, 2, 5, 2, 1, 9, 9, 3, 9, 1, 0, 8, 0, 2, 5, 5, 7, 7, 5, 6, 8, 4, 7, 2, 2, 8, 5, 7, 0, 1, 6, 4, 3, 1, 8, 3, 1, 1, 1, 2, 4, 9, 2, 6, 2, 9, 9, 6, 6, 8, 5, 0, 1, 7, 8, 4, 0, 4, 7, 8, 1, 2, 5, 8, 0, 1, 1, 9, 4, 9, 0, 9, 2, 7, 0, 0, 6, 4, 3, 8
Offset: 1

Views

Author

N. J. A. Sloane, Apr 07 2004

Keywords

Comments

This is the limit x of the ratio N(n+1)/N(n) for n -> infinity of the Narayana sequence N(n) = A000930(n). The real root of x^3 - x^2 - 1. See the formula section. - Wolfdieter Lang, Apr 24 2015
This is the fourth smallest Pisot number. - Iain Fox, Oct 13 2017
Sometimes called the supergolden ratio or Narayana's cows constant, and denoted by the symbol psi. - Ed Pegg Jr, Feb 01 2019

Examples

			1.46557123187676802665673122521993910802557756847228570164318311124926...
		

References

  • S. R. Finch, Mathematical Constants, Cambridge, 2003, Section 1.2.3.
  • Paul J. Nahin, The Logician and the Engineer, How George Boole and Claude Shannon Created the Information Age, Princeton University Press, Princeton and Oxford, 2013, Chap. 7: Some Combinational Logic Examples, Section 7.1: Channel Capacity, Shannon's Theorem, and Error-Detection Theory, page 120.

Crossrefs

Other Pisot numbers: A060006, A086106, A228777, A293506, A293508, A293509, A293557.
Cf. A381124 (numerators of convergents).
Cf. A381125 (denominators of convergents).

Programs

  • Mathematica
    RealDigits[(2 Cos[ ArcCos[ 29/2]/3] + 1)/3, 10, 111][[1]] (* Robert G. Wilson v, Apr 12 2004 *)
    RealDigits[ Solve[ x^3 - x^2 - 1 == 0, x][[1, 1, 2]], 10, 111][[1]] (* Robert G. Wilson v, Oct 10 2013 *)
  • PARI
    allocatemem(932245000); default(realprecision, 20080); x=solve(x=1, 2, x^3 - x^2 - 1); for (n=1, 20000, d=floor(x); x=(x-d)*10; write("b092526.txt", n, " ", d));  \\ Harry J. Smith, Jun 21 2009

Formula

The real root of x^3 - x^2 - 1. - Franklin T. Adams-Watters, Oct 12 2006
The only real irrational root of x^4-x^2-x-1 (-1 is also a root). [Nahim]
Equals (2/3)*cos( (1/3)*arccos(29/2) ) + 1/3.
Equals 1 + A088559.
Equals (1/6)*(116+12*sqrt(93))^(1/3) + 2/(3*(116+12*sqrt(93))^(1/3)) + 1/3. - Vaclav Kotesovec, Dec 18 2014
Equals 1/A263719. - Alois P. Heinz, Apr 15 2018
Equals (1 + 1/r + r)/3 where r = ((29 + sqrt(837))/2)^(1/3). - Peter Luschny, Apr 04 2020
Equals (1/3)*(1 + ((1/2)*(29 + (3*sqrt(93))))^(1/3) + ((1/2)*(29 - 3*sqrt(93)))^(1/3)). See A075778. - Wolfdieter Lang, Aug 17 2022

A263719 Decimal expansion of the real root r of r^3 + r - 1 = 0.

Original entry on oeis.org

6, 8, 2, 3, 2, 7, 8, 0, 3, 8, 2, 8, 0, 1, 9, 3, 2, 7, 3, 6, 9, 4, 8, 3, 7, 3, 9, 7, 1, 1, 0, 4, 8, 2, 5, 6, 8, 9, 1, 1, 8, 8, 5, 8, 1, 8, 9, 7, 9, 9, 8, 5, 7, 7, 8, 0, 3, 7, 2, 8, 6, 0, 6, 6, 3, 9, 8, 9, 6, 6, 7, 8, 6, 8, 6, 9, 9, 8, 0, 2, 1, 0, 8, 1, 7, 3, 2, 0, 4, 3, 7, 8, 6, 2, 0, 5, 1, 2, 8, 2, 9, 5, 5, 9, 3, 3, 1, 8, 7, 6
Offset: 0

Views

Author

Paul D. Hanna, Oct 24 2015

Keywords

Comments

Constant from Narayana's cows sequence: Limit A000930(n)/A000930(n+1) = r.
Reciprocal of constant described by A092526.

Examples

			0.682327803828019327369483739711048256891188581897998577803728606639896...
		

Crossrefs

Programs

  • Mathematica
    RealDigits[ ((Sqrt[93] + 9)/18)^(1/3) - ((Sqrt[93] - 9)/18)^(1/3), 10, 100][[1]] (* G. C. Greubel, May 01 2017 *)
  • PARI
    a(n) = my(r = (sqrt(93)/18 + 1/2)^(1/3) - (sqrt(93)/18 - 1/2)^(1/3)); floor(r*10^(n+1))%10
    for(n=0,120,print1(a(n),", "))
    
  • PARI
    solve(r=0, 1,  r^3 + r - 1 ) \\ Michel Marcus, Oct 25 2015

Formula

r = (sqrt(93)/18 + 1/2)^(1/3) - (sqrt(93)/18 - 1/2)^(1/3).
Constant r satisfies:
(1) 1/(1 - r*i) = (r + r^2*i) where i^2 = -1.
(2) r = real( 1/(1 - r*i) ).
(3) r = norm( 1/(1 - r*i) ).
(4) r = r^2 + r^4.
Equals 1/A092526. - Vaclav Kotesovec, Nov 27 2017

A005154 a(0) = 1, a(1) = 2; thereafter a(n) = 3*a(n-1)^2 - 2*a(n-2)^4.

Original entry on oeis.org

1, 2, 10, 268, 195472, 104310534400, 29722161121961969778688, 2413441860555924454205324333893477339897004032, 15913289476042091181119569948276231488639535067163704670852319029791565485433738366445158400
Offset: 0

Views

Author

Keywords

Comments

A lower bound for maximal number of stable matchings (or marriages) possible with 2^n men and 2^n women for suitable preference ordering.

References

  • D. Gusfield and R. W. Irving, The Stable Marriage Problem: Structure and Algorithms. MIT Press, 1989, p. 25.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Recurrence is similar to A076725.

Programs

  • Magma
    I:=[1,2]; [m le 2 select I[m] else 3*Self(m-1)^2-2*Self(m-2)^4: m in [1..9]]; // Marius A. Burtea, Aug 09 2019
  • Maple
    A005154 := proc(n) option remember; if n <= 1 then n+1 else 3*A005154(n-1)^2-2*A005154(n-2)^4; fi; end;
  • Mathematica
    RecurrenceTable[{a[0]==1,a[1]==2,a[n]==3a[n-1]^2-2a[n-2]^4},a,{n,8}] (* Harvey P. Dale, Mar 19 2012 *)

Formula

a(n) ~ r*s^(2^n), where r = (sqrt(3)-1)/2 = 0.366025... and s = 2.28014... . - Clayton Thomas, Aug 09 2019
The Karlin, Gharan, Weber upper bound is C^(2^n) for a large C. - Domotor Palvolgyi, Feb 09 2020

Extensions

Formula and comment swapped by N. J. A. Sloane, Mar 01 2020

A338293 Number of matchings in the complete binary tree of n rows.

Original entry on oeis.org

1, 1, 3, 15, 495, 467775, 448046589375, 396822986774382287109375, 316789536051348354157896789538095888519287109375
Offset: 0

Views

Author

Kevin Ryde, Oct 21 2020

Keywords

Comments

A recurrence is formed by considering the root vertex matched or unmatched and a(n-1) or a(n-2) matchings in the subtrees below.
unmatched matched matched
/ \ / \\ // \
any any any matched matched any
/ \ / \
any any any any
so:
a(n-1)^2 + 2 * a(n-1)*a(n-2)^2 = a(n)
The Jacobsthal product formula (below) follows from this recurrence by induction by substituting the products for a(n-1) and a(n-2) and using J(n+1) = J(n) + 2*J(n-1) (its recurrence in A001045).
The Jacobsthal product terms, with multiplicity, in a(n) are a subset of the terms in any bigger a(m), so a(n) divides any bigger a(m) and so in particular this is a divisibility sequence.
Asymptotically, a(n) ~ (1/2)*C^(2^n) where C = 1.537176.. = A338294. For growth power C, let c(n) = (2*a(n))^(1/2^n) so that C = lim_{n->oo} c(n). The Jacobsthal products formula gives log(c(n)) = log(2)/2^n + log(J(n+1))/2^n + Sum_{k=1..n} log(J(k))/2^k. Then discarding log(J(1)) = log(J(2)) = 0, and log(2)/2^n -> 0, and log(J(n+1))/2^n -> 0, leaves the terms of A242049 so that log(C) = A242049.
The asymptotic factor F = 1/2 is found by letting f(n) = a(n)/a(n-1)^2, so f(n) = J(n+1) / J(n) by the products formula, and f(n) = 2 + (-1)^n/J(n) -> 2 = 1/F. This factor makes no difference to the growth power C, since any F^(1/2^n) -> 1, but it brings the approximation closer to a(n) sooner.

Examples

			n=0 rows is the empty tree and n=1 row is a single vertex.  Both have only the empty matching so a(0) = a(1) = 1.
n=2 rows is a path-3 and has 3 matchings: first two vertices, last two, or the empty matching, so a(2) = 3.
Jacobsthal products formula:
  a(4) = J(5) * J(4) * J(3)^2 * J(2)^4 * J(1)^8
       =  11  *   5  *    3^2 *    1^4 *    1^8 = 495.
		

Crossrefs

Cf. A001045 (Jacobsthal numbers), A338294 (growth power), A242049 (log of growth power).
Cf. A076725 (independent sets), A158681 (Wiener index), A000975 (independence number and matching number).

Programs

  • PARI
    a(n) = my(x=1,y=1); for(i=2,n, [x,y] = [x^2 + 2*x*y^2, x]); x;

Formula

a(n) = a(n-1)^2 + 2*a(n-1)*a(n-2)^2 starting a(0)=1 and a(1)=1.
a(n) = J(n+1) * J(n) * J(n-1)^2 * J(n-2)^4 * ... * J(1)^(2^(n-1)) where J(n) = (2^n - (-1)^n)/3 = A001045(n) is the Jacobsthal numbers.
A228607(n) = a(n+1)^2*(a(n+1)+3*a(n)^2). - R. J. Mathar, Jul 22 2022

A128384 a(n) = numerator of r(n): r(n) is such that the continued fraction (of rational terms) [r(1);r(2),...,r(n)] = b(n) for every positive integer n, where b(1) = 1 and b(n+1) = 1 + 1/b(n)^2 for.every positive integer n.

Original entry on oeis.org

1, 1, 1, 9, 91, 1110627, 2340346013551, 1153990596161360976412397283, 4046008078695782327150934410204261346038863974869654053
Offset: 1

Views

Author

Leroy Quet, Feb 28 2007

Keywords

Comments

b(n) = A076725(n)/A076725(n-1)^2. The limit, as n -> infinity, of r(n)*r(n+1) = (2 /x^3) + (x^3 /2) - 2, where x is the real root of x^3 -x^2 -1 = 0. (This limit result needs some checking.)
a(10) has 113 digits. - Michel Marcus, Jan 13 2014

Examples

			{r(n)}: 1, 1, 1/3, 9/13, 91/289,...
b(4) = 41/25 = 1 + 1/(1 + 1/(1/3 + 13/9)).
And b(5) = 2306/1681 = 1 + 1/(1 + 1/(1/3 + 1/(9/13 + 289/91))).
		

Crossrefs

Programs

  • PARI
    lista(nn) = {kill(n); kill(m); nn1 = nn + 1; v = vector(nn1); v[1] = 1; v[2] = 1; for (i=3, nn1, v[i] = v[i-1]^2 + v[i-2]^4;); b = vector(nn1, i, if (i==1, 1, v[i]/v[i-1]^2)); r = vector(nn); r[1] = b[1]; for (i=2, nn, pol = (n/m); forstep (k = i-1, 1, -1, pol = 1/pol + r[k];); mat = matrix(2, 2); mat[1, 1] = polcoeff( polcoeff( numerator(pol), 1, n), 0, m); mat[1, 2] = polcoeff( polcoeff( numerator(pol), 1, m), 0, n); mat[2, 1] = polcoeff( polcoeff( denominator(pol), 1, n), 0, m); mat[2, 2] = polcoeff( polcoeff( denominator(pol), 1, m), 0, n); col = vector(2); col[1] = numerator(b[i+1]); col[2] = denominator(b[i+1]); vres = matsolve(mat, col~); r[i] = vres[1]/vres[2];); r;} \\ Michel Marcus, Jan 12 2014

Extensions

More terms from Michel Marcus, Jan 12 2014

A128385 a(n) = denominator of r(n): r(n) is such that the continued fraction (of rational terms) [r(1);r(2),...,r(n)] = b(n) for every positive integer n, where b(1) = 1 and b(n+1) = 1 + 1/b(n)^2 for.every positive integer n.

Original entry on oeis.org

1, 1, 3, 13, 289, 1645423, 7499988983197, 1716234423353399580977511919, 12985299047930678223817284541389710796223289877600061663
Offset: 1

Views

Author

Leroy Quet, Feb 28 2007

Keywords

Comments

b(n) = A076725(n)/A076725(n-1)^2. The limit, as n -> infinity, of r(n)*r(n+1) = (2 /x^3) + (x^3 /2) - 2, where x is the real root of x^3 -x^2 -1 = 0. (This limit result needs some checking.)
a(10) has 113 digits. - Michel Marcus, Jan 13 2014

Examples

			{r(n)}: 1, 1, 1/3, 9/13, 91/289,...
b(4) = 41/25 = 1 + 1/(1 + 1/(1/3 + 13/9)).
And b(5) = 2306/1681 = 1 + 1/(1 + 1/(1/3 + 1/(9/13 + 289/91))).
		

Crossrefs

Programs

Extensions

More terms from Michel Marcus, Jan 12 2014

A144229 The numerators of the convergents to the recursion x=1/(x^2+1).

Original entry on oeis.org

1, 1, 4, 25, 1681, 5317636, 66314914699609, 8947678119828215014722891025, 178098260698995011212395018312912894502905113202338936836
Offset: 0

Views

Author

Cino Hilliard, Sep 15 2008

Keywords

Comments

The recursion converges to the real root of 1/(x^2+1) - x = 0, 0.682327803...
An interesting consequence of this result occurs if we multiply by x^2+1 to get 1-x-x^3=0. These different equations intersect at the same root 0.682327803... Note also that a(n) is a square. The square roots form sequence A076725.
a(n) is the number of (0,1)-labeled perfect binary trees of height n such that no adjacent nodes have 1 as the label and the root is labeled 0. - Ran Pan, May 22 2015

Crossrefs

Programs

  • Mathematica
    f[n_]:=(n+1/n)/n;Prepend[Denominator[NestList[f,2,7]],1] (* Vladimir Joseph Stephan Orlovsky, Nov 19 2010 *)
    RecurrenceTable[{a[n]==(a[n-2]^2 + a[n-1])^2, a[0]==1, a[1]==1},a,{n,0,10}] (* Vaclav Kotesovec, May 22 2015 after Ran Pan *)
  • PARI
    x=0;for(j=1,10,x=1/(x^2+1);print1((numerator(x))","))

Formula

a(n+2) = (a(n)^2 + a(n+1))^2. - Ran Pan, May 22 2015
a(n) ~ c * d^(2^n), where c = A088559 = 0.465571231876768... is the root of the equation c*(1+c)^2 = 1, d = 1.6634583970724267140029... . - Vaclav Kotesovec, May 22 2015

A252584 a(n) = a(n-1)^3 + a(n-2)^9, a(0) = 0, a(1) = 1.

Original entry on oeis.org

0, 1, 1, 2, 9, 1241, 2298661010, 19127219051011953293860241761, 8789440239853164630485833302292601093162389737995133605845884014903267053091248194081
Offset: 0

Views

Author

Vaclav Kotesovec, Dec 18 2014

Keywords

Comments

In general, if a(n) = a(n-1)^k + a(n-2)^(k^2), k > 1, then a(n) ~ d * c^(k^n), where c is a constant (dependent only on k, a(0) and a(1)), d is the root of the equation d^(k-1) * (1 + d^(k*(k-1))) = 1.
From Massimo Galasi, Jul 26 2018: (Start)
The recursion a(n)=a(n-1)^k+a(n-2)^(k^2) with a(0)=1, and a(1)=2, gives the number of independent sets of the k-ary tree with n levels. (For n=0 one has the empty tree.)
Thus this sequence, starting with 1, 2, 9, 1241, ... is the case k=3. Sequence A076725 is the case k=2. For k=1 the tree becomes a path and a(n) is Fibonacci(n+1). (End)

Crossrefs

Programs

  • Maple
    a:=proc(n) option remember; if n=0 then 0 else if n=1 then 1 else a(n-1)^3+a(n-2)^9 fi fi end: seq(a(n), n = 0..9);
  • Mathematica
    RecurrenceTable[{a[0]==0, a[1]==1, a[n] == a[n-1]^3 + a[n-2]^9}, a, {n, 0, 10}]

Formula

a(n) ~ d * c^(3^n), where c = 1.03028886637346769106..., d = 0.85117093406701547... is the root of the equation d^2 + d^8 = 1.

A242117 The number of independent sets in a complete binary tree with n levels (i.e., with 2^n-1 vertices) in which every vertex has degree 3.

Original entry on oeis.org

0, 0, 3, 24, 1680, 5317635, 66314914699608, 8947678119828215014722891024, 178098260698995011212395018312912894502905113202338936835
Offset: 1

Views

Author

Keywords

Comments

For example, when n=3, there are two degree 3 vertices which do not share an edge. There are then three degree 3 (regular) independent subsets so a(3)=3. a(10) has 113 digits and is too large to include. The sequence is related to A076725, the number of independent sets in a complete binary tree.
The independent sets sought are those in the subgraph induced by the degree-3 vertices. This subgraph is a forest comprising two complete binary trees with n-2 levels each. These trees have A076725(n-2+1) independent sets each and the empty set (empty in both) is excluded here so a(n) = A076725(n-1)^2 - 1. - Kevin Ryde, Mar 10 2020

Examples

			a(3) = (a(1) + 1)^4 + 2(a(2)+1)(a(1) + 1)^2 + (a(2) + 1)^2 - 1 = (0+1)^4+2(0+1)(0+1)^2+(0+1)^2-1 = 3.
a(4) = (a(2) + 1)^4 + 2(a(3)+1)(a(2) + 1)^2 + (a(3) + 1)^2 - 1 = (0+1)^4+2(3+1)(0+1)^2+(3+1)^2-1 = 24.
a(5) = (a(3) + 1)^4 + 2(a(4)+1)(a(3) + 1)^2 + (a(4) + 1)^2 - 1 = (3+1)^4+2(24+1)(3+1)^2+(24+1)^2-1 = 1680.
		

Crossrefs

Cf. A076725.

Programs

  • PARI
    a(n) = my(x=1,y=1); for(i=3,n, [x,y] = [(x + y^2)^2, x]); x-1; \\ Kevin Ryde, Mar 10 2020

Formula

a(n) = (a(n-2) + 1)^4 + 2(a(n-1)+1)(a(n-2) + 1)^2 + (a(n-1) + 1)^2 - 1, with a(1) = a(2) = 0.

A252583 a(n) = a(n-1)^3 + a(n-2)^6, a(0) = 0, a(1) = 1.

Original entry on oeis.org

0, 1, 1, 2, 9, 793, 499208698, 124407462491481058208408441, 1925481259009966865844002992692350885969632796673886663638811207308483184039785
Offset: 0

Views

Author

Vaclav Kotesovec, Dec 18 2014

Keywords

Crossrefs

Programs

  • Mathematica
    RecurrenceTable[{a[0]==0, a[1]==1, a[n] == a[n-1]^3 + a[n-2]^6}, a, {n, 0, 10}]
    nxt[{a_,b_}]:={b,b^3+a^6}; NestList[nxt,{0,1},10][[All,1]] (* Harvey P. Dale, Jul 22 2022 *)

Formula

a(n) ~ c^(3^n), where c = 1.0278548747403916038597317519446646178420852580529382519451043895427806227... . - Vaclav Kotesovec, Dec 18 2014
Showing 1-10 of 10 results.