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

A249739 The smallest prime whose square divides n, 1 if n is squarefree.

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 2, 3, 1, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 5, 1, 3, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 3, 1, 1, 2, 7, 5, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 1, 3, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 5, 2, 1, 1, 1, 2, 3, 1, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 7, 3, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 3, 1, 1, 2
Offset: 1

Views

Author

Antti Karttunen, Nov 04 2014

Keywords

Comments

A249740 gives the corresponding largest prime.
If n belongs to A013929, then a(n)>1. - Robert G. Wilson v, Nov 16 2016

Crossrefs

Differs from A071773 and A249740 for the first time at n=36, where a(36) = 2, while A249740(36) = 3 and A071773(36) = 6.

Programs

  • Mathematica
    Table[If[SquareFreeQ@ n, 1, p = 2; While[! Divisible[n, p^2], p = NextPrime@ p]; p], {n, 120}] (* Michael De Vlieger, Nov 15 2016 *)
  • PARI
    a(n) = {f = factor(n/core(n)); vsq = select(x->((x%2) == 0), f[,2], 1); if (#vsq, f[vsq[1], 1], 1);} \\ Michel Marcus, Mar 11 2017
  • Scheme
    (define (A249739 n) (let loop ((n n) (p (A020639 n))) (cond ((= 1 n) n) ((zero? (modulo n (* p p))) p) (else (loop (/ n p) (A020639 (/ n p)))))))
    

Formula

a(n) = A020639(A003557(n)). - Amiram Eldar, Feb 11 2021

A046028 Largest multiple prime factor of the n-th nonsquarefree number (A013929).

Original entry on oeis.org

2, 2, 3, 2, 2, 3, 2, 2, 5, 3, 2, 2, 3, 2, 2, 3, 2, 7, 5, 2, 3, 2, 2, 3, 2, 2, 3, 5, 2, 2, 3, 2, 2, 3, 2, 2, 7, 3, 5, 2, 3, 2, 2, 3, 2, 11, 2, 5, 3, 2, 2, 3, 2, 2, 3, 7, 2, 5, 2, 3, 2, 2, 3, 2, 2, 13, 3, 2, 5, 2, 3, 2, 2, 3, 2, 7, 3, 5, 2, 3, 2, 2, 3, 2, 2, 5, 2, 2, 3, 2, 2, 11, 3, 2, 7, 2, 5, 3, 2, 2, 3
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Haskell
    a046028 n = a046028_list !! (n-1)
    a046028_list = f 1 where
       f x | null zs   = f (x + 1)
           | otherwise = (fst $ head zs) : f (x + 1)
           where zs = reverse $ filter ((> 1) . snd) $
                      zip (a027748_row x) (a124010_row x)
    -- Reinhard Zumkeller, Dec 29 2012
    
  • Mathematica
    Select[ FactorInteger[#]//Reverse, #[[2]]>1&, 1][[1, 1]]& /@ Select[ Range[300], !SquareFreeQ[#]& ] (* Jean-François Alcover, Nov 06 2012 *)
  • Python
    from math import isqrt
    from sympy import mobius, factorint
    def A046028(n):
        def f(x): return n+sum(mobius(k)*(x//k**2) for k in range(1, isqrt(x)+1))
        m, k = n, f(n)
        while m != k:
            m, k = k, f(k)
        s = factorint(m)
        return next(p for p in sorted(s,reverse=True) if s[p]>1) # Chai Wah Wu, Jul 22 2024

Formula

a(n) = A249740(A013929(n)). - Amiram Eldar, Feb 11 2021

A283454 The square root of the smallest square referenced in A249025 (Numbers k such that 3^k - 1 is not squarefree).

Original entry on oeis.org

2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 13, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11, 2, 13, 2, 2, 2, 2, 11, 2, 2, 2, 2, 2, 11
Offset: 1

Views

Author

Robert Price, Mar 07 2017

Keywords

Comments

The terms are the smallest prime whose square divides 3^k-1, when it is not squarefree.

Examples

			A249025(3)=5, 3^5-1 = 242 = 2*11*11. 242 is not squarefree the square being 11*11 = 121, the root being 11.
		

Crossrefs

Programs

  • Mathematica
    p[n_] := If[(f = Select[FactorInteger[n], Last[#] > 1 &]) == {}, 1, f[[1, 1]]]; p /@ Select[3^Range[100] - 1, !SquareFreeQ[#] &] (* Amiram Eldar, Feb 12 2021 *)
  • PARI
    lista(nn) = {for (n=1, nn, if (!issquarefree(k = 3^n-1), f = factor(k/core(k)); vsq = select(x->((x%2) == 0), f[,2], 1); print1(f[vsq[1], 1], ", ");););} \\ Michel Marcus, Mar 11 2017

Formula

a(n) = A249739(A024023(A249025(n))). - Amiram Eldar, Feb 12 2021

Extensions

More terms from Michel Marcus, Mar 11 2017

A283919 The smallest square referenced in A013929 (Numbers that are not squarefree).

Original entry on oeis.org

4, 4, 9, 4, 4, 9, 4, 4, 25, 9, 4, 4, 4, 4, 4, 9, 4, 49, 25, 4, 9, 4, 4, 9, 4, 4, 4, 25, 4, 4, 9, 4, 4, 9, 4, 4, 49, 9, 4, 4, 4, 4, 4, 9, 4, 121, 4, 25, 9, 4, 4, 9, 4, 4, 4, 49, 4, 25, 4, 9, 4, 4, 9, 4, 4, 169, 9, 4, 25, 4, 4, 4, 4, 9, 4, 4, 9, 4, 4, 9, 4, 4
Offset: 1

Views

Author

Robert Price, Mar 17 2017

Keywords

Examples

			A013929(4) = 12, 12 = 2*2*3, so 12 is not squarefree, the square being 2*2 = 4.
		

Crossrefs

Programs

A384064 a(n) = s(n) divided by the smallest multiple prime factor of s(n), where s = A013929.

Original entry on oeis.org

2, 4, 3, 6, 8, 6, 10, 12, 5, 9, 14, 16, 18, 20, 22, 15, 24, 7, 10, 26, 18, 28, 30, 21, 32, 34, 36, 15, 38, 40, 27, 42, 44, 30, 46, 48, 14, 33, 50, 52, 54, 56, 58, 39, 60, 11, 62, 25, 42, 64, 66, 45, 68, 70, 72, 21, 74, 30, 76, 51, 78, 80, 54, 82, 84, 13, 57, 86
Offset: 1

Views

Author

Michael De Vlieger, Jun 23 2025

Keywords

Comments

a(n) is the largest proper nonunitary divisor of s(n).

Crossrefs

Programs

  • Mathematica
    Map[#/Select[FactorInteger[#], #[[-1]] > 1 &, 1][[1, 1]] &, Select[Range[200], Not @* SquareFreeQ] ] (* or *) Map[Select[Most@ Divisors[#], Not @* CoprimeQ] &, Select[Range[200], Not @* SquareFreeQ] ][[All, -1]]
  • Python
    from math import isqrt
    from sympy import mobius, factorint
    def A384064(n):
        def f(x): return n+sum(mobius(k)*(x//k**2) for k in range(1, isqrt(x)+1))
        m, k = n, f(n)
        while m != k:
            m, k = k, f(k)
        s = factorint(m)
        return m//next(p for p in sorted(s) if s[p]>1) # Chai Wah Wu, Jun 25 2025

Formula

a(n) = A013929(n)/A046027(n).

A046026 Smallest prime p dividing n#-1, n#, or n#+1, n squarefree.

Original entry on oeis.org

2, 2, 2, 3, 3, 3, 5, 7, 13, 7, 5, 17, 7, 7, 11, 23, 13, 5, 5, 5, 11, 17, 7, 23, 19, 13, 41, 7, 43, 23, 47, 17, 19, 11, 19, 29, 13, 17, 31, 13, 11, 67, 23, 7, 71, 53, 37, 11, 13, 29, 41, 83, 17, 43, 29, 89, 13, 31, 47, 19, 17, 101, 17, 103, 7, 53, 107, 109, 11, 37, 113, 19
Offset: 1

Views

Author

Keywords

References

  • C. Ashbacher, A Note on the Smarandache Near-To-Primorial Function, Smarandache Notions J. 7 (1996), 46-49.
  • M. R. Mudge, The Smarandache Near-To-Primorial Function, Abstracts of Papers Presented to the Amer. Math. Soc., 17 (1996), 585

Crossrefs

Cf. A002110 (primorial numbers), A046027, A013929.

Formula

Smallest prime p such that n divides one of p#-1, p#, p#+1
Showing 1-6 of 6 results.