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

A028935 a(n) = A006720(n)^3 (cubed terms of Somos-4 sequence).

Original entry on oeis.org

1, 1, 1, 1, 8, 27, 343, 12167, 205379, 30959144, 3574558889, 553185473329, 578280195945297, 238670664494938073, 487424450554237378792, 2035972062206737347698803, 4801616835579099275862827431
Offset: 0

Views

Author

Keywords

Comments

If initial two 1's are omitted, denominator of y-coordinate of (2n+1)*P where P is the generator for rational points on the curve y^2 + y = x^3 - x.

Examples

			5P = (1/4, -5/8).
		

Crossrefs

Programs

  • Magma
    I:=[1,1,1,1,8,27,343,12167,205379]; [n le 9 select I[n] else (129*Self(n-1)*Self(n-8) - 260*Self(n-2)*Self(n-7) - 8385*Self(n-3)*Self(n-6) + 48633*Self(n-4)*Self(n-5))/Self(n-9): n in [1..30]]; // G. C. Greubel, Feb 22 2018
  • Mathematica
    b[n_ /; 0 <= n <= 4] = 1; b[n_]:= b[n] = (b[n-1]*b[n-3] + b[n-2]^2)/b[n -4]; Table[(b[n])^3, {n,0,30}] (* G. C. Greubel, Feb 21 2018 *)
    a[n_ /; 0 <= n <= 3] = 1; a[4]:= 8; a[5]:= 27; a[6]:= 343; a[7]:= 12167; a[8]:= 205379; a[9]:= 30959144; a[n_]:= a[n] = (129*a[n-1]*a[n-8] - 260*a[n-2]*a[n-7] - 8385*a[n-3]*a[n-6] + 48633*a[n-4]*a[n-5])/a[n-9]; Table[a[n], {n,0,30}] (* G. C. Greubel, Feb 22 2018 *)
  • PARI
    {b(n) = if(n< 4, 1, (b(n-1)*b(n-3) + b(n-2)^2)/b(n-4))};
    for(n=0,30, print1((b(n))^3, ", ")) \\ G. C. Greubel, Feb 21 2018
    

Formula

