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

A055830 Triangle T read by rows: diagonal differences of triangle A037027.

Original entry on oeis.org

1, 1, 0, 2, 1, 0, 3, 3, 1, 0, 5, 7, 4, 1, 0, 8, 15, 12, 5, 1, 0, 13, 30, 31, 18, 6, 1, 0, 21, 58, 73, 54, 25, 7, 1, 0, 34, 109, 162, 145, 85, 33, 8, 1, 0, 55, 201, 344, 361, 255, 125, 42, 9, 1, 0, 89, 365, 707, 850, 701, 413, 175, 52, 10, 1, 0, 144, 655, 1416, 1918, 1806, 1239, 630, 236, 63, 11, 1, 0
Offset: 0

Views

Author

Clark Kimberling, May 28 2000

Keywords

Comments

Or, coefficients of a generalized Lucas-Pell polynomial read by rows. - Philippe Deléham, Nov 05 2006
Equals A046854(shifted) * Pascal's triangle; where A046854 is shifted down one row and "1" inserted at (0,0). - Gary W. Adamson, Dec 24 2008

Examples

			Triangle begins:
   1
   1,   0
   2,   1,   0
   3,   3,   1,   0
   5,   7,   4,   1,   0
   8,  15,  12,   5,   1,   0
  13,  30,  31,  18,   6,   1,  0
  21,  58,  73,  54,  25,   7,  1, 0
  34, 109, 162, 145,  85,  33,  8, 1, 0
  55, 201, 344, 361, 255, 125, 42, 9, 1, 0
  ...
		

Crossrefs

Left-hand columns include A000045, A023610.
Row sums: A001333 (numerators of continued fraction convergents to sqrt(2)).
Cf. A122075 (another version).
Cf. A046854. - Gary W. Adamson, Dec 24 2008

