%I #103 Jul 25 2024 14:22:25
%S 6,12,18,20,21,24,30,36,40,42,48,54,60,63,66,72,78,80,84,90,96,100,
%T 102,105,108,110,114,120,126,132,136,138,140,144,147,150,155,156,160,
%U 162,168,174,180,186,189,192,198,200,204,210,216,220,222,228,231,234,240
%N Numbers m such that 2^m - 1 is divisible by a square > 1.
%C Conjecture: 2^n-1 is squarefree iff gcd(n,2^n-1)=1. If true, the conjecture would imply that Mersenne numbers (A001348) are squarefree. - _Vladeta Jovovic_, Apr 12 2002. But the conjecture is not true: counterexamples are n = 364 and n = 1755, i.e., gcd(364,2^364-1) = 1 and (2^364-1) mod 1093^2 = 0 and gcd(1755,2^1755-1) = 1 and (2^1755-1) mod 3511^2 = 0, cf. A001220. - _Vladeta Jovovic_, Nov 01 2005. The conjecture is true with assumption that n is not a multiple of A002326((q-1)/2), where q is a Wieferich prime A001220. - _Thomas Ordowski_, Nov 17 2015
%C If d|n and 2^d-1 is not squarefree, then 2^n-1 cannot be squarefree. For example, if 6 is in the sequence then 6*d is also. - _Enrique Pérez Herrero_, Feb 28 2009
%C If p(p-1)|n then p^2|2^n-1, where p is an odd prime. - _Thomas Ordowski_, Jan 22 2014
%C The primitive elements of this sequence are A237043. - _Charles R Greathouse IV_, Feb 05 2014
%C Dilcher & Ericksen prove that this sequence is exactly the set of numbers divisible by either t(p)p for a Wieferich prime p>2 or t(p) for a non-Wieferich prime p, where t(p) is the order of 2 modulo p (see Proposition 3.1). - _Kellen Myers_, Jun 09 2015
%C If d^2 divides 2^n-1 then d divides n, where n is not a multiple of 364, 1755, ...; i.e., A002326((q-1)/2) for Wieferich primes q, A001220. - _Thomas Ordowski_, Nov 15 2015
%C (1, 2^n-1, 2^n) is an abc triple iff 2^n-1 is not squarefree. - _William Hu_, Jul 04 2024
%D R. K. Guy, Unsolved Problems in Number Theory, A3.
%H Max Alekseyev, <a href="/A049094/b049094.txt">Table of n, a(n) for n = 1..296</a>
%H Karl Dilcher and Larry Ericksen, <a href="http://www.jstor.org/stable/10.4169/amer.math.monthly.122.04.338">The Polynomials of Mahler and Roots of Unity</a>, The American Mathematical Monthly, Vol. 122, No. 04 (April 2015), pp. 338-353.
%H Enrique Pérez Herrero, <a href="http://psychedelic-geometry.blogspot.com/2009/02/mersenne-numbers-teasure-map.html">Mersenne Numbers Treasure Map</a>, Psych Geom blogspot, 02/17/09
%H Andy Steward, <a href="http://www.users.globalnet.co.uk/~aads/faclist.html">Factorizations of Generalized Repunits</a> [Dead link]
%e a(2)=12 because 2^12 - 1 = 4095 = 5*(3^2)*7*13 is divisible by a square.
%p N:= 250:
%p B:= Vector(N):
%p for n from 1 to N do
%p if B[n] <> 1 then
%p F:= ifactors(2^n-1,easy)[2];
%p if max(seq(t[2],t=F)) > 1 or (hastype(F,symbol)
%p and not numtheory:-issqrfree(2^n-1)) then
%p B[[seq(n*k,k=1..floor(N/n))]]:= 1;
%p fi
%p fi;
%p od:
%p select(t -> B[t]=1, [$1..N]); # _Robert Israel_, Nov 17 2015
%t Select[Range[240], !SquareFreeQ[2^#-1]&] (* _Vladimir Joseph Stephan Orlovsky_, Mar 18 2011 *)
%o (PARI) default(factor_add_primes,1);
%o is(n)=my(f=factor(n>>valuation(n,2))[,1],N,o); for(i=1,#f,if(n%(f[i]-1) == 0, return(1))); N=2^n-1; fordiv(n,d,f=factor(2^d-1)[,1]; for(i=1,#f, if(d==n,return(!issquarefree(N))); o=valuation(N,f[i]); if(o>1, return(1)); N/=f[i]^o)) \\ _Charles R Greathouse IV_, Feb 02 2014
%o (PARI) is(n)=!issquarefree(2^n-1) \\ _Charles R Greathouse IV_, Feb 04 2014
%o (Magma) [n: n in [1..250] | not IsSquarefree(2^n-1)]; // _Vincenzo Librandi_, Jul 14 2015
%Y Cf. A001220, A001348, A002326, A014491, A049093, A049096, A049095, A237043, A282242, A282243.
%K nonn
%O 1,1
%A _Labos Elemer_
%E More terms from _Vladeta Jovovic_, Apr 12 2002
%E Definition corrected by _Jonathan Sondow_, Jun 29 2010