The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A059267 Numbers n with 2 divisors d1 and d2 having difference 2: d2 - d1 = 2; equivalently, numbers that are 0 (mod 4) or have a divisor d of the form d = m^2 - 1. 6

%I #43 Jun 26 2023 04:29:37

%S 3,4,6,8,9,12,15,16,18,20,21,24,27,28,30,32,33,35,36,39,40,42,44,45,

%T 48,51,52,54,56,57,60,63,64,66,68,69,70,72,75,76,78,80,81,84,87,88,90,

%U 92,93,96,99,100,102,104,105,108,111,112,114,116,117,120,123,124,126,128

%N Numbers n with 2 divisors d1 and d2 having difference 2: d2 - d1 = 2; equivalently, numbers that are 0 (mod 4) or have a divisor d of the form d = m^2 - 1.

%C Complement of A099477; A008586, A008585 and A037074 are subsequences - _Reinhard Zumkeller_, Oct 18 2004

%C These numbers have an asymptotic density of ~ 0.522. This corresponds to all numbers which are multiples of 4 (25%), or of 3 (having 1 & 3 as divisors: + (1-1/4)*1/3 = 1/4), or of 5*7, or of 11*13, etc. (Generally, multiples of lcm(k,k+2), but multiples of 3 and 4 are already taken into account in the 50% covered by the first 2 terms.) - _M. F. Hasler_, Jun 02 2012

%C By considering divisors of the form m^2-1 with m <= 200 it is possible to prove that the density of this sequence is in the interval (0.5218, 0.5226). The numbers of terms not exceeding 10^k, for k = 1, 2, ..., are 5, 52, 521, 5219, 52206, 522146, 5221524, 52215473, 522155386, 5221555813, ..., so the asymptotic density of this sequence can be estimated empirically by 0.522155... . - _Amiram Eldar_, Sep 25 2022

%H M. F. Hasler, <a href="/A059267/b059267.txt">Table of n, a(n) for n = 1..3131</a>

%F A099475(a(n)) > 0. - _Reinhard Zumkeller_, Oct 18 2004

%e a(18) = 35 because 5 and 7 divide 35 and 7 - 5 = 2.

%p isA059267 := proc(n)

%p local m ;

%p if modp(n,4)=0 then

%p true;

%p else

%p for m from 2 to ceil(sqrt(n)) do

%p if modp(n,m^2-1) = 0 then

%p return true ;

%p end if;

%p end do;

%p false ;

%p end if;

%p end proc:

%p for n from 1 to 130 do

%p if isA059267(n) then

%p printf("%d,",n) ;

%p end if;

%p end do:

%t d1d2Q[n_]:=Mod[n,4]==0||AnyTrue[Sqrt[#+1]&/@Divisors[n],IntegerQ]; Select[ Range[ 200],d1d2Q] (* _Harvey P. Dale_, May 31 2020 *)

%o (PARI) isA059267(n)={ n%4==0 || fordiv( n,d, issquare(d+1) && return(1))} \\ _M. F. Hasler_, Aug 29 2008

%o (PARI) is_A059267(n) = fordiv( n,d, n%(d+2)||return(1)) \\ _M. F. Hasler_, Jun 02 2012

%Y Cf. A099475, A099477, A008585, A008586, A037074.

%K nonn

%O 1,1

%A Avi Peretz (njk(AT)netvision.net.il), Jan 23 2001

%E More terms from _James A. Sellers_, Jan 24 2001

%E Removed comments linking to A143714, which seem wrong, as observed by _Ignat Soroko_, _M. F. Hasler_, Jun 02 2012

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 18 03:43 EDT 2024. Contains 372618 sequences. (Running on oeis4.)