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-18 of 18 results.

A157636 Triangle read by rows: T(n, k) = 1 if k=0 or k=n, otherwise = n*k*(n-k)/2.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 3, 3, 1, 1, 6, 8, 6, 1, 1, 10, 15, 15, 10, 1, 1, 15, 24, 27, 24, 15, 1, 1, 21, 35, 42, 42, 35, 21, 1, 1, 28, 48, 60, 64, 60, 48, 28, 1, 1, 36, 63, 81, 90, 90, 81, 63, 36, 1, 1, 45, 80, 105, 120, 125, 120, 105, 80, 45, 1
Offset: 0

Views

Author

Roger L. Bagula, Mar 03 2009

Keywords

Examples

			Triangle begins as:
  1;
  1,  1;
  1,  1,  1;
  1,  3,  3,   1;
  1,  6,  8,   6,   1;
  1, 10, 15,  15,  10,   1;
  1, 15, 24,  27,  24,  15,   1;
  1, 21, 35,  42,  42,  35,  21,   1;
  1, 28, 48,  60,  64,  60,  48,  28,  1;
  1, 36, 63,  81,  90,  90,  81,  63, 36,  1;
  1, 45, 80, 105, 120, 125, 120, 105, 80, 45, 1;
		

Crossrefs

Programs

  • Magma
    A157636:= func< n,k | k eq 0 or k eq n select 1 else n*k*(n-k)/2 >;
    [A157636(n,k): k in [0..n], n in [0..15]]; // G. C. Greubel, Dec 13 2021
    
  • Mathematica
    T[n_, k_] = If[n*k*(n-k)==0, 1, n*k*(n-k)/2];
    Table[T[n, k], {n,0,15}, {k,0,n}]//Flatten
  • Sage
    def A157636(n,k): return 1 if (k==0 or k==n) else n*k*(n-k)/2
    flatten([[A157636(n,k) for k in (0..n)] for n in (0..15)]) # G. C. Greubel, Dec 13 2021

Formula

T(n, k) = 1 if k=0 or k=n, otherwise = n*k*(n-k)/2.
Sum_{k=0..n} T(n, k) = 2 + n^2*(n^2 - 1)/12 = 2 + A002415(n) if n>0.
From G. C. Greubel, Dec 13 2021: (Start)
T(n, k) = T(n, n-k).
T(n, 1) = [n<2] + binomial(n, 2).
T(n, 2) = A132411(n-1), for n >= 2.
T(2*n, n) = [n=0] + A000578(n). (End)

A180357 a(n) = n^7 + 7*n.

Original entry on oeis.org

0, 8, 142, 2208, 16412, 78160, 279978, 823592, 2097208, 4783032, 10000070, 19487248, 35831892, 62748608, 105413602, 170859480, 268435568, 410338792, 612220158, 893871872, 1280000140, 1801088688, 2494358042
Offset: 0

Views

Author

Odimar Fabeny, Aug 30 2010

Keywords

Crossrefs

Programs

  • Mathematica
    Table[n^7+7n,{n,0,30}] (* Harvey P. Dale, Sep 10 2010 *)

Formula

From Chai Wah Wu, Oct 15 2016: (Start)
a(n) = 8*a(n-1) - 28*a(n-2) + 56*a(n-3) - 70*a(n-4) + 56*a(n-5) - 28*a(n-6) + 8*a(n-7) - a(n-8) for n > 7.
G.f.: 2*x*(4*x^6 + 39*x^5 + 648*x^4 + 1138*x^3 + 648*x^2 + 39*x + 4)/(x - 1)^8. (End)

Extensions

First term corrected and additional terms from Harvey P. Dale, Sep 10 2010

A265611 a(n) = a(n-1) + floor((n-1)/2) - (-1)^n + 2 for n>=2, a(0)=1, a(1)=3.

Original entry on oeis.org

