A088797 Numbers n > 2 such that n divides the concatenation of n-2 and n-1.
3, 7, 67, 667, 6667, 66667, 666667, 2857143, 6666667, 66666667, 666666667, 1052631579, 6666666667, 66666666667, 666666666667, 2857142857143, 6666666666667, 11764705882353, 66666666666667, 666666666666667
Offset: 1
Examples
a(2)=7 because (7-2) concatenated with (7-1) yields 56 and 7 is a divisor of 56. a(4)=667 because 667 is a divisor of 665666. .
Links
- Robert Israel, Table of n, a(n) for n = 1..1285 (n = 1..104 from Robert G. Wilson v)
Programs
-
Maple
M:= 20: # to get all terms with <= M digits select(type, [seq(seq((2*10^m+1)/k, k=[19,17,7,3]),m=1..M)],integer); # Robert Israel, Oct 18 2015
-
Mathematica
Select[ Range[8250000000], Mod[ FromDigits[ Join[ IntegerDigits[ # - 2], IntegerDigits[ # - 1]]], # ] == 0 &] fQ[n_] := Mod[ FromDigits[ Join[ IntegerDigits[n - 2], IntegerDigits[n - 1]]], n] == 0; k = 1; lst = {}; Select[ Flatten@ Table[ Select[ Divisors[4*10^n + 2], 10^(n - 1) < # < 10^n &], {n, 15}], fQ] (* Robert G. Wilson v, Sep 05 2015 *)
-
PARI
for(n=3, 1e6, if((k=eval(Str(n-2,n-1))) && k % n == 0, print1(n", "))) \\ Altug Alkan, Sep 25 2015
Extensions
Extended by Robert G. Wilson v, Oct 21 2003
Further terms from Chuck Seggelin, Oct 29 2003
Comments