Programs

  • Magma
    function T(n,k)
      if k lt 0 or k gt n then return 0;
      elif k eq 0 then return Fibonacci(n+1);
      elif n eq 1 and k eq 1 then return 0;
      else return T(n-1,k-1) + T(n-1,k) + T(n-2,k);
      end if; return T; end function;
    [T(n,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Jan 21 2020
    
  • Maple
    with(combinat);
    T:= proc(n, k) option remember;
          if k<0 or k>n then 0
        elif k=0 then fibonacci(n+1)
        elif n=1 and k=1 then 0
        else T(n-1, k-1) + T(n-1, k) + T(n-2, k)
          fi; end:
    seq(seq(T(n, k), k=0..n), n=0..12); # G. C. Greubel, Jan 21 2020
  • Mathematica
    T[n_, k_]:= T[n, k]= If[k<0 || k>n, 0, If[k==0, Fibonacci[n+1], If[n==1 && k==1, 0, T[n-1, k-1] + T[n-1, k] + T[n-2, k]]]]; Table[T[n, k], {n, 0, 12}, {k, 0, n}]//Flatten (* G. C. Greubel, Dec 19 2017 *)
  • PARI
    T(n,k) = if(k<0 || k>n, 0, if(k==0, fibonacci(n+1), if(n==1 && k==1, 0, T(n-1, k-1) + T(n-1, k) + T(n-2, k) )));
    for(n=0,12, for(k=0, n, print1(T(n,k), ", "))) \\ G. C. Greubel, Jan 21 2020
    
  • Sage
    @CachedFunction
    def T(n, k):
        if (k<0 or k>n): return 0
        elif (k==0): return fibonacci(n+1)
        elif (n==1 and k==1): return 0
        else: return T(n-1, k-1) + T(n-1, k) + T(n-2, k)
    [[T(n, k) for k in (0..n)] for n in (0..12)] # G. C. Greubel, Jan 21 2020

Formula

G.f.: (1-y*z) / (1-y*(1+y+z)).
T(i, j) = R(i-j, j), where R(0, 0)=1, R(0, j)=0 for j >= 1, R(1, j)=1 for j >= 0, R(i, j) = Sum_{k=0..j} (R(i-2, k) + R(i-1, k)) for i >= 1, j >= 1.
Sum_{k=0..n} x^k*T(n,k) = A039834(n-2), A000012(n), A000045(n+1), A001333(n), A003688(n), A015448(n), A015449(n), A015451(n), A015453(n), A015454(n), A015455(n), A015456(n), A015457(n) for x= -2,-1,0,1,2,3,4,5,6,7,8,9,10. - Philippe Deléham, Oct 22 2006
Sum_{k=0..floor(n/2)} T(n-k,k) = A011782(n). - Philippe Deléham, Oct 22 2006
Triangle T(n,k), 0 <= k <= n, given by [1, 1, -1, 0, 0, 0, 0, 0, ...] DELTA [0, 1, 0, 0, 0, 0, 0, 0, 0, 0, ...] where DELTA is the operator defined in A084938. - Philippe Deléham, Nov 05 2006
T(n,0) = Fibonacci(n+1) = A000045(n+1). Sum_{k=0..n} T(n,k) = A001333(n). T(n,k)=0 if k > n or if k < 0, T(0,0)=1, T(1,1)=0, T(n,k) = T(n-1,k-1) + T(n-1,k) + T(n-2,k). - Philippe Deléham, Nov 05 2006

Extensions

Edited by Ralf Stephan, Jan 12 2005

A214992 Power ceiling-floor sequence of (golden ratio)^4.

Original entry on oeis.org

7, 47, 323, 2213, 15169, 103969, 712615, 4884335, 33477731, 229459781, 1572740737, 10779725377, 73885336903, 506417632943, 3471038093699, 23790849022949, 163064905066945, 1117663486445665, 7660579500052711
Offset: 0

Views

Author

Clark Kimberling, Nov 08 2012, Jan 24 2013

Keywords

Comments

Let f = floor and c = ceiling. For x > 1, define four sequences as functions of x, as follows:
p1(0) = f(x), p1(n) = f(x*p1(n-1));
p2(0) = f(x), p2(n) = c(x*p2(n-1)) if n is odd and p2(n) = f(x*p1(n-1)) if n is even;
p3(0) = c(x), p3(n) = f(x*p3(n-1)) if n is odd and p3(n) = c(x*p3(n-1)) if n is even;
p4(0) = c(x), p4(n) = c(x*p4(n-1)).
The present sequence is given by a(n) = p3(n).
Following the terminology at A214986, call the four sequences power floor, power floor-ceiling, power ceiling-floor, and power ceiling sequences. In the table below, a sequence is identified with an A-numbered sequence if they appear to agree except possibly for initial terms. Notation: S(t)=sqrt(t), r = (1+S(5))/2 = golden ratio, and Limit = limit of p3(n)/p2(n).
x ......p1..... p2..... p3..... p4.......Limit
r^2.....A001519 A001654 A061646 A001906..-1+S(5)
r^3.....A024551 A001076 A015448 A049652..-1+S(5)
r^4.....A049685 A157335 A214992 A004187..-19+9*S(5)
r^5.....A214993 A049666 A015457 A214994...(-9+5*S(5))/2
r^6.....A007805 A156085 A214995 A049660..-151+68*S(5)
2+S(2)..A007052 A214996 A214997 A007070..(1+S(2))/2
1+S(3)..A057960 A002605 A028859 A077846..(1+S(3))/2
2+S(3)..A001835 A109437 A214998 A001353..-4+3*S(3)
S(5)....A214999 A215091 A218982 A218983..1.26879683...
2+S(5)..A024551 A001076 A015448 A049652..-1+S(5)
2+S(6)..A218984 A090017 A123347 A218985..S(3/2)
2+S(7)..A218986 A015530 A126473 A218987..(1+S(7))/3
2+S(8)..A218988 A057087 A086347 A218989..(1+S(2))/2
3+S(8)..A001653 A084158 A218990 A001109..-13+10*S(2)
3+S(10).A218991 A005668 A015451 A218992..-2+S(10)
...
Properties of p1, p2, p3, p4:
(1) If x > 2, the terms of p2 and p3 interlace: p2(0) < p3(0) < p2(1) < p3(1) < p2(2) < p3(2)... Also, p1(n) <= p2(n) <= p3(n) <= p4(n) <= p1(n+1) for all x>0 and n>=0.
(2) If x > 2, the limits L(x) = limit(p/x^n) exist for the four functions p(x), and L1(x) <= L2(x) <= L3(x) <= L4 (x). See the Mathematica programs for plots of the four functions; one of them also occurs in the Odlyzko and Wilf article, along with a discussion of the special case x = 3/2.
(3) Suppose that x = u + sqrt(v) where v is a nonsquare positive integer. If u = f(x) or u = c(x), then p1, p2, p3, p4 are linear recurrence sequences. Is this true for sequences p1, p2, p3, p4 obtained from x = (u + sqrt(v))^q for every positive integer q?
(4) Suppose that x is a Pisot-Vijayaraghavan number. Must p1, p2, p3, p4 then be linearly recurrent? If x is also a quadratic irrational b + c*sqrt(d), must the four limits L(x) be in the field Q(sqrt(d))?
(5) The Odlyzko and Wilf article (page 239) raises three interesting questions about the power ceiling function; it appears that they remain open.

Examples

			a(0) = ceiling(r) = 7, where r = ((1+sqrt(5))/2)^4 = 6.8...; a(1) = floor(7*r) = 47; a(2) = ceiling(47) = 323.
		

Crossrefs

Programs

  • Mathematica
    (* Program 1.  A214992 and related sequences *)
    x = GoldenRatio^4; z = 30; (* z = # terms in sequences *)
    z1 = 100; (* z1 = # digits in approximations *)
    f[x_] := Floor[x]; c[x_] := Ceiling[x];
    p1[0] = f[x]; p2[0] = f[x]; p3[0] = c[x]; p4[0] = c[x];
    p1[n_] := f[x*p1[n - 1]]
    p2[n_] := If[Mod[n, 2] == 1, c[x*p2[n - 1]], f[x*p2[n - 1]]]
    p3[n_] := If[Mod[n, 2] == 1, f[x*p3[n - 1]], c[x*p3[n - 1]]]
    p4[n_] := c[x*p4[n - 1]]
    Table[p1[n], {n, 0, z}]  (* A049685 *)
    Table[p2[n], {n, 0, z}]  (* A157335 *)
    Table[p3[n], {n, 0, z}]  (* A214992 *)
    Table[p4[n], {n, 0, z}]  (* A004187 *)
    Table[p4[n] - p1[n], {n, 0, z}]  (* A004187 *)
    Table[p3[n] - p2[n], {n, 0, z}]  (* A098305 *)
    (* Program 2.  Plot of power floor and power ceiling functions, p1(x) and p4(x) *)
    f[x_] := f[x] = Floor[x]; c[x_] := c[x] = Ceiling[x];
    p1[x_, 0] := f[x]; p1[x_, n_] := f[x*p1[x, n - 1]];
    p4[x_, 0] := c[x]; p4[x_, n_] := c[x*p4[x, n - 1]];
    Plot[Evaluate[{p1[x, 10]/x^10, p4[x, 10]/x^10}], {x, 2, 3}, PlotRange -> {0, 4}]
    (* Program 3. Plot of power floor-ceiling and power ceiling-floor functions, p2(x) and p3(x) *)
    f[x_] := f[x] = Floor[x]; c[x_] := c[x] = Ceiling[x];
    p2[x_, 0] := f[x]; p3[x_, 0] := c[x];
    p2[x_, n_] := If[Mod[n, 2] == 1, c[x*p2[x, n - 1]], f[x*p2[x, n - 1]]]
    p3[x_, n_] := If[Mod[n, 2] == 1, f[x*p3[x, n - 1]], c[x*p3[x, n - 1]]]
    Plot[Evaluate[{p2[x, 10]/x^10, p3[x, 10]/x^10}], {x, 2, 3}, PlotRange -> {0, 4}]

Formula

a(n) = floor(r*a(n-1)) if n is odd and a(n) = ceiling(r*a(n-1)) if n is even, where a(0) = ceiling(r), r = (golden ratio)^4 = (7 + sqrt(5))/2.
a(n) = 6*a(n-1) + 6*a(n-2) - a(n-3).
G.f.: (7 + 5*x - x^2)/((1 + x)*(1 - 7*x + x^2)).
a(n) = (10*(-2)^n+(10+3*sqrt(5))*(7-3*sqrt(5))^(n+2)+(10-3*sqrt(5))*(7+3*sqrt(5))^(n+2))/(90*2^n). - Bruno Berselli, Nov 14 2012
a(n) = 7*A157335(n) + 5*A157335(n-1) - A157335(n-2). - R. J. Mathar, Feb 05 2020
E.g.f.: exp(-x)*(5 + 2*exp(9*x/2)*(155*cosh(3*sqrt(5)*x/2) + 69*sqrt(5)*sinh(3*sqrt(5)*x/2)))/45. - Stefano Spezia, Oct 28 2024

A135597 Square array read by antidiagonals: row m (m >= 1) satisfies b(0) = b(1) = 1; b(n) = m*b(n-1) + b(n-2).

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 1, 3, 3, 1, 1, 4, 7, 5, 1, 1, 5, 13, 17, 8, 1, 1, 6, 21, 43, 41, 13, 1, 1, 7, 31, 89, 142, 99, 21, 1, 1, 8, 43, 161, 377, 469, 239, 34, 1, 1, 9, 57, 265, 836, 1597, 1549, 577, 55, 1, 1, 10, 73, 407, 1633, 4341, 6765, 5116, 1393, 89, 1, 1, 11, 91, 593, 2906
Offset: 1

Views

Author

N. J. A. Sloane, Mar 02 2008

Keywords

Comments

For n > 1, the number of independent vertex sets in the graph K_m X P_{n-1}. For example, in K_3 X P_1 there are 4 independent vertex sets. - Andrew Howroyd, May 23 2017

Examples

			Array begins:
========================================================
m\n| 0 1 2  3   4    5     6      7       8        9
---|----------------------------------------------------
1  | 1 1 2  3   5    8    13     21      34       55 ...
2  | 1 1 3  7  17   41    99    239     577     1393 ...
3  | 1 1 4 13  43  142   469   1549    5116    16897 ...
4  | 1 1 5 21  89  377  1597   6765   28657   121393 ...
5  | 1 1 6 31 161  836  4341  22541  117046   607771 ...
6  | 1 1 7 43 265 1633 10063  62011  382129  2354785 ...
7  | 1 1 8 57 407 2906 20749 148149 1057792  7552693 ...
8  | 1 1 9 73 593 4817 39129 317849 2581921 20973217 ...
...
		

Crossrefs

Programs

  • Maple
    A135597 := proc(m,c) coeftayl( (m*x-x-1)/(x^2+m*x-1),x=0,c) ; end: for d from 1 to 15 do for c from 0 to d-1 do printf("%d,",A135597(d-c,c)) ; od: od: # R. J. Mathar, Apr 21 2008
  • Mathematica
    a[, 0] = a[, 1] = 1; a[m_, n_] := m*a[m, n-1] + a[m, n-2]; Table[a[m-n+1, n], {m, 0, 11}, {n, 0, m}] // Flatten (* Jean-François Alcover, Jan 20 2014 *)

Formula

O.g.f. row m: (mx-x-1)/(x^2+mx-1). - R. J. Mathar, Apr 21 2008

Extensions

More terms from R. J. Mathar, Apr 21 2008

A180028 Eight white queens and one red queen on a 3 X 3 chessboard. G.f.: (1 + 3*x)/(1 - 6*x - 3*x^2).

Original entry on oeis.org

1, 9, 57, 369, 2385, 15417, 99657, 644193, 4164129, 26917353, 173996505, 1124731089, 7270376049, 46996449561, 303789825513, 1963728301761, 12693739287105, 82053620627913, 530402941628793, 3428578511656497
Offset: 0

Views

Author

Johannes W. Meijer, Aug 09 2010; edited Jun 21 2013

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in the center square (m = 5) on a 3 X 3 chessboard. This fairy chess piece behaves like a white queen on the eight side and corner squares but on the central square the queen explodes with fury and turns into a red queen.
On a 3 X 3 chessboard there are 2^9 = 512 ways to explode with fury on the center square (off the center square the piece behaves like a normal queen). The red queen is represented by the A[5] vector in the fifth row of the adjacency matrix A, see the Maple program and A180140. For the center square the 512 red queens lead to 17 red queen sequences, see the overview of red queen sequences and the crossreferences.
The sequence above corresponds to just one red queen vector, i.e., A[5] = [111 111 111] vector. The other squares lead for this vector to A090018.
This sequence belongs to a family of sequences with g.f. (1+k*x)/(1 - 6*x - k*x^2). The members of this family that are red queen sequences are A180028 (k=3; this sequence), A180029 (k=2), A015451 (k=1), A000400 (k=0), A001653 (k=-1), A180034 (k=-2), A084120 (k=-3), A154626 (k=-4) and A000012 (k=-5). Other members of this family are A123362 (k=5), 6*A030192(k=-6).
Inverse binomial transform of A107903.

References

  • Gary Chartrand, Introductory Graph Theory, pp. 217-221, 1984.

Crossrefs

Cf. A180140 (berserker sequences)
Cf. A180032 (Corner and side squares).
Cf. Red queen sequences center square [decimal value A[5]]: A180028 [511], A180029 [255], A180031 [495], A015451 [127], A152240 [239], A000400 [63], A057088 [47], A001653 [31], A122690 [15], A180034 [23], A180036 [7], A084120 [19], A180038 [3], A154626 [17], A015449 [1], A000012 [16], A000007 [0].

Programs

  • Magma
    I:=[1,9]; [n le 2 select I[n] else 6*Self(n-1)+3*Self(n-2): n in [1..20]]; // Vincenzo Librandi, Nov 15 2011
  • Maple
    nmax:=19; m:=5; A[1]:=[0,1,1,1,1,0,1,0,1]: A[2]:=[1,0,1,1,1,1,0,1,0]: A[3]:=[1,1,0,0,1,1,1,0,1]: A[4]:=[1,1,0,0,1,1,1,1,0]: A[5]:=[1,1,1,1,1,1,1,1,1]: A[6]:=[0,1,1,1,1,0,0,1,1]: A[7]:=[1,0,1,1,1,0,0,1,1]: A[8]:=[0,1,0,1,1,1,1,0,1]: A[9]:=[1,0,1,0,1,1,1,1,0]: A:=Matrix([A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8], A[9]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);
  • Mathematica
    LinearRecurrence[{6,3},{1,9},50] (* Vincenzo Librandi, Nov 15 2011 *)

Formula

G.f.: (1+3*x)/(1 - 6*x - 3*x^2).
a(n) = 6*a(n-1) + 3*a(n-2) with a(0) = 1 and a(1) = 9.
a(n) = ((1-A)*A^(-n-1) + (1-B)*B^(-n-1))/4 with A=(-1+2*sqrt(3)/3) and B=(-1-2*sqrt(3)/3).
Lim_{k->infinity} a(n+k)/a(k) = (-1)^(n-1)*A108411(n+1)/(A041017(n-1)*sqrt(12) - A041016(n-1)) for n >= 1.

A154626 a(n) = 2^n*A001519(n).

Original entry on oeis.org

1, 2, 8, 40, 208, 1088, 5696, 29824, 156160, 817664, 4281344, 22417408, 117379072, 614604800, 3218112512, 16850255872, 88229085184, 461973487616, 2418924584960, 12665653559296, 66318223015936, 347246723858432, 1818207451086848, 9520257811087360
Offset: 0

Views

Author

Paul Barry, Jan 13 2009

Keywords

Comments

Hankel transform of 1,1,3,11,45,... (see A026375). Binomial transform of A015448.
From Gary W. Adamson, Jul 22 2016: (Start)
A production matrix for the sequence is M =
1, 1, 0, 0, 0, ...
1, 0, 5, 0, 0, ...
1, 0, 0, 5, 0, ...
1, 0, 0, 0, 5, ...
...
Take powers of M, extracting the upper left terms; getting
the sequence starting (1, 1, 2, 8, 40, 208, ...). (End)
The sequence is N=5 in an infinite set of INVERT transforms of powers of N prefaced with a "1". (1, 2, 8, 40, ...) is the INVERT transform of (1, 1, 5, 25, 125, ...). The first six of such sequences are shown in A006012 (N=3). - Gary W. Adamson, Jul 24 2016
From Gary W. Adamson, Jul 27 2016: (Start)
The sequence is the first in an infinite set in which we perform the operation for matrix M (Cf. Jul 22 2016), but change the left border successively from (1, 1, 1, 1, ...) then to (1, 2, 2, 2, ...), then (1, 3, 3, 3, ...) ...; generally (1, N, N, N, ...). Extracting the upper left terms of each matrix operation, we obtain the infinite set beginning:
N=1 (A154626): 1, 2, 8, 40, 208, 1088, ...
N=2 (A084120): 1, 3, 15, 81, 441, 1403, ...
N=3 (A180034): 1, 4, 22, 124, 700, 3952, ...
N=4 (A001653): 1, 5, 29, 169, 985, 5741, ...
N=5 (A000400): 1, 6, 36, 216, 1296, 7776, ...
N=6 (A015451): 1, 7, 43, 265, 1633, 10063, ...
N=7 (A180029): 1, 8, 50, 316, 1996, 12608, ...
N=8 (A180028): 1, 9, 57, 369, 1285, 15417, ...
N=9 (.......): 1, 10, 64, 424, 2800, 18496, ...
N=10 (A123361): 1, 11, 71, 481, 3241, 21851, ...
N=11 (.......): 1, 12, 78, 540, 3708, 25488, ...
... Each of the sequences begins (1, (N+1), (7*N + 1),
(40*N + (N-1)^2), ... (End)
The set of infinite sequences shown (Cf. comment of Jul 27 2016), can be generated from the matrices P = [(1,N; 1,5]^n, (N=1,2,3,...) by extracting the upper left terms. Example: N=6 sequence (A015451): (1, 7, 43, 265, ...) can be generated from the matrix P = [(1,6); (1,5)]^n. - Gary W. Adamson, Jul 28 2016

Crossrefs

Programs

  • Magma
    [n le 2 select (n) else 6*Self(n-1)-4*Self(n-2): n in [1..25]]; // Vincenzo Librandi, May 15 2015
    
  • Mathematica
    LinearRecurrence[{6, -4}, {1, 2}, 30] (* Vincenzo Librandi, May 15 2015 *)
  • PARI
    Vec((1-4*x) / (1-6*x+4*x^2) + O(x^30)) \\ Colin Barker, Sep 22 2017

Formula

G.f.: (1 - 4*x) / (1 - 6*x + 4*x^2).
a(n) = A084326(n+1) - 4*A084326(n). - R. J. Mathar, Jul 19 2012
From Colin Barker, Sep 22 2017: (Start)
a(n) = (((3-sqrt(5))^n*(1+sqrt(5)) + (-1+sqrt(5))*(3+sqrt(5))^n)) / (2*sqrt(5)).
a(n) = 6*a(n-1) - 4*a(n-2) for n>1. (End)
E.g.f.: exp(3*x)*(5*cosh(sqrt(5)*x) - sqrt(5)*sinh(sqrt(5)*x))/5. - Stefano Spezia, Aug 26 2025

A179237 a(0) = 1, a(1) = 2; a(n+1) = 6*a(n) + a(n-1) for n>1.

Original entry on oeis.org

1, 2, 13, 80, 493, 3038, 18721, 115364, 710905, 4380794, 26995669, 166354808, 1025124517, 6317101910, 38927735977, 239883517772, 1478228842609, 9109256573426, 56133768283165, 345911866272416, 2131604965917661, 13135541661778382, 80944854936587953
Offset: 0

Views

Author

Gary W. Adamson, Jul 04 2010

Keywords

Comments

a(n)/a(n-1) converges to 1/(sqrt(10) - 3) = 6.16227766017... = A176398.

Examples

			a(5) = 3038 = 6*a(5) + a(4) = 6*493 + 80.
a(5) = term (1,1) in M^5 where M^5 = [3038, 4215, 4215, 5848].
		

Programs

  • Magma
    I:=[1,2]; [n le 2 select I[n] else 6*Self(n-1)+Self(n-2): n in [1..40]]; // Vincenzo Librandi, Oct 13 2015
  • Mathematica
    CoefficientList[Series[(-1 + 4 x)/(-1 + 6 x + x^2), {x, 0, 33}], x] (* Vincenzo Librandi, Oct 13 2015 *)
  • PARI
    Vec((-1+4*x)/(-1+6*x+x^2) + O(x^40)) \\ Colin Barker, Oct 13 2015
    

Formula

Let M = the 2x2 matrix [2,3; 3,4]. a(n) = term (1,1) in M^n.
G.f.: ( -1+4*x ) / ( -1+6*x+x^2 ). a(n) = A005668(n) + A015451(n). - R. J. Mathar, Jul 06 2012
a(n) = ((3-sqrt(10))^n*(1+sqrt(10))+(-1+sqrt(10))*(3+sqrt(10))^n)/(2*sqrt(10)). - Colin Barker, Oct 13 2015
a(n) = Sum_{k=0..n-2} A168561(n-2,k)*6^k + 2 * Sum_{k=0..n-1} A168561(n-1,k)*6^k, n>0. - R. J. Mathar, Feb 14 2024
a(n) = A005668(n+1) - 4*A005668(n). - R. J. Mathar, Feb 14 2024

Extensions

Corrected by R. J. Mathar, Jul 06 2012

A013946 Least d for which the number with continued fraction [n,n,n,n...] is in Q(sqrt(d)).

Original entry on oeis.org

5, 2, 13, 5, 29, 10, 53, 17, 85, 26, 5, 37, 173, 2, 229, 65, 293, 82, 365, 101, 445, 122, 533, 145, 629, 170, 733, 197, 5, 226, 965, 257, 1093, 290, 1229, 13, 1373, 362, 61, 401, 1685, 442, 1853, 485, 2029, 530, 2213, 577, 2405, 626, 2605, 677, 2813, 730, 3029, 785, 3253
Offset: 1

Views

Author

Keywords

Comments

Square roots of a(n) are found in the limiting ratios of A000045, A001333, A003688, A015448, A015449, A015451 and so on. I.e., the limiting ratios are the golden ratio, silver mean, bronze ratio and so on. - Mats Granvik, Oct 20 2010

Crossrefs

a(n) = 2 is equivalent to "n is in the sequence A077444", a(n) = 5 is equivalent to "n is in the sequence A002878".

Programs

  • Mathematica
    z = 5000; u = Table[{p, e} = Transpose[FactorInteger[n]];
    Times @@ (p^Mod[e, 2]), {n, z}]; Table[u[[n^2 + 4]], {n, 1, Sqrt[z - 4]}]  (* Clark Kimberling, Jul 20 2015, based on T. D. Noe's program at A007913 *)
  • PARI
    A013946(n)=core(n^2+4)  \\ M. F. Hasler, Dec 08 2010

Formula

a(n) = A007913(n^2+4). - David W. Wilson, Dec 08 2010

Extensions

More terms from David W. Wilson

A213895 Fixed points of a sequence h(n) defined by the minimum number of 6's in the relation n*[n,6,6,...,6,n] = [x,...,x] between simple continued fractions.

Original entry on oeis.org

7, 11, 23, 47, 127, 139, 211, 223, 251, 331, 367, 379, 383, 463, 487, 499, 607, 619, 691, 727, 739, 743, 811, 823, 863, 887, 967, 971, 983, 1051, 1063, 1087, 1171, 1291, 1303, 1327, 1367, 1423, 1447, 1451, 1459
Offset: 1

Views

Author

Art DuPre, Jun 23 2012

Keywords

Comments

In a variant of A213891, multiply n by a number with simple continued fraction [n,6,6,...,6,n] and increase the number of 6's until the continued fraction of the product has the same first and last entry (called x in the NAME). Examples are
2 * [2, 6, 2] = [4, 3, 4],
3 * [3, 6, 3] = [9, 2, 9],
4 * [4, 6, 6, 6, 4] = [16, 1, 1, 1, 5, 1, 1, 1, 16],
5 * [5, 6, 6, 6, 6, 5] = [25, 1, 4, 3, 3, 4, 1, 25],
6 * [6, 6, 6] = [36, 1, 36],
7 * [7, 6, 6, 6, 6, 6, 6, 6, 7] = [50, 7, 2, 1, 4, 4, 4, 1, 2, 7, 50].
The number of 6's needed defines the sequence h(n) = 1, 1, 3, 4, 1, 7, 7, 5, 9, ... (n>=2).
The current sequence contains the fixed points of h, i.e., those n where h(n)=n.
We conjecture that this sequence contains numbers is analogous to the sequence of prime numbers A000057, in the sense that, instead of referring to the Fibonacci sequences (sequences satisfying f(n) = f(n-1) + f(n-2) with arbitrary positive integer values for f(1) and f(2)) it refers to the generalized Fibonacci sequences satisfying f(n) = 6*f(n-1) + f(n-2), A005668, A015451, A179237, etc. This would mean that a prime is in the sequence if and only if it divides some term in each of the sequences satisfying f(n) = 6*f(n-1) + f(n-2).
The above sequence h() is recorded as A262216. - M. F. Hasler, Sep 15 2015

Crossrefs

Programs

  • Mathematica
    f[m_, n_] := Block[{c, k = 1}, c[x_, y_] := ContinuedFraction[x FromContinuedFraction[Join[{x}, Table[m, {y}], {x}]]]; While[First@ c[n, k] != Last@ c[n, k], k++]; k]; Select[Range[2, 1000], f[6, #] == # &] (* Michael De Vlieger, Sep 16 2015 *)
  • PARI
    {a(n) = local(t, m=1); if( n<2, 0, while( 1,
       t = contfracpnqn( concat([n, vector(m,i,6), n]));
       t = contfrac(n*t[1,1]/t[2,1]);
       if(t[1]
    				

A218991 Power floor sequence of 3+sqrt(10).

Original entry on oeis.org

6, 36, 221, 1361, 8386, 51676, 318441, 1962321, 12092366, 74516516, 459191461, 2829665281, 17437183146, 107452764156, 662153768081, 4080375372641, 25144406003926, 154946811396196, 954825274381101, 5883898457682801
Offset: 0

Views

Author

Clark Kimberling, Nov 12 2012

Keywords

Comments

See A214992 for a discussion of power floor sequence and the power floor function, p1(x) = lim_{n->oo} a(n,x)/x^n. The present sequence is a(n,r), where r = 3+sqrt(10), and the limit p1(r) = 5.815421188487681054332319082...
See A218992 for the power floor function, p4. For comparison with p1, we have lim_{r->oo} p4(r)/p1(r) = (3+sqrt(10))/5 = 1.23245553....

Examples

			a(0) = floor(r) = 6, where r = 3+sqrt(10);
a(1) = floor(6*r) = 36;
a(2) = floor(36*r) = 221.
		

Crossrefs

Cf. A176398 (3+sqrt(10)).

Programs

  • Magma
    [IsZero(n) select Floor(r) else Floor(r*Self(n)) where r is 3+Sqrt(10): n in [0..20]]; // Bruno Berselli, Nov 22 2012
  • Mathematica
    x = 3 + Sqrt[10]; z = 30; (* z = # terms in sequences *)
    f[x_] := Floor[x]; c[x_] := Ceiling[x];
    p1[0] = f[x]; p2[0] = f[x]; p3[0] = c[x]; p4[0] = c[x];
    p1[n_] := f[x*p1[n - 1]]
    p2[n_] := If[Mod[n, 2] == 1, c[x*p2[n - 1]], f[x*p2[n - 1]]]
    p3[n_] := If[Mod[n, 2] == 1, f[x*p3[n - 1]], c[x*p3[n - 1]]]
    p4[n_] := c[x*p4[n - 1]]
    t1 = Table[p1[n], {n, 0, z}]  (* A218991 *)
    t2 = Table[p2[n], {n, 0, z}]  (* A005668 *)
    t3 = Table[p3[n], {n, 0, z}]  (* A015451 *)
    t4 = Table[p4[n], {n, 0, z}]  (* A218992 *)

Formula

a(n) = floor(r*a(n-1)), where r=3+sqrt(10), a(0) = floor(r).
a(n) = 7*a(n-1) - 5*a(n-2) - a(n-3).
G.f.: (6 - 6*x - x^2)/(1 - 7*x + 5*x^2 + x^3).
a(n) = ((5+sqrt(10))*(3-sqrt(10))^(n+2) + (5-sqrt(10))*(3+sqrt(10))^(n+2)+2)/12. - Bruno Berselli, Nov 22 2012

A218992 Power ceiling sequence of 3+sqrt(10).

Original entry on oeis.org

7, 44, 272, 1677, 10335, 63688, 392464, 2418473, 14903303, 91838292, 565933056, 3487436629, 21490552831, 132430753616, 816075074528, 5028881200785, 30989362279239, 190965054876220, 1176779691536560, 7251643204095581
Offset: 0

Views

Author

Clark Kimberling, Nov 12 2012

Keywords

Comments

See A214992 for a discussion of power ceiling sequence and the power ceiling function, p4(x) = limit of a(n,x)/x^n. The present sequence is a(n,r), where r = 3+sqrt(10), and the limit p4(r) = 7.16724801485749657...
See A218991 for the power floor function, p1(x); for comparison of p1 and p4, we have limit(p4(r)/p1(r) = (3+sqrt(10))/5 = 1.23245553...

Examples

			a(0) = ceiling(r) = 7, where r = 3+sqrt(10);
a(1) = ceiling(7*r) = 44;
a(2) = ceiling(44*r) = 272.
		

Crossrefs

Cf. A176398 (3+sqrt(10)).

Programs

  • Magma
    [IsZero(n) select Ceiling(r) else Ceiling(r*Self(n)) where r is 3+Sqrt(10): n in [0..20]]; // Bruno Berselli, Nov 22 2012
  • Mathematica
    (See A218991.)
    LinearRecurrence[{7,-5,-1},{7,44,272},20] (* Harvey P. Dale, Sep 22 2016 *)

Formula

a(n) = ceiling(r*a(n-1)), where r=3+sqrt(10), a(0) = ceiling(r).
a(n) = 7*a(n-1) - 5*a(n-2) - a(n-3).
G.f.: (7 - 5*x - x^2)/(1 - 7*x + 5*x^2 + x^3).
a(n) = ((5+sqrt(10))*(3-sqrt(10))^(n+3)+(5-sqrt(10))*(3+sqrt(10))^(n+3)-10)/60. [Bruno Berselli, Nov 22 2012]
Showing 1-10 of 11 results. Next