1, 3, 4, 8, 10, 15, 18, 24, 28, 35, 40, 48, 54, 63, 70, 80, 88, 99, 108, 120, 130, 143, 154, 168, 180, 195, 208, 224, 238, 255, 270, 288, 304, 323, 340, 360, 378, 399, 418, 440, 460, 483, 504, 528, 550, 575, 598, 624, 648, 675, 700, 728, 754, 783, 810, 840
Offset: 0

Views

Author

Peter Luschny, Dec 17 2015

Keywords

Crossrefs

Cf. A084964 and A097065, after the first 3: a(n+1) - a(n) for n>0.
Cf. A055998, after 3: a(n+1) + a(n) for n>0.
Cf. A063929: a(2*n+1) gives the second column of the triangle; for n>0, a(2*n) gives the third column.

Programs

  • Magma
    [1] cat [(2*n*(n+6)-5*(-1)^n+5)/8: n in [1..60]]; // Bruno Berselli, Dec 18 2015
  • Maple
    A265611 := proc(n) iquo(n+1,2); %*(%+irem(n+1,2)+2)+0^n end:
    seq(A265611(n), n=0..55);
  • Mathematica
    Join[{1}, Table[(2 n (n + 6) - 5 (-1)^n + 5)/8, {n, 1, 60}]] (* Bruno Berselli, Dec 18 2015 *)
  • PARI
    Vec((x^4-2*x^3+2*x^2-x-1)/(x^4-2*x^3+2*x-1) + O(x^1000)) \\ Altug Alkan, Dec 18 2015
    
  • Sage
    # The initial values x, y = 0, 1 give the quarter-squares A002620.
    def A265611():
        x, y = 1, 2
        while True:
           yield x
           x, y = x + y, x//y + 1
    a = A265611(); print([next(a) for i in range(60)])
    

Formula

O.g.f.: (x^4-2*x^3+2*x^2-x-1)/(x^4-2*x^3+2*x-1).
E.g.f.: 1-(5/8)*exp(-x)+(1/8)*(5+14*x+2*x^2)*exp(x).
a(2*n) = n*(n+3) + 0^n = A028552(n) + 0^n. [Here 0^0 = 1, otherwise 0^s = 0. - N. J. A. Sloane, Aug 26 2022]
a(2*n+1) = (n+1)*(n+3) = A005563(n+1).
a(n+1) - a(n) = floor(n/2) + 2 + (-1)^n - 0^n.
a(n) = a(-n-6) = (2*n*(n+6) - 5*(-1)^n + 5)/8 for n>0, a(0)=1. [Bruno Berselli, Dec 18 2015]
For n>0, a(n) = n + 1 + Sum_{i=1..n+1} floor(i/2) + (-1)^i = n + floor((n+1)^2/4) + (1 - (-1)^n)/2. - Enrique Pérez Herrero, Dec 18 2015
Sum_{n>=0} 1/a(n) = 85/36. - Enrique Pérez Herrero, Dec 18 2015
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4) for n>5. - R. H. Hardin, Dec 21 2015, proved by Susanne Wienand for the algorithm sent to the seqfan mailing list and used in the Sage script below.
a(n) = A002620(n+1) + A052928(n+1) for n>=1. (Note A198442(n) = A002620(n+2) - A052928(n+2) for n>=1.) - Peter Luschny, Dec 22 2015
a(n) = (floor((n+3)/2)-1)*(ceiling((n+3)/2)+1) for n>0. - Wesley Ivan Hurt, Mar 30 2017

A180358 n^8+8n.

Original entry on oeis.org

0, 9, 272, 6585, 65568, 390665, 1679664, 5764857, 16777280, 43046793, 100000080, 214358969, 429981792, 815730825, 1475789168, 2562890745, 4294967424, 6975757577, 11019960720, 16983563193, 25600000160, 37822859529, 54875873712
Offset: 0

Views

Author

Odimar Fabeny, Aug 30 2010

Keywords

Crossrefs

Programs

  • Mathematica
    Table[n^8+8n,{n,0,30}] (* or *) LinearRecurrence[ {9,-36,84,-126,126,-84,36,-9,1},{0,9,272,6585,65568,390665,1679664,5764857,16777280},30] (* Harvey P. Dale, Jan 03 2012 *)

