A309263
Terms of A140110 that are not divisible by 6.
Original entry on oeis.org
1, 2, 4, 8, 16, 20, 32, 64, 100, 128, 256, 272, 500, 512, 1024, 2048, 2500, 4096, 4624, 8192, 10100, 12500, 16384, 32768, 62500, 65536, 65792, 78608, 131072, 262144, 312500, 524288, 1020100, 1048576, 1336336, 1562500, 2097152, 4194304, 7812500, 8388608
Offset: 1
20 is in this sequence because it is in A140110 and is not divisible by 6.
24, which is in A140110, is not in this sequence because it is divisible by 6.
-
isok(n) = {if(n%6 == 0, return(0)); my(d = divisors(n)); for (k=1, #d - 1, r = d[k+1]/d[k]; if(numerator(r) != denominator(r) + 1, return(0)); ); return(1); } \\ Jinyuan Wang, Aug 03 2019
A280963
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.
Original entry on oeis.org
1, 3, 9, 15, 27, 75, 81, 99, 243, 255, 315, 375, 729, 783, 1089, 1875, 2187, 4335, 6561, 6723, 9375, 9999, 11979, 19683, 22707, 46875, 59049, 65535, 73695, 99855, 131769, 177147, 234375, 531441, 558009, 658503, 1009899, 1171875, 1188099, 1252815, 1449459, 1594323
Offset: 1
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
-
Select[Range[10^6], Times @@ Boole@ Map[Denominator@ # - Numerator@ # == 2 &, Divide @@@ Partition[Divisors@ #, 2, 1]] == 1 &] (* Michael De Vlieger, Jan 11 2017 *)
-
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);}
A280964
a(n) is the least term that is not a power of p, the n-th prime, in the sequence of numbers whose consecutive divisors have a ratio satisfying numerator - denominator = p-1.
Original entry on oeis.org
6, 15, 725, 91, 15851, 30589, 6977093777, 703
Offset: 1
a(1) = 6 is the first non-(prime power) of 2 (the 1st prime) in A140110.
a(2) = 15 is the first non-(prime power) of 3 (the 2nd prime) in A280963.
For n=3, p=5, the sequence begins: 1, 5, 25, 125, 625, 725, ... so a(3)=725.
For n=4, p=7, the sequence begins: 1, 7, 49, 91, 343, ... so a(4)=91.
-
Table[Function[p, SelectFirst[Range[10^5], Function[n, And[! IntegerQ@ Log[p, n], Times @@ Boole@ Map[Abs[Numerator@ # - Denominator@ #] == p - 1 &[#2/#1] & @@ # &, Partition[Divisors@ n, 2, 1]] > 0]] ]]@ Prime@ n /. k_ /; MissingQ@ k -> Nothing, {n, 6}] (* Michael De Vlieger, Jan 13 2017, Version 10.2 *)
-
isok(n, plus) = {my(vd = divisors(n)); for (k=1, #vd - 1, r = vd[k+1]/vd[k]; if (numerator(r) != denominator(r) + plus, return(0));); return(1);}
isokp(k) = (k!= 1) && !isprime(k) && ! isprimepower(k);
findnp(n) = {k = 1; ok = 0; nb = 0; while (! ok, okk = isok(k, n); if (okk, ok = isokp(k); if (! ok, nb++);); if (!ok, k++);); k;}
lista(nn) = for(n=1, nn, print1(findnp(prime(n)-1), ", "));
-
/ * alternate program; does it give the least terms? */
isokplus(n, plus) = {my(vd = divisors(n)); for (k=1, #vd - 1, r = vd[k+1]/vd[k]; if (numerator(r) != denominator(r) + plus, return(0));); return(1);}
findqq(p) = {ok = 0; ip = 1; while (!ok, ik = 1; while (!ok, if (isprime(q= ik*p^ip+(p-1)) && isokplus(p^ip*q, p-1), return([p^ip, q])); ik++; if (ik > p, break);); ip ++;); return ([]);}
listff(nn) = {for (n=1, nn, p = prime(n); v = findqq(p); pp = v[1]; q = v[2]; print1(pp*q, ", "););}
Showing 1-3 of 3 results.
Comments