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.

A280892 Squareful numbers with both neighbors squarefree.

Original entry on oeis.org

4, 12, 16, 18, 20, 32, 36, 40, 52, 54, 56, 60, 68, 72, 84, 88, 90, 92, 96, 104, 108, 112, 128, 132, 140, 144, 150, 156, 160, 162, 164, 180, 184, 192, 196, 198, 200, 204, 212, 216, 220, 228, 232, 234, 236, 240, 248, 250, 252, 256, 264, 268, 270, 272, 284, 292, 294, 300, 304, 306, 308, 312
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jan 16 2017

Keywords

Comments

Subsequence of A013929 and A067874.
The asymptotic density of this sequence is Product_{p prime} (1 - 2/p^2) - Product_{p prime} (1 - 3/p^2) = 0.197147118033435... (Mossinghoff et al., 2021). - Amiram Eldar, Nov 11 2021, Mar 21 2024

Examples

			4 is in this sequence because 4 = 2^2 is nonsquarefree and both 4 - 1 = 3 and 4 + 1 = 5 are squarefree.
		

Crossrefs

Programs

  • Magma
    [n: n in [2..300] | not IsSquarefree(n) and IsSquarefree(n-1) and IsSquarefree(n+1)];
    
  • Mathematica
    Mean/@SequencePosition[Table[If[SquareFreeQ[n],1,0],{n,400}],{1,0,1}] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Sep 19 2020 *)
  • PARI
    isok(n) = !issquarefree(n) && issquarefree(n-1) && issquarefree(n+1); \\ Michel Marcus, Jun 18 2017

Extensions

Definition corrected by Jon E. Schoenfield, Jun 18 2017