Formula

a(n)= +9*a(n-1) -36*a(n-2) +84*a(n-3) -126*a(n-4) +126*a(n-5) -84*a(n-6) +36*a(n-7) -9*a(n-8) +a(n-9). G.f.: x*(-9-191*x-4461*x^2-15339*x^3-15899*x^4-4125*x^5-303*x^6+7*x^7) / (x-1)^9 . [From R. J. Mathar, Sep 19 2010]

Extensions

a(0) corrected by R. J. Mathar, Sep 19 2010

A356879 Numbers k such that the sum k^x + k^y can be a square with {x, y} >= 0.

Original entry on oeis.org

0, 2, 3, 8, 15, 18, 24, 32, 35, 48, 50, 63, 72, 80, 98, 99, 120, 128, 143, 162, 168, 195, 200, 224, 242, 255, 288, 323, 338, 360, 392, 399, 440, 450, 483, 512, 528, 575, 578, 624, 648, 675, 722, 728, 783, 800, 840, 882, 899, 960, 968, 1023, 1058, 1088, 1152, 1155, 1224
Offset: 0

Views

Author

Karl-Heinz Hofmann, Sep 12 2022

Keywords

Comments

Characteristics of the terms:
- Any x combined with any y is a solution.
This special case is valid only for k = 0 (exception: x = y = 0).
- Any x is possible and if x is odd: y = x. If x is even: y = x + 3.
This special case is valid only for k = 2 (see A356880).
- Only even x combined with y = x + 1 gives a solution.
Those terms are the terms of A132411.
- Only odd x combined with y = x gives a solution.
Those terms are the terms of A001105.
- Any x is possible and if x is odd: y = x. If x is even: y = x + 1.
Those terms are the terms of A132592.

Examples

			Squares that can be produced with k = 8: 8^0 + 8^1 = 9; 8^1 + 8^1 = 16; 8^2 + 8^3 = 576; 8^3 + 8^3 = 1024; 8^4 + 8^5 = 36864; 8^5 + 8^5 = 65536; 8^6 + 8^7 = 2359296, ....
		

Crossrefs

Cf. A132411 is a subsequence (except A132411(1)), A001105 is a subsequence.
Cf. A132592 is a subsequence.
Cf. A356880 (k = 2), A270473 (k = 3).

