login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A088797 Numbers n > 2 such that n divides the concatenation of n-2 and n-1. 15

%I

%S 3,7,67,667,6667,66667,666667,2857143,6666667,66666667,666666667,

%T 1052631579,6666666667,66666666667,666666666667,2857142857143,

%U 6666666666667,11764705882353,66666666666667,666666666666667

%N Numbers n > 2 such that n divides the concatenation of n-2 and n-1.

%C For a 10-digit number, the difference between cat((n+2),(n+1)) and cat((n-2),(n-1)) is 40000000002 (as long as n-2 to n+2 are all numbers with the same number of digits). This difference has only 3 divisors which are ten digits long (1052631579, 2105263158 and 6666666667) of which two belong to the sequence. As 40000000002 has no other 10-digit factors, it is necessary to consider 11-digit numbers to obtain more terms.

%C From _Robert G. Wilson v_, Oct 21 2003, Oct 28 2003, Sep 23 2015 & Oct 24 2015: (Start)

%C All numbers of the forms

%C 2(10^n-1)/3 + 1,

%C floor(2(10^(6n + 1) - 1)/7 + 1),

%C floor(2(10^(16n - 2) - 1)/17 + 1), and

%C floor(2(10^(18n - 8) - 1)/19 + 1), for n > 0 are members.

%C The only term not one of the above forms so far is 3. But it is included when n=0 for the second form.

%C (End)

%C If numbers less than 3 are acceptable, then an argument could be made that 1 is a terms since cat(n-2,n-1) is -10 which is == 0 (mod 1). - _Robert G. Wilson v_, Sep 29 2015

%C From _Robert Israel_, Oct 18 2015: (Start)

%C Numbers n of the form (2*10^m + 1)/k where k = 3, or k = 7 and m == 1 mod 6, or k = 17 and m == 14 mod 16, or k = 19 and m == 10 mod 18.

%C This is because n | (n-2)*10^m + (n-1) iff n | 2*10^m + 1.

%C But since we need 10^m >= n > 10^(m-1), 2*10^m+1 = k*n where 3 <= k <= 20.

%C The only numbers in that range that ever divide 2*10^m+1 are 3,7,17,19. (End)

%H Robert Israel, <a href="/A088797/b088797.txt">Table of n, a(n) for n = 1..1285</a> (n = 1..104 from Robert G. Wilson v)

%e a(2)=7 because (7-2) concatenated with (7-1) yields 56 and 7 is a divisor of 56.

%e a(4)=667 because 667 is a divisor of 665666.

%e .

%p M:= 20: # to get all terms with <= M digits

%p select(type, [seq(seq((2*10^m+1)/k, k=[19,17,7,3]),m=1..M)],integer); # _Robert Israel_, Oct 18 2015

%t Select[ Range[8250000000], Mod[ FromDigits[ Join[ IntegerDigits[ # - 2], IntegerDigits[ # - 1]]], # ] == 0 &]

%t 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 *)

%o (PARI) for(n=3, 1e6, if((k=eval(Str(n-2,n-1))) && k % n == 0, print1(n", "))) \\ _Altug Alkan_, Sep 25 2015

%Y Cf. A069860, A069862, A069871, A088798.

%K base,nonn

%O 1,1

%A Chuck Seggelin (barkeep(AT)plastereddragon.com), Oct 18 2003

%E Extended by _Robert G. Wilson v_, Oct 21 2003

%E Further terms from Chuck Seggelin (barkeep(AT)plastereddragon.com), Oct 29 2003

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 21 20:44 EDT 2019. Contains 328315 sequences. (Running on oeis4.)