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.

Previous Showing 11-17 of 17 results.

A210728 a(n) = a(n-1) + a(n-2) + n + 2 with n>1, a(0)=1, a(1)=2.

Original entry on oeis.org

1, 2, 7, 14, 27, 48, 83, 140, 233, 384, 629, 1026, 1669, 2710, 4395, 7122, 11535, 18676, 30231, 48928, 79181, 128132, 207337, 335494, 542857, 878378, 1421263, 2299670, 3720963, 6020664, 9741659, 15762356, 25504049, 41266440, 66770525, 108037002, 174807565
Offset: 0

Views

Author

Alex Ratushnyak, May 10 2012

Keywords

Crossrefs

Cf. A065220: a(n)=a(n-1)+a(n-2)+n-5, a(0)=1,a(1)=2 (except first 2 terms).
Cf. A168043: a(n)=a(n-1)+a(n-2)+n-3, a(0)=1,a(1)=2 (except first 2 terms).
Cf. A131269: a(n)=a(n-1)+a(n-2)+n-2, a(0)=1,a(1)=2.
Cf. A000126: a(n)=a(n-1)+a(n-2)+n-1, a(0)=1,a(1)=2.
Cf. A104161: a(n)=a(n-1)+a(n-2)+n, a(0)=1,a(1)=2 (except the first term).
Cf. A192969: a(n)=a(n-1)+a(n-2)+n+1, a(0)=1,a(1)=2.
Cf. A210729: a(n)=a(n-1)+a(n-2)+n+3, a(0)=1,a(1)=2.

Programs

  • Mathematica
    RecurrenceTable[{a[0] == 1, a[1] == 2, a[n] == a[n - 1] + a[n - 2] + n + 2}, a, {n, 36}] (* Bruno Berselli, Jun 27 2012 *)
    nxt[{n_,a_,b_}]:={n+1,b,a+b+n+3}; NestList[nxt,{1,1,2},40][[;;,2]] (* Harvey P. Dale, Aug 26 2024 *)

Formula

G.f.: (1-x+3*x^2-2*x^3)/((1-x)^2*(1-x-x^2)). - Bruno Berselli, Jun 27 2012
a(n) = ((5+sqrt(5))*(1+sqrt(5))^(n+1)-(5-sqrt(5))*(1-sqrt(5))^(n+1))/(2^(n+1)*sqrt(5))-n-5. - Bruno Berselli, Jun 27 2012
a(n) = -n-5+A022112(n+1). R. J. Mathar, Jul 03 2012

A024831 a(n) = least m such that if r and s in {F(h)/F(2*h): h = 1,2,...,n} satisfy r < s, then r < k/m < s for some integer k, where F = A000045 (Fibonacci numbers).

Original entry on oeis.org

2, 7, 10, 10, 15, 23, 37, 59, 95, 153, 247, 399, 645, 1043, 1687, 2729, 4415, 7143, 11557, 18699, 30255, 48953, 79207, 128159, 207365, 335523, 542887, 878409, 1421295, 2299703, 3720997, 6020699, 9741695, 15762393, 25504087, 41266479, 66770565, 108037043, 174807607, 282844649
Offset: 2

Views

Author

Keywords

Comments

Note that F(2*h)/F(h) = Lucas(h) for h > 0. - Editors.
For a guide to related sequences, see A001000. - Clark Kimberling, Aug 07 2012

Crossrefs

