A327501 Maximum divisor of n that is 1 or not a perfect power.
1, 2, 3, 2, 5, 6, 7, 2, 3, 10, 11, 12, 13, 14, 15, 2, 17, 18, 19, 20, 21, 22, 23, 24, 5, 26, 3, 28, 29, 30, 31, 2, 33, 34, 35, 18, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 7, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 2, 65, 66, 67, 68, 69
Offset: 1
Keywords
Examples
The divisors of 36 that are not perfect powers are {1, 2, 3, 6, 12, 18}, so a(36) = 18.
Links
- Andrew Howroyd, Table of n, a(n) for n = 1..10000
- Gus Wiseman, Sequences counting and encoding certain classes of multisets
Crossrefs
Programs
-
Magma
[1] cat [Max([d:d in Divisors(n)| d gt 1 and not IsPower(d)]):n in [2..70]]; // Marius A. Burtea, Sep 20 2019
-
Mathematica
Table[Max[Select[Divisors[n],GCD@@Last/@FactorInteger[#]==1&]],{n,100}]
-
PARI
isp(n) = !ispower(n) && (n>1); \\ A007916 a(n) = if (n==1, 1, vecmax(select(x->isp(x), divisors(n)))); \\ Michel Marcus, Sep 18 2019
Comments