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.

A073247 Squarefree numbers k such that k-1 and k+1 are not squarefree.

Original entry on oeis.org

17, 19, 26, 51, 53, 55, 89, 91, 97, 127, 149, 151, 161, 163, 170, 197, 199, 233, 235, 241, 249, 251, 269, 271, 293, 295, 305, 307, 337, 339, 341, 349, 362, 377, 379, 413, 415, 449, 451, 485, 487, 489, 491, 521, 523, 530, 551, 557, 559, 577, 579, 593, 595
Offset: 1

Views

Author

Reinhard Zumkeller, Jul 22 2002

Keywords

Comments

Probably 11*n < a(n) < 12*n for n > 189. - Charles R Greathouse IV, Nov 05 2017
The asymptotic density of this sequence is 1/zeta(2) - 2 * Product_{p prime} (1 - 2/p^2) + Product_{p prime} (1 - 3/p^2) = A059956 - 2*A065474 + A206256 = 0.088145884881346585838... . - Amiram Eldar, Aug 30 2024

Crossrefs

Cf. A268331, A268332, A268333, A268334 (squarefree numbers isolated by more than 2, 3, etc.).

Programs

  • Maple
    sf:= select(numtheory:-issqrfree,[$1..1000]):
    map(t -> `if`(sf[t-1]=sf[t]-1 or sf[t+1]=sf[t]+1,NULL,sf[t]), [$2..nops(sf)-1]); # Robert Israel, Feb 01 2016
  • Mathematica
    Reap[For[n = 0, n <= 1000, n++, If[SquareFreeQ[n] && !SquareFreeQ[n-1] && !SquareFreeQ[n+1], Sow[n]]]][[2, 1]] (* Jean-François Alcover, Feb 26 2019 *)
  • PARI
    is(n)=!issquarefree(n-1) && issquarefree(n) && !issquarefree(n+1) \\ Charles R Greathouse IV, Nov 05 2017
    
  • PARI
    list(lim)=my(v=List(),l1,l2); forfactored(k=9,lim\1+1, if(!issquarefree(k) && !issquarefree(l2) && issquarefree(l1), listput(v,l1[1])); l2=l1; l1=k); Vec(v) \\ Charles R Greathouse IV, Nov 27 2024

A268332 Squarefree numbers differing by more than 3 from any other squarefree number.

Original entry on oeis.org

2526, 44405, 47527, 47973, 55779, 72474, 101037, 106327, 106674, 109023, 110107, 133577, 153173, 165574, 183553, 186247, 193026, 196747, 208847, 209674, 212127, 218527, 220209, 234622, 237522, 245149, 261478, 266853, 269953, 308649, 328877, 334522, 342066, 364151, 370785, 375823
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Maple
    SF:= select(numtheory:-issqrfree, [$1..10^6]):
    SF[select(i -> SF[i]-SF[i-1]>=4  and SF[i+1]-SF[i]>=4, [$2..nops(SF)-1])]; # Robert Israel, Feb 02 2016

A268334 Squarefree numbers differing by more than 5 from any other squarefree number.

Original entry on oeis.org

8061827, 60529549, 82490423, 213819827, 245990821, 360350923, 364661627, 465966527, 494501773, 531794155, 651012673, 661327077, 665519027, 693770521, 765921647, 800254429, 826112857, 836818573, 885970253, 914588627, 930996623, 936321349, 958710973, 992890427, 1069677149
Offset: 1

Views

Author

Keywords

Crossrefs

A268330 Least squarefree number differing by more than n from any other squarefree number.

Original entry on oeis.org

1, 17, 26, 2526, 5876126, 8061827, 8996188226, 2074150570370
Offset: 0

Views

Author

Keywords

Comments

1.8*10^12 < a(7) <= 10735237201449 - Robert Israel, Mar 18 2016
a(8) > 5*10^12. - Giovanni Resta, Apr 11 2016

Examples

			a(2) = 26 because 26 is squarefree but 24,25,27,28 are not.
		

Crossrefs

Programs

  • MATLAB
    B = 10^8; % blocks of size B
    nB = 1000; % nB blocks
    A = [1];
    P = primes(floor(sqrt(nB*B)));
    mmax = 1;
    i0 = 1;
    for k = 0:nB-1  % search squarefrees from i0+1 to i0 + B
      V = true(1, B);
      for i = 1:numel(P)
        p = P(i);
        V([(p^2 - mod(i0,p^2)):p^2:B]) = false;
      end
      SF = find(V) + i0;
      DSF = SF(2:end) - SF(1:end-1);
      i0 = SF(end-2);
      M = min(DSF(1:end-1), DSF(2:end));
      newmax = max(mmax,max(M));
      for i = mmax+1:newmax
        A(i) = SF(1 + find(M>=i, 1, 'first'));
      end
      mmax = newmax;
    end
    for i=1:mmax
      fprintf('%d ',A(i));
    end
    fprintf('\n');  % Robert Israel, Mar 16 2016
  • Mathematica
    (* implementation assumes a(n) is increasing *)
    nsfRun[n_]:=Module[{i=n}, While[!SquareFreeQ[i], i++]; i-n]
    a268330[{low_, high_}, width_]:=Module[{k=width, i, next, r, s, list={}}, For[i=low, i<=high, i+=next, r=nsfRun[i]; If[r0 (* Hartmut F. W. Hoft, Mar 15 2016 *)
    a268330[{0,10000000},1] (* computes a(1)...a(5) *)

Extensions

a(6) from Hartmut F. W. Hoft, Mar 15 2016
a(7) from Giovanni Resta, Apr 11 2016

A268333 Squarefree numbers differing by more than 4 from any other squarefree number.

Original entry on oeis.org

5876126, 8061827, 19375679, 27926071, 29002021, 29850943, 39224453, 39728861, 54427974, 56389147, 60529549, 63520174, 67806346, 71987374, 75239979, 82490423, 87011827, 91332377, 97447622, 99368949, 100842249, 107447838, 110196277, 118389143, 134817726, 149840974, 159140777, 161651279
Offset: 1

Views

Author

Keywords

Crossrefs

Showing 1-5 of 5 results.