%I #12 Jan 12 2017 06:36:15
%S 1,3,9,15,27,75,81,99,243,255,315,375,729,783,1089,1875,2187,4335,
%T 6561,6723,9375,9999,11979,19683,22707,46875,59049,65535,73695,99855,
%U 131769,177147,234375,531441,558009,658503,1009899,1171875,1188099,1252815,1449459,1594323
%N Numbers n such that for all divisors of n, ratios of 2 consecutive divisors of n will always reduce to lowest terms to a fraction with numerator=denominator+2.
%C 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.
%C 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.
%C The sequence of powers of 3 (A000244) is a subsequence. And all terms except 1 are divisible by p, here 3.
%e 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
%t Select[Range[10^6], Times @@ Boole@ Map[Denominator@ # - Numerator@ # == 2 &, Divide @@@ Partition[Divisors@ #, 2, 1]] == 1 &] (* _Michael De Vlieger_, Jan 11 2017 *)
%o (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);}
%Y Cf. A000244, A006093, A140110.
%K nonn
%O 1,2
%A _Michel Marcus_, Jan 11 2017