P = (0, 0), 2P = (1, 0); if kP = (a, b) then (k+1)P = (a' = (b^2 - a^3)/a^2, b' = -1 -b*a'/a).
a(n) = (129*a(n-1)*a(n-8) - 260*a(n-2)*a(n-7) - 8385*a(n-3)*a(n-6) + 48633*a(n-4)*a(n-5))/a(n-9). - G. C. Greubel, Feb 22 2018

Extensions

Edited by N. J. A. Sloane, May 14 2009

A028945 a(n) = A006720(n)^2 (squared terms of Somos-4 sequence).

Original entry on oeis.org

1, 1, 1, 1, 4, 9, 49, 529, 3481, 98596, 2337841, 67387681, 6941055969, 384768368209, 61935294530404, 16063784753682169, 2846153597907293521, 2237394491744632911601, 1262082793174195430038441, 1063198259901027900600665796
Offset: 0

Views

Author

Keywords

Comments

If first two 1's are omitted, denominator of x-coordinate of (2n+1)*P where P is the generator for rational points on the curve y^2 + y = x^3 - x.

Crossrefs

Programs

  • Magma
    I:=[1,1,1,1,4,9,49]; [n le 7 select I[n] else (- 4*Self(n-6)*Self(n-1) + 29*Self(n-5)*Self(n-2) + 116*Self(n-4)*Self(n-3) )/Self(n-7): n in [1..30]]; // G. C. Greubel, Feb 21 2018
  • Mathematica
    b[n_ /; 0 <= n <= 4] = 1; b[n_]:= b[n] = (b[n-1]*b[n-3] + b[n-2]^2)/b[n -4]; Table[(b[n])^2, {n,0,30}] (* G. C. Greubel, Feb 21 2018 *)
  • PARI
    {b(n) = if(n< 4, 1, (b(n-1)*b(n-3) + b(n-2)^2)/b(n-4))};
    for(n=0,30, print1((b(n))^2, ", ")) \\ G. C. Greubel, Feb 21 2018
    

Formula

P = (0, 0), 2P = (1, 0); if kP = (a, b) then (k+1)P = (a' = (b^2 - a^3)/a^2, b' = -1 -b*a'/a).
a(n) = (- 4 a(n - 6) a(n - 1) + 29 a(n - 5) a(n - 2) + 116 a(n - 4) a(n - 3))/a(n-7). - Bill Gosper, May 14 2009
5P = (1/4, -5/8).
0 = a(n)*a(n+6) - 5*a(n+1)*a(n+5) + 4*a(n+2)*a(n+4) - 20*a(n+3)^2 for all n in Z. - Michael Somos, Apr 12 2020

Extensions

Edited by N. J. A. Sloane, May 14 2009

A220838 Tropical version of Somos-4 sequence A006720.

Original entry on oeis.org

-1, 0, 0, 0, 1, 1, 2, 3, 3, 5, 6, 7, 9, 10, 12, 14, 15, 18, 20, 22, 25, 27, 30, 33, 35, 39, 42, 45, 49, 52, 56, 60, 63, 68, 72, 76, 81, 85, 90, 95, 99, 105, 110, 115, 121, 126, 132, 138, 143, 150, 156, 162, 169, 175, 182, 189, 195, 203, 210, 217, 225, 232
Offset: 1

Views

Author

N. J. A. Sloane, Dec 23 2012

Keywords

Comments

Given the generalized Somos-4 sequence with variables s(1), s(2), s(3), s(4), u, v and recursion s(n) = (u*s(n-1)*s(n-3) + v*s(n-2)^2)/s(n-4), then s(n) is a Laurent polynomial with denominator b(n) := s(1)^a(n)*s(2)^a(n-1)*s(3)^a(n-2)*s(4)^a(n-3) for all n in Z. Moreover, s(n)*b(n) is an irreducible polynomial for all n in Z. - Michael Somos, Sep 16 2023

Examples

			G.f. = -x + x^5 + x^6 + 2*x^7 + 3*x^8 + 3*x^9 + 5*x^10 + 6*x^11 + 7*x^12 + ...
		

Crossrefs

Programs

  • Magma
    m:=25; R:=PowerSeriesRing(Integers(), m); Coefficients(R!(x*( x^6-x^5+x^4-x^2+2*x-1)/((1-x)^2*(1-x^8)))); // G. C. Greubel, Aug 10 2018
  • Maple
    A118825x := proc(n)
        coeftayl((1-2*x+x^2)/(x^4+1),x=0,n) ;
    end proc:
    A056594 := proc(n)
        coeftayl(1/(x^2+1),x=0,n) ;
    end proc:
    A220838 := proc(n)
        -9/32-1/8*n+1/16*n^2+1/32*(-1)^n ;
        %+A118825x(n)/4 - A056594(n+3)/8  ;
    end proc:
    seq(A220838(n),n=0..80) ; # R. J. Mathar, Jan 30 2013
  • Mathematica
    LinearRecurrence[{2, -1, 0, 0, 0, 0, 0, 1, -2, 1}, {-1, 0, 0, 0, 1, 1, 2, 3, 3, 5}, 62] (* Jean-François Alcover, Nov 26 2017 *)
    a[ n_] := With[{m = n-1}, Floor[m^2/16] - Boole[Mod[m, 8] == 0]]; (* Michael Somos, Sep 16 2023 *)
  • PARI
    {a(n) = if( n<1, n = 2-n); polcoeff( x * (x^6 - x^5 + x^4 - x^2 + 2*x - 1) / ( (1 - x)^2 * (1 - x^8) ) + x * O(x^n), n)} /* Michael Somos, Dec 27 2012 */
    
  • PARI
    {a(n) = n--; n^2\16 - !(n%8)}; /* Michael Somos, Sep 16 2023 */
    

Formula

From Michael Somos, Dec 27 2012: (Start)
G.f.: x * (x^6 - x^5 + x^4 - x^2 + 2*x - 1) / ( (1 - x)^2 * (1 - x^8) ).
a(2-n) = a(n). (End)
Second difference has period 8. - Michael Somos, Dec 27 2012
a(n) = A236294(n-5) = max( a(n-1) + a(n-3), 2*a(n-2) ) - a(n-4) for all n in Z. - Michael Somos, Sep 16 2023

A129739 Primes in Somos-4 sequence (A006720).

Original entry on oeis.org

2, 3, 7, 23, 59, 8209, 620297, 1687054711, 25907979805412230144914099508240296236020415269340706571266102156690578761249, 167688864076998154482920561111926793545475633249050257599724515210137245508480818512193851652306467577687209241137
Offset: 1

Views

Author

N. J. A. Sloane, May 13 2007

Keywords

Crossrefs

Cf. A192241, primes in Dana Scott's sequence (A048736).

Extensions

a(9)-a(10) from Robert G. Wilson v, Jul 04 2007

A129741 List of primitive prime divisors of the Somos-4 sequence (A006720) in their order of occurrence.

Original entry on oeis.org

2, 3, 7, 23, 59, 157, 11, 139, 8209, 9257, 620297, 983, 4003, 1847, 9803, 1687054711, 1433, 33008447, 83, 101, 113, 51563, 61, 823, 5381, 20117, 6329, 262650531833, 197, 10259, 519606349, 2621, 11887, 136667817691, 13933, 42591667, 564188663, 211, 8802371
Offset: 1

Views

Author

N. J. A. Sloane, May 13 2007

Keywords

Comments

Read A006720 term-by-term, factorize each term, write down any primes not seen before.

Crossrefs

Cf. A227199 (primes in this sequence).

Programs

  • Mathematica
    a[0] = a[1] = a[2] = a[3] = 1; a[n_] := a[n] = (a[n - 1] a[n - 3] + a[n - 2]^2)/a[n - 4]; t = Array[a, 30]; t2 = {}; ps = {}; Do[f = Transpose[FactorInteger[t[[n]]]][[1]]; c = Complement[f, ps]; t2 = Join[t2, c]; ps = Union[ps, c], {n, 4, 30}]; t2 (* T. D. Noe, Nov 19 2013 *)
    DeleteDuplicates[DeleteCases[Flatten[FactorInteger[#][[;;,1]]&/@RecurrenceTable[{a[0]==a[1]== a[2]==a[3]==1,a[n]==(a[n-1]a[n-3]+a[n-2]^2)/a[n-4]},a,{n,30}]],1]] (* Harvey P. Dale, May 25 2024 *)

Extensions

Order of some of the terms corrected by T. D. Noe, Nov 19 2013

A254316 Hankel transform of a(n) is A006720(n+1). Hankel transform of a(n+1) is A006720(n+3).

Original entry on oeis.org

1, 1, 2, 6, 21, 78, 299, 1172, 4677, 18947, 77746, 322545, 1350906, 5704822, 24265651, 103872254, 447146683, 1934538301, 8407277728, 36685185300, 160663301053, 705974374128, 3111584887543, 13752592535137, 60939737103636, 270672216346769, 1204862348053296
Offset: 0

Views

Author

Michael Somos, Jan 28 2015

Keywords

Examples

			G.f. = 1 + x + 2*x^2 + 6*x^3 + 21*x^4 + 78*x^5 + 299*x^6 + 1172*x^7 + ...
		

Crossrefs

Cf. A006720.

Programs

  • Mathematica
    CoefficientList[Series[(1-2*x+x^2-Sqrt[(1-4*x+x^2)^2-4*x^3])/(2*x*(1 - x)), {x, 0, 60}], x] (* G. C. Greubel, Aug 04 2018 *)
  • PARI
    {a(n) = if( n<0, 0, polcoeff( (1 - 2*x + x^2 - sqrt( (1-4*x+x^2)^2 - 4*x^3 + x^2 * O(x^n))) / (2*x*(1 - x)), n))};

Formula

Given g.f. A(x), 0 = (x^2-x)*A(x)^2 + (x^2-2*x+1)*A(x) + (2*x-1).
G.f.: (1 - 2*x + x^2 - sqrt( (1-4*x+x^2)^2 - 4*x^3 )) / (2*x*(1 - x)).
Conjecture: +(n+1)*a(n) +(-8*n+3)*a(n-1) +(18*n-29)*a(n-2) +(-12*n+31)*a(n-3) +(n-4)*a(n-4)=0. - R. J. Mathar, Jun 07 2016

A129740 Indices of primes in Somos-4 sequence (A006720).

Original entry on oeis.org

4, 5, 6, 7, 8, 11, 13, 16, 43, 52, 206, 647
Offset: 1

Views

Author

N. J. A. Sloane, May 13 2007

Keywords

Comments

Sequence is probably finite - see A006720.

Crossrefs

Extensions

More terms (based on the entry A006720) from Stefan Steinerberger, Jun 06 2007

A151502 a(n) = A006720(n)^4 (fourth powers of Somos-4 sequence).

Original entry on oeis.org

1, 1, 1, 1, 16, 81, 2401, 279841, 12117361, 9721171216, 5465500541281, 4541099550557761, 48178257964790528961, 148046697174216601867681, 3835980708567891638880403216, 258045180612631702971803868544561, 8100590302880631846481071607248577441
Offset: 0

Views

Author

N. J. A. Sloane, May 14 2009

Keywords

Crossrefs

Cf. A006720(n)^k; A006720 (k=1), A028945 (k=2), A028935 (k=3), this sequence (k=4).

Programs

  • Magma
    I:=[1,1,1,1]; [n le 4 select I[n] else ((Self(n-1)*Self(n-3) + Self(n-2)^2)/Self(n-4))^4: n in [1..15]]; // G. C. Greubel, Sep 25 2018
  • Mathematica
    b[n_ /; 0 <= n <= 4] = 1; b[n_]:= b[n] = (b[n-1]*b[n-3] + b[n-2]^2)/b[n -4]; Table[(b[n])^4, {n, 0, 20}] (* G. C. Greubel, Sep 25 2018 *)
  • PARI
    {b(n) = if(n<4, 1, (b(n-1)*b(n-3) + b(n-2)^2)/b(n-4))};
    for(n=0, 20, print1((b(n))^4, ", ")) \\ G. C. Greubel, Sep 25 2018
    
  • PARI
    b=vector(20); b[1]=b[2]=b[3]=1;b[4]=2; for(n=5, #b, b[n]=(b[n-1]*b[n-3]+b[n-2]^2)/b[n-4]); concat(1, vector(20, n, b[n]^4)) \\ Altug Alkan, Sep 25 2018
    

Formula

a(n) = A028945(n)^2 = A006720(n)^4. - Seiichi Manyama, Nov 20 2016

A227199 Primes that divide some term of A006720.

Original entry on oeis.org

2, 3, 7, 11, 23, 41, 47, 53, 59, 61, 71, 73, 83, 97, 101, 113, 127, 139, 149, 157, 173, 179, 181, 191, 197, 199, 211, 223, 229, 239, 257, 263, 271, 277, 281, 307, 331, 337, 347, 359, 373, 379, 383, 389, 397, 409, 419, 433, 439, 443, 463, 467, 479, 499, 509
Offset: 1

Views

Author

Jeremy Rouse, Sep 18 2013

Keywords

Comments

The density of primes in this sequence is 11/21.
If p divides A006720(n) for some n, then the smallest such n is <= (1/2)*((sqrt(p)+1)^2+3).

Examples

			11 is in the sequence because 11 divides A006720(10) = 1529.
		

Programs

  • Magma
    [ n : n in [2..500] | IsPrime(n) and (n ne 37) and (Order(EllipticCurve([GF(n)!0,0,1,-1,0])![0,0,1]) mod 2 eq 1) ];

A141604 Triangle, read by rows, T(n,k) = round(A006720(n)/(A006720(n-k)*A006720(k))).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 2, 3, 3, 2, 1, 1, 2, 4, 7, 4, 2, 1, 1, 3, 8, 12, 12, 8, 3, 1, 1, 3, 8, 20, 15, 20, 8, 3, 1, 1, 5, 14, 45, 52, 52, 45, 14, 5, 1, 1, 5, 26, 66, 109, 170, 109, 66, 26, 5, 1
Offset: 0

Views

Author

Roger L. Bagula and Gary W. Adamson, Aug 21 2008

Keywords

Comments

The round-function in the definition is round-to-nearest, not Mathematica's round-to-even. - R. J. Mathar, Jul 12 2012

Examples

			Triangle begins:
  1;
  1,   1;
  1,   1,   1;
  1,   1,   1,   1;
  1,   2,   2,   2,   1;
  1,   2,   3,   3,   2,   1;
  1,   2,   4,   7,   4,   2,   1;
  1,   3,   8,  12,  12,   8,   3,   1;
  1,   3,   8,  20,  15,  20,   8,   3,   1;
  1,   5,  14,  45,  52,  52,  45,  14,   5,   1;
  1,   5,  26,  66, 109, 170, 109,  66,  26,   5,   1;
		

Crossrefs

Cf. A006720.

Programs

  • Magma
    A006720:= [n le 4 select 1 else (Self(n-1)*Self(n-3)+Self(n-2)^2)/Self(n-4): n in [1..30]];
    A141604:= func< n,k | Round(A006720[n+1]/(A006720[k+1]*A006720[n-k+1])) >;
    [A141604(n,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Sep 21 2024
    
  • Maple
    A141604 := proc(n,m)
            round(A006720(n)/A006720(n-m)/A006720(m)) ;
    end proc:
    seq(seq(A141604(n,k),k=0..n),n=0..12) ; # R. J. Mathar, Jul 12 2012
  • Mathematica
    f[n_]:= f[n]= If[n<4, 1, (f[n-1]*f[n-3] +f[n-2]^2)/f[n-4]]; (* A006720 *)
    A141604[n_, k_]:= Round[f[n]/(f[k]*f[n-k])];
    Table[A141604[n,k], {n,0,12}, {k,0,n}]//Flatten (* modified by G. C. Greubel, Sep 21 2024 *)
  • SageMath
    def f(n): # f = A006720
        if n<4: return 1
        else: return (f(n-1)*f(n-3) +f(n-2)^2)/f(n-4)
    def A141604(n,k): return round(f(n)/(f(k)*f(n-k)))
    flatten([[A141604(n,k) for k in range(n+1)] for n in range(13)]) # G. C. Greubel, Sep 21 2024
Showing 1-10 of 93 results. Next