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.

A087414 Numbers n such that 2*n*k(n) is rational but not an integer, where k(n) is sum of successive remainders when computing the Euclidean algorithm for (1, 1/sqrt(n)) as defined in A086378 (MuPAD program is given there); numbers belonging to A086378 but not to A088900.

Original entry on oeis.org

153, 1717, 2244, 2340, 3525, 3650, 6460, 7119, 7475, 10074, 14490, 19147, 20008, 20862, 21424, 21747, 24453, 25400, 26039, 27346, 28028, 28371, 31484, 35483, 37008, 44275, 44678, 45974, 50389, 52155, 62187, 63724, 64752
Offset: 1

Views

Author

Thomas Baruchel, Oct 21 2003

Keywords

Crossrefs

Cf. A086378 and A088900.

Programs

  • PARI
    /* z(n)!=0 iff n is in the sequence */
    z(n)= { local(a,b,c,d,e,f,g,h,i,j,k);
    b=a=sqrtint(n);d=f=i=1;e=g=h=0;j=c=n-a^2;if(!c,return(0));
    until((a==b)&&(c==j),k=d+a*e;f*=c;d=a*d+e*n;e=k;g+=i;i*=c;
    k=g+a*h;g=a*g+h*n;h=k;k=(a+b)\c;g-=i*k;a=c*k-a;c=(n-a^2)/c);
    d=d/f-1;e/=f;g/=i;h/=i;i=d^2-n*e^2;k=h*d-g*e;g=g*d-h*e*n;
    b=n-a^2;a=b*g-c*a*i;c=b*k+i*c;b*=i;!a*(2%(b/gcd(b,n*c))); }