Programs

  • Mathematica
    leastSeparator[seq_] := Module[{n = 1},
    Table[While[Or @@ (Ceiling[n #1[[1]]] <
    2 + Floor[n #1[[2]]] &) /@ (Sort[#1, Greater] &) /@
    Partition[Take[seq, k], 2, 1], n++]; n, {k, 2, Length[seq]}]];
    t = Table[N[Fibonacci[h]/Fibonacci[2 h]], {h, 1, 30}]
    t1 = leastSeparator[t]
    (* Peter J. C. Moses, Aug 01 2012 *)

Formula

From Philippe Deléham, Feb 06 2024: (Start)
a(n) = a(n-1) + a(n-2) - 1 for n >= 8.
a(n) = 2*a(n-1) - a(n-3) for n >= 9.
a(n) = 1 + A022112(n-3) for n >= 6.
a(n) = floor(((1 + sqrt(5))/2)*a(n-1)) for n >= 8.
G.f.: x^2*(x^6+3*x^5+2*x^4-8*x^3-4*x^2+3*x+2)/((x-1)*(x^2+x-1)).
(End)

Extensions

All the terms were corrected by Clark Kimberling, Aug 07 2012
More terms from Sean A. Irvine, Jul 25 2019

A164413 Number of binary strings of length n with no substrings equal to 0000, 0001 or 1001.

Original entry on oeis.org

1, 2, 4, 8, 13, 22, 36, 58, 94, 152, 246, 398, 644, 1042, 1686, 2728, 4414, 7142, 11556, 18698, 30254, 48952, 79206, 128158, 207364, 335522, 542886, 878408, 1421294, 2299702, 3720996, 6020698, 9741694, 15762392, 25504086, 41266478, 66770564, 108037042
Offset: 0

Views

Author

R. H. Hardin, Aug 14 2009

Keywords

Comments

Essentially the same as A022112. - R. J. Mathar, Nov 30 2011

Programs

  • PARI
    Vec(-(x^2+1)*(x^2-x+1)*(x+1)^2/(x^2+x-1) + O(x^50)) \\ Colin Barker, Oct 27 2017
    
  • PARI
    first(n) = {my(start = [1, 2, 4, 8, 13, 22, 36]); if(n <= 7, return(vector(n+1, i, start[i]))); res = concat(start, vector(n-7)); for(i=8, n,
    res[i] = res[i-1] + res[i-2]); res} \\ David A. Corneth, Oct 27 2017

Formula

From Colin Barker, Oct 27 2017: (Start)
G.f.: -(x^2+1)*(x^2-x+1)*(x+1)^2/(x^2+x-1).
a(n) = 2*(((1 - sqrt(5))/2)^n + ((1 + sqrt(5))/2)^n) for n>4.
a(n) = a(n-1) + a(n-2) for n>6.
(End)

A244213 Inverse binomial transform of -2 followed by A000032(n+1).

Original entry on oeis.org

-2, 3, -1, 0, 3, -7, 14, -25, 43, -72, 119, -195, 318, -517, 839, -1360, 2203, -3567, 5774, -9345, 15123, -24472, 39599, -64075, 103678, -167757, 271439, -439200, 710643, -1149847, 1860494, -3010345, 4870843, -7881192
Offset: 0

Views

Author

Paul Curtz, Jun 23 2014

Keywords

Comments

A simple transform of a(n) is a(n) with -a(0) instead of nonzero a(0) (or -a(0) followed by a(n+1)). Example: -1 followed by A198631(n+1)/A006519(n+2). Its inverse binomial transform is -1, 3/2, -2, 9/4, -2, 3/2, -2,... = -(-1)^n*A143074(n).
Difference table of -2 followed by A000032(n+1):
-2, 1, 3, 4, 7, 11, 18,...
3, 2, 1, 3, 4, 7, 11,...
-1, -1, 2, 1, 3, 4, 7,...
0, 3, -1, 2, 1, 3, 4,...
3, -4, 3, -1, 2, 1, 3,...
-7, 7, -4, 3, -1, 2, 1,...
14, -11, 7, -4, 3, -1, 2,...
etc.
a(n) is the first column.

Crossrefs

Programs

  • PARI
    Vec(-(5*x^2-x-2)/((x+1)*(x^2-x-1)) + O(x^100)) \\ Colin Barker, Jun 23 2014

Formula

a(n) = -2, 3, -1, followed by -(-1)^n*A206417(n).
a(n) = (-1)^n* (A000032(n) - 4).
a(n+3) = -a(n) -(-1)^n*A022112(n).
a(n) = -2*a(n-1) + a(n-3). - Colin Barker, Jun 23 2014
G.f.: -(5*x^2-x-2) / ((x+1)*(x^2-x-1)). - Colin Barker, Jun 23 2014

A247526 a(n) = L(n+1) * L(n) * L(n-1) * L(n-2) / 6, where L(n) = Lucas numbers (A000032).

Original entry on oeis.org

-1, -1, 4, 14, 154, 924, 6699, 44979, 310764, 2123554, 14571974, 99833524, 684385079, 4690541639, 32150245204, 220358978774, 1510368355474, 10352204457804, 70955102255139, 486333408161979, 3333379024971324, 22847319059525674, 156597856242950654
Offset: 0

Views

Author

Michael Somos, Sep 19 2014

Keywords

Examples

			G.f. = -1 - x + 4*x^2 + 14*x^3 + 154*x^4 + 924*x^5 + 6699*x^6 + 44979*x^7 + ...
		

Crossrefs

Programs

  • Magma
    m:=60; R:=PowerSeriesRing(Integers(), m); Coefficients(R!(-(1-4*x-24*x^2+6*x^3-4*x^4)/((1-x)*(1+3*x+x^2)*(1 - 7*x+x^2)))); // G. C. Greubel, Aug 05 2018
  • Mathematica
    CoefficientList[Series[-(1-4*x-24*x^2+6*x^3-4*x^4)/((1-x)*(1+3*x+x^2)*(1 - 7*x+x^2)), {x, 0, 60}], x] (* G. C. Greubel, Aug 05 2018 *)
    Times@@#/6&/@Partition[LucasL[Range[-2,30]],4,1] (* or *) LinearRecurrence[{5,15,-15,-5,1},{-1,-1,4,14,154},30] (* Harvey P. Dale, Apr 20 2022 *)
  • PARI
    {a(n) = my(u = fibonacci(n), v = fibonacci(n-1)); (3*u + v) * (u + 2*v) * (2*u - v) * (-u + 3*v) / 6};
    
  • PARI
    {a(n) = if( n<1, n=1-n); polcoeff( - (1 - 4*x - 24*x^2 + 6*x^3 - 4*x^4) / ((1 - x) * (1 + 3*x + x^2) * (1 - 7*x +x^2)) + x * O(x^n), n)};
    

Formula

G.f.: -(1 - 4*x - 24*x^2 + 6*x^3 - 4*x^4)/((1-x)*(1 + 3*x + x^2)*(1 - 7*x + x^2)).
a(n) = a(1-n) = 5*a(n-1) + 15*a(n-2) - 15*a(n-3) - 5*a(n-4) + a(n-5) for all n in Z.
0 = a(n)*(+a(n+1) - 2*a(n+2)) + a(n+1)*(-5*a(n+1) + a(n+2)) for all n in Z.
From Klaus Purath, Oct 02 2020: (Start)
a(n) = (L(n-2)*L(n-1)^3 - L(n-1)*L(n-2)^3)/6 where L = Lucas.
a(n) = f(n-3)*f(n-2)*f(n-1)*f(n)/96 where f = A022112.
a(n) = (f(n-2)*f(n-1)^3 - f(n-1)*f(n-2)^3)/96 where f = A022112.
(End)
2*a(n) = A098149(n) +A004187(n+1)-6*A004187(n) -2 . - R. J. Mathar, Sep 24 2021

A372242 a(n) = 10*Fibonacci(n) + (-1)^n.

Original entry on oeis.org

1, 9, 11, 19, 31, 49, 81, 129, 211, 339, 551, 889, 1441, 2329, 3771, 6099, 9871, 15969, 25841, 41809, 67651, 109459, 177111, 286569, 463681, 750249, 1213931, 1964179, 3178111, 5142289, 8320401, 13462689, 21783091, 35245779, 57028871, 92274649, 149303521, 241578169
Offset: 0

Views

Author

Paul Curtz, Apr 23 2024

Keywords

Examples

			a(0) = 10*0 + 1 =  1,
a(1) = 10*1 - 1 =  9,
a(2) = 10*1 + 1 = 11,
a(3) = 10*2 - 1 = 19.
		

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{0, 2, 1}, {1, 9, 11}, 50] (* Paolo Xausa, May 20 2024 *)

Formula

Floor(a(n+2)/10) = A052952(n).
a(n) = 1 + A153382(n).
a(n) = 2*A371843(n) - (-1)^n.
a(n) = A022093(n) + (-1)^n.
G.f.: -(9*x^2+9*x+1)/((x+1)*(x^2+x-1)).
a(0) = 1. a(n) = -a(n-1) + 10*A000045(n+1) for n >= 1.
a(n) = a(n-4) + (2*A280154(n-2) = 5*A022112(n-3) = 10*A000032(n-2)) for n >= 4.

A347351 Triangle read by rows: T(n,k) is the number of links of length k in a set of all necklaces A000358 of length n, 1 <= k <= n.

Original entry on oeis.org

1, 2, 1, 3, 0, 1, 4, 2, 0, 1, 5, 1, 1, 0, 1, 6, 4, 2, 1, 0, 1, 7, 3, 2, 1, 1, 0, 1, 8, 8, 3, 3, 1, 1, 0, 1, 9, 8, 7, 3, 2, 1, 1, 0, 1, 10, 18, 9, 5, 4, 2, 1, 1, 0, 1, 11, 21, 13, 8, 5, 3, 2, 1, 1, 0, 1, 12, 40, 24, 16, 8, 6, 3, 2, 1, 1, 0, 1, 13, 55, 34, 21, 13, 8, 5, 3, 2, 1, 1, 0, 1
Offset: 0

Views

Author

Maxim Karimov and Vladislav Sulima, Aug 28 2021

Keywords

Comments

Definitions:
1. A link is any 0 in any necklace from A000358 and all 1s following this 0 in this necklace to right until another 0 is encountered.
2. Length of the link is the number of elements in the link.
Sum of all elements n-row is Fibonacci(n-1)+n iff n=1 or n=p (follows from the identity for the sum of the Fibonacci numbers and the formula for the triangle T(n,k)).

Examples

			For k > 0:
   n\k |  1   2   3   4   5   6   7   8   9  10  ...
  -----+---------------------------------------
   1   |  1
   2   |  2   1
   3   |  3   0   1
   4   |  4   2   0   1
   5   |  5   1   1   0   1
   6   |  6   4   2   1   0   1
   7   |  7   3   2   1   1   0   1
   8   |  8   8   3   3   1   1   0   1
   9   |  9   8   7   3   2   1   1   0   1
  10   | 10  18   9   5   4   2   1   1   0   1
  ...
If we continue the calculation for nonpositive k, we get a table in which each row is a Fibonacci sequence, in which term(0) = A113166, term(1) = A034748.
For k <= 0:
   n\k |  0   -1   -2   -3   -4   -5   -6   -7   -8   -9 ...
  -----+------------------------------------------------
   1   |  0    1    1    2    3    5    8   13   21   34 ... A000045
   2   |  1    2    3    5    8   13   21   34   55   89 ... A000045
   3   |  1    4    5    9   14   23   37   60   97  157 ... A000285
   4   |  3    6    9   15   24   39   63  102  165  267 ... A022086
   5   |  3    9   12   21   33   54   87  141  228  369 ... A022379
   6   |  8   14   22   36   58   94  152  246  398  644 ... A022112
   7   |  8   19   27   46   73  119  192  311  503  814 ... A206420
   8   | 17   30   47   77  124  201  325  526  851 1377 ... A022132
   9   | 23   44   67  111  178  289  467  756 1223 1979 ... A294116
  10   | 41   68  109  177  286  463  749 1212 1961 3173 ... A022103
  ...
		

Crossrefs

Programs

  • MATLAB
    function [res] = calcLinks(n,k)
    if k==1
        res=n;
    else
        d=divisors(n);
        res=0;
        for i=1:length(d)
            if d (i) >= k
                res=res+eulerPhi(n/d(i))*fiboExt(d(i)-k-1);
            end
        end
    end
    function [s] = fiboExt(m) % extended fibonacci function (including negative arguments)
    m=sym(m); % for large fibonacci numbers
    if m>=0 || mod(m,2)==1
        s=fibonacci(abs(m));
    else
        s=fibonacci(abs(m))*(-1);
    end
    
  • PARI
    T(n, k) = if (k==1, n, sumdiv(n, d, if (d>=k, eulerphi(n/d)*fibonacci(d-k-1)))); \\ Michel Marcus, Aug 29 2021

Formula

If k=1, T(n,k)=n, otherwise T(n,k) = Sum_{d>=k, d|n} Phi(n/d)*Fibonacci(d-k-1), where Phi=A000010.
Previous Showing 11-17 of 17 results.