OFFSET
1,2
COMMENTS
This sequence is similar to A140110. Both sequences concern numbers such that consecutive divisors of these numbers have a ratio which is of the form (k+1)/k for A140110 and (k+2)/k for this sequence.
So for each q >= 1, one can define a corresponding sequence where the said ratio is of the form (k+q)/k. It appears that such sequences are reduced to a single term 1 when q+1 is not prime. On the other hand when p=q-1 is prime (see A006093), then these sequences include the terms 1, p, p^2, .... so they are infinite.
The sequence of powers of 3 (A000244) is a subsequence. And all terms except 1 are divisible by p, here 3.
EXAMPLE
9 is in the sequence for the following reason. Divisors of 9 are {1,3,9}; ratios formed by pairing adjacent divisors are 3/1,9/3, both reduce to 3/1. The difference between numerator and denominator is 2 in both cases. - Michael De Vlieger, Jan 11 2017
MATHEMATICA
Select[Range[10^6], Times @@ Boole@ Map[Denominator@ # - Numerator@ # == 2 &, Divide @@@ Partition[Divisors@ #, 2, 1]] == 1 &] (* Michael De Vlieger, Jan 11 2017 *)
PROG
(PARI) isok(n) = {my(vd = divisors(n)); for (k=1, #vd - 1, r = vd[k+1]/vd[k]; if (numerator(r) != denominator(r) + 2, return(0)); ); return(1); }
CROSSREFS
KEYWORD
nonn
AUTHOR
Michel Marcus, Jan 11 2017
STATUS
approved