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

A130280 a(n) = smallest integer k>1 such that n(k^2-1)+1 is a perfect square, or 0 if no such number exists.

Original entry on oeis.org

2, 5, 3, 0, 2, 3, 5, 2, 0, 3, 7, 5, 4, 11, 3, 2, 4, 13, 9, 7, 2, 5, 19, 4, 0, 5, 21, 3, 11, 9, 11, 14, 2, 29, 5, 3, 6, 31, 21, 2, 13, 11, 13, 169, 3, 7, 41, 6, 0, 7, 5, 11, 22, 419, 3, 2, 5, 23, 461, 27, 8, 55, 7, 4, 2, 3, 49, 29
Offset: 1

Views

Author

M. F. Hasler, May 20 2007, May 25 2007

Keywords

Comments

A084702(n) = a(n)^2-1, resp. a(n) = sqrt(A084702(n)+1). See A130283 for values where A130280(n)=0.

Examples

			a( (2k)^2 ) <= k since (2k)^2(k^2-1)+1 = (2k^2-1)^2 (but k=1 is excluded since with k^2-1=0 this would be a trivial solution for any n).
		

Crossrefs

Programs

  • Maple
    A130280:=proc(n) local x,y,z; if n=1 then return 2 fi; isolve(n*(x^2-1)+1=y^2,z); select(has,`union`(%),x); map(rhs,%); simplify(eval(%,z=1) union eval(%,z=0)) minus {-1,1}; if %={} then 0 else (min@op@map)(abs,%) fi end;
  • Mathematica
    $MaxExtraPrecision = 100;
    r[n_, c_] := Reduce[k > 1 && j > 1 && n*(k^2 - 1) + 1 == j^2, {j, k}, Integers] /. C[1] -> c // Simplify;
    a[n_] := If[rn = r[n,0] || r[n,1] || r[n,2]; rn === False, 0, k /. {ToRules[rn]} // Min];
    Table[an = a[n]; Print["a(", n, ") = ", an]; an, {n, 1, 800}] (* Jean-François Alcover, May 12 2017 *)
  • PARI
    {A130280(n,L=10^15)=if(issquare(n),L=2+sqrtint(n>>2)); for( k=2, L, if( issquare(n*(k^2-1)+1),return(k)))}

Formula

If n=(2k)^2, then A130280(n) <= k, since (2k)^2(k^2-1)+1 = (2k^2-1)^2. See A130281 for the cases where equality does not hold. If n=k^2-1, then A130280(n) <= k-1 since (k^2-1)((k-1)^2-1)+1 = (k^2-k-1)^2. See A130282 for the cases where equality does not hold.

A130284 Integers j > 0 such that (2j+1)^2(m^2-1) + 1 is a square for some integer m > 1.

Original entry on oeis.org

7, 17, 31, 49, 71, 97, 104, 127, 161, 199, 241, 287, 337, 391, 449, 511, 577, 594, 647, 721, 799, 881, 967, 1057, 1151, 1249, 1351, 1455, 1457, 1567, 1681, 1799, 1921, 1952, 2047, 2177, 2311, 2449, 2591, 2737, 2887, 3041, 3199, 3361, 3527, 3697, 3871, 4049
Offset: 1

Views

Author

M. F. Hasler, May 24 2007, May 29 2007

Keywords

Comments

All terms > 4 in A130283 are odd squares, but not all odd squares are in that sequence: This sequence here gives the exceptions as (2a(n)+1)^2. The sequence consists mainly of the subsequences: (1) A056220(k) = 2k^2-1 with k>1: {7,17,31,49,...}, for which m=k gives (1+2*A056220(k))^2(k^2-1)+1 = k^2(4k^2-3)^2; (2) 2*A079414(k) = 2k^2(4k^2-3) with k>1: {104,594,1952,4850,...}, for which m=k gives (1+4*A079414(k))^2(k^2-1)+1 = k^2(16k^4-20k^2+5)^2. A third subsequence starts {1455,20195,...}; up to 20195, all terms are in one of these subsequences.

Examples

			Up to k=17, a(k)=P[1](k+1) with P[1] = 2x^2 - 1, A130280(a(k)) = k+1.
a(18) = P[2](2) < P[1](19) with P[2] = 2x^2*(4x^2 - 3), A130280(a(18)) = 2.
a(106) = P[1](100) < a(107) = P[3](3) < a(108) = P[4](2) < a(109) = P[1](101).
		

Crossrefs

Programs

  • Mathematica
    r[n_] := Reduce[m>1 && k>1 && (2n+1)^2*(m^2-1)+1 == k^2, {m, k}, Integers];
    Reap[For[n=1, n <= 5000, n++, If[r[n] =!= False, Print[n]; Sow[n]]]][[2,1]] (* Jean-François Alcover, May 12 2017 *)
  • PARI
    A130284( LIM=9999, START=1 )={ local(N); for( n=START, LIM, N=(2*n+1)^2; for( m=2, sqrtint(n>>1+1), if(!issquare( N*(m^2-1)+1 ), next); print1(n", "); next(2))) }
    
  • PARI
    {Q(k,x=x)=if(m>0,(4*x^2-2)*Q(k-1,x)-Q(k-2,x),1)} {P(k,x=x)=if(type(x=(x^2*Q(k,x)^2-1)/(x^2-1))!="t_POL",sqrtint(x)\2,((-1)^k*Pol(sqrt(x))-1)/2)}

Formula

A130284 = { P[k](m) ; k=1,2,3,..., m=2,3,4,... } where P[k] = (sqrt((X^2 Q[k]^2 - 1)/(X^2 - 1))-1)/2 and Q[0] = Q[-1] = 1, Q[k+1] = (4X^2 -2)*Q[k] - Q[k-1]. Furthermore, (2P[k](m)+1)^2 (m^2 - 1)+1 = m^2 Q[k](m)^2, thus A130280(P[k](m)) <= m. So far, no case is known where we have strict inequality.

A130288 Record indices of A130280: integers n>0 for which min{ m>1 | (2n+1)^2(m^2-1)+1 is a square} < oo but bigger than for all preceding n.

Original entry on oeis.org

1, 2, 11, 14, 18, 23, 27, 34, 38, 44, 54, 59, 74, 158, 179, 284, 524
Offset: 1

Views

Author

M. F. Hasler, May 24 2007

Keywords

Comments

Most elements of this sequence seem to be 1,2 or 4 times a prime.
Corresponding values of A130280 are given in A130289. - M. F. Hasler, May 24 2007

Crossrefs

Programs

  • PARI
    A130288(L=999,S=1)={local(R,T);for(n=S,L, if(issquare(n) || R>=T=A130280(n),next); print1(n", ");R=T)}

A130289 Record values in A130280: minima of { m>1 | (2n+1)^2(m^2-1)+1 is a square} bigger than for all preceding n.

Original entry on oeis.org

3, 5, 7, 11, 13, 19, 21, 29, 31, 169, 419, 461, 3269, 7127, 3877019, 22783559, 215308729
Offset: 1

Views

Author

M. F. Hasler, May 24 2007

Keywords

Comments

Most elements of this sequence seem to be 1,2 or 4 times a prime.

Crossrefs

Programs

  • PARI
    A130289( L=999, S=1 )={ local( R, T ); for( n=S, L, if( issquare(n) || R >= T = A130280(n), next ); print1( T ", " ); R=T )}

A306767 Least x > 0 such that (x^2-1)/(y^2-1) = n, where y=A130280(n), or 0 if no such x exists.

Original entry on oeis.org

2, 7, 5, 0, 4, 7, 13, 5, 0, 9, 23, 17, 14, 41, 11, 7, 16, 55, 39, 31, 8, 23, 91, 19, 0, 25, 109, 15, 59, 49, 61, 79, 10, 169, 29, 17, 36, 191, 131, 11, 83, 71, 85, 1121, 19, 47, 281, 41, 0, 49, 35, 79, 160, 3079, 21, 13, 37, 175, 3541, 209, 62, 433, 55, 31, 14, 23, 401, 239
Offset: 1

Views

Author

Jinyuan Wang, Apr 13 2019

Keywords

Crossrefs

Programs

  • PARI
    a(n, L=10^15) = if(issquare(n), L=2+n^2); for(k=2, L, if((k^2-1)%n==0,if(issquare(1+(k^2-1)/n), return(k))));

Formula

a(n) = sqrt(n*(A130280(n)^2-1) + 1).
a(A130283(n)) = 0.
Showing 1-5 of 5 results.