A048943 Product of divisors of n is a square.
1, 6, 8, 10, 14, 15, 16, 21, 22, 24, 26, 27, 30, 33, 34, 35, 38, 39, 40, 42, 46, 51, 54, 55, 56, 57, 58, 60, 62, 65, 66, 69, 70, 72, 74, 77, 78, 81, 82, 84, 85, 86, 87, 88, 90, 91, 93, 94, 95, 96, 102, 104, 105, 106, 108, 110, 111, 114, 115, 118, 119, 120
Offset: 1
Keywords
Examples
From _Gerard P. Michon_, Oct 10 2010: (Start) a(1) = 1 because it's a fourth power. The product of all divisors of 1 is 1, which is a square. a(2) = 6 because 2^1.3^1 is the product of two primes with odd multiplicities (1 in both cases). Indeed, the divisor product 1.2.3.6 = 36 is a square. a(3) = 8 because 2 is a prime factor of 8 with multiplicity 3. Indeed, 1.2.4.8 = 64 is a square. a(7) = 16 because it's a fourth power; 1.2.4.8.16 = 1024 is the square of 32. (End)
Links
- T. D. Noe, Table of n, a(n) for n = 1..1000
- G. P. Michon, Divisor Product, Numericana.
- Eric Weisstein's World of Mathematics, Divisor Product
Crossrefs
Supersequence of A229153.
Programs
-
Mathematica
Select[Range[125], IntegerQ[Sqrt[Times @@ Divisors[#]]] &] (* T. D. Noe, Apr 30 2012 *)
-
PARI
{for(k=1, 126, mpc=1; M=divisors(k); for(i=1, matsize(M)[2], mpc=mpc*M[i]); if(issquare(mpc), print1(k, ", ")))} \\\ Douglas Latimer, Apr 30 2012
-
PARI
is(n)=my(f=factor(n)[,2]); gcd(f)%4==0 || #select(k->k%2, f)>1 || #select(k->k%4==3, f) \\ Charles R Greathouse IV, Sep 18 2015
-
Python
from sympy import divisor_count from gmpy2 import iroot A048943_list = [i for i in range(1,10**3) if iroot(i,4)[1] or not divisor_count(i) % 4] # Chai Wah Wu, Mar 10 2016
-
Sage
[n for n in (1..125) if prod(divisors(n)).is_square()] # Giuseppe Coppoletta, Dec 16 2014
Comments