Programs

  • Mathematica
    Select[Range[0, 1225], IntegerQ[Sqrt[# + 1]] || IntegerQ[Sqrt[#/2]] &] (* Amiram Eldar, Sep 18 2022 *)
  • Python
    from gmpy2 import is_square
    print([n for n in range(0,1225) if is_square(n+1) or (n % 2 == 0 and is_square(n//2))])

A133475 Integers n such that n^3 + n^2 - 9*n + 16 is a square.

Original entry on oeis.org

-4, -3, -1, 0, 1, 3, 5, 11, 15, 28, 47, 55, 81, 549, 1799, 8361
Offset: 1

Views

Author

Mohamed Bouhamida, Nov 29 2007

Keywords

Comments

The set of x values of integral points on the elliptic curve y^2 = x^3 + x^2 - 9*x + 16.

Examples

			0^3 + (-5)^2 + (-9) = 4^2, 1^3 + (-4)^2 + (-8) = 3^2, 3^3 + (-2)^2 + (-6) = 5^2
		

Crossrefs

Programs

  • Magma
    P := PolynomialRing(Integers()); {x: x in Sort([ p[1] : p in IntegralPoints(EllipticCurve(n^3 + n^2 - 9*n + 16)) ])};
    
  • Mathematica
    ok[x_] := Reduce[{y^2 == x^3 + x^2 - 9*x + 16, y >= 0}, y, Integers] =!= False; Select[Table[x, {x, -4, 10000}], ok ] (* Jean-François Alcover, Sep 07 2011 *)
  • PARI
    is(n)=issquare(n^3+n^2-9*n+16) \\ Charles R Greathouse IV, Sep 06 2016
  • Sage
    EllipticCurve([0,1,0,-9,16]).integral_points()
    

Extensions

Edited by Max Alekseyev, Nov 13 2009

A180359 n^9+9n.

Original entry on oeis.org

0, 10, 530, 19710, 262180, 1953170, 10077750, 40353670, 134217800, 387420570, 1000000090, 2357947790, 5159780460, 10604499490, 20661046910, 38443359510, 68719476880, 118587876650, 198359290530, 322687697950, 512000000180
Offset: 0

Views

Author

Odimar Fabeny, Aug 30 2010

Keywords

Crossrefs

Formula

a(n)= +10*a(n-1) -45*a(n-2) +120*a(n-3) -210*a(n-4) +252*a(n-5) -210*a(n-6) +120*a(n-7) -45*a(n-8) +10*a(n-9) -a(n-10). G.f.: 10*x*(1+43*x+1486*x^2+8773*x^3+15682*x^4+8773*x^5+1486*x^6+43*x^7+x^8)/(x -1)^10. [From R. J. Mathar, Sep 19 2010]

Extensions

a(0) corrected by R. J. Mathar, Sep 19 2010

A343009 a(n) = (n^(2n)-1)/(n^2-1) for n > 1, a(1) = 1.

Original entry on oeis.org

1, 5, 91, 4369, 406901, 62193781, 14129647351, 4467856773185, 1876182941212489, 1010101010101010101, 678356244890331342611, 555922008415320588345745, 546031727340884622966664381, 633213824057681722185793753109, 856031514432518244055765015738351
Offset: 1

Views

Author

Thomas Ordowski, Apr 02 2021

Keywords

Comments

Conjecture: for n > 2, a(n) is a Fermat pseudoprime to base n.
If p is an odd prime, then a(p) is a Cipolla pseudoprime to base p.
Is a(m) a Fermat pseudoprime to base m for every composite m?
Amiram Eldar confirmed this up to m = 3800.
From Jianing Song, Aug 28 2022: (Start)
a(n) = Product_{d|(2n),d>2} Phi(d,n), where Phi(n,x) is the d-th cyclotomic polynomial. Note that Phi(n,x) > 1 for x >= 2 unless (n,x) = (1,2): suppose that n >= 3 and x >= 2, then Phi(n,x) = Product_{1<=j<=n,gcd(j,n)=1} (x - exp(2*j*Pi*i/n)) = Product_{1<=j<=n/2,gcd(j,n)=1} (x^2 - 2*cos(2*j*Pi/n)*x + 1) = Product_{1<=j<=n/2,gcd(j,n)=1} ((x - cos(2*j*Pi/n))^2 + (sin(2*j*Pi/n))^2) > 1 since x - cos(2*j*Pi/n) > 1. This shows that a(n) is composite for n > 2.
For n > 2, a(n) is a Fermat pseudoprime to base n, since n^(2*n) == 1 (mod a(n)) and 2*n divides a(n)-1 = n^2*(n^(2*n-2)-1)/(n^2-1): if n is even, then 2*n | n^2; if n is odd, then n | n^2 and 2 | n^2+1 = (n^4-1)/(n^2-1) | (n^(2*n-2)-1)/(n^2-1). (End)

Examples

			a(10) = (10^20-1)/99 = 1010101010101010101.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := (n^(2*n)-1)/(n^2-1); a[1] = 1; Array[a, 15] (* Amiram Eldar, Apr 02 2021 *)

Formula

a(n) = Sum_{k=0..n-1} n^(2*k). - Davide Rotondo, Aug 28 2022
From Alois P. Heinz, Aug 28 2022: (Start)
a(n) = A117812(n)/A005563(n-1) = A117812(n)/A132411(n-1) for n>=2.
Limit_{n -> 1} (n^(2*n)-1)/(n^2-1) = 1. (End).

Extensions

More terms from Amiram Eldar, Apr 02 2021
a(1)=1 prepended and name adapted by Alois P. Heinz, Aug 28 2022
Previous Showing 11-18 of 18 results.