login
A063163
Composite numbers which in base 7 contain their largest proper factor as a substring.
1
49, 77, 91, 119, 133, 161, 203, 217, 259, 287, 301, 329, 343, 371, 413, 427, 469, 497, 511, 539, 551, 553, 581, 623, 637, 679, 707, 721, 749, 763, 791, 833, 847, 889, 917, 931, 959, 973, 989, 1001, 1043, 1057, 1099, 1127, 1141, 1169, 1183, 1211, 1253
OFFSET
1,1
COMMENTS
Sequence contains every term of A084968 except 7. - Bill McEachen, Dec 29 2020
LINKS
EXAMPLE
91 = 160_7 and its largest proper factor is 13 = 16_7 where 16 is a substring of 160. - Bill McEachen, Dec 30 2020
MATHEMATICA
Do[ If[ !PrimeQ[ n ] && StringPosition[ ToString[ FromDigits[ IntegerDigits[ n, 7 ] ] ], ToString[ FromDigits[ IntegerDigits[ Divisors[ n ] [ [ -2 ] ], 7 ] ] ] ] != {}, Print[ n ] ], {n, 2, 2000} ]
Select[Range[1300], CompositeQ[#]&&SequenceCount[IntegerDigits[#, 7], IntegerDigits[ Divisors[#][[-2]], 7]]>0&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Feb 21 2021 *)
PROG
(PARI) isok(n)={mystr=digits(n, 7); d=divisors(n); gpf=d[#d-1]; seek=digits(gpf, 7); ls=#seek; for(w=1, #mystr-ls+1, if(mystr[w]!=seek[1], next); for(h=1, ls-1, if(mystr[w+h]!=seek[h+1], break); if(h==ls-1, return(1)))); return(0); } \\ Bill McEachen, Dec 31 2020
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Robert G. Wilson v, Aug 08 2001
STATUS
approved