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.

A378032 a(1) = a(2) = 1; a(n>2) is the greatest nonsquarefree number < prime(n).

Original entry on oeis.org

1, 1, 4, 4, 9, 12, 16, 18, 20, 28, 28, 36, 40, 40, 45, 52, 56, 60, 64, 68, 72, 76, 81, 88, 96, 100, 100, 104, 108, 112, 126, 128, 136, 136, 148, 150, 156, 162, 164, 172, 176, 180, 189, 192, 196, 198, 208, 220, 225, 228, 232, 236, 240, 250, 256, 261, 268, 270
Offset: 1

Views

Author

Gus Wiseman, Nov 16 2024

Keywords

Examples

			The terms together with their prime indices begin:
    1: {}
    1: {}
    4: {1,1}
    4: {1,1}
    9: {2,2}
   12: {1,1,2}
   16: {1,1,1,1}
   18: {1,2,2}
   20: {1,1,3}
   28: {1,1,4}
   28: {1,1,4}
   36: {1,1,2,2}
   40: {1,1,1,3}
   40: {1,1,1,3}
   45: {2,2,3}
   52: {1,1,6}
   56: {1,1,1,4}
   60: {1,1,2,3}
   64: {1,1,1,1,1,1}
   68: {1,1,7}
   72: {1,1,1,2,2}
		

Crossrefs

Terms appearing twice are A061351 + 1.
For prime-powers we have A065514 (diffs A377781), opposite A345531 (diffs A377703).
For squarefree we have A112925 (differences A378038).
The opposite for squarefree is A112926 (differences A378037).
The opposite is A377783 (union A378040), restriction of A120327 (differences A378039).
Restriction of A378033, which has differences A378036.
The first-differences are A378034, opposite A377784.
A000040 lists the primes, differences A001223, seconds A036263.
A005117 lists the squarefree numbers.
A013929 lists the nonsquarefree numbers, differences A078147, seconds A376593.
A061398 counts squarefree numbers between primes (sums A337030), zeros A068360.
A061399 counts nonsquarefree numbers between primes (sums A378086), zeros A068361.
A070321 gives the greatest squarefree number up to n.
A377046 encodes k-differences of nonsquarefree numbers, zeros A377050.

Programs

  • Mathematica
    Table[NestWhile[#-1&,Prime[n],#>1&&SquareFreeQ[#]&],{n,100}]

Formula

a(n) = A378033(prime(n)).