login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A346276 Composite m-digit numbers with m <> 3k and digital product = 7 that are divisible by 7. 1
11711, 1111117, 7111111, 11171111, 1111711111, 11111111711, 11711111111, 1111111111117, 1111117111111, 7111111111111, 11111111171111, 11171111111111, 1111111111711111, 1111711111111111, 11111111111111711, 11111111711111111, 11711111111111111, 1111111111111111117, 1111111111117111111 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

Proposition: when m > 4 and m <> 3k, there is always at least one m-digit number that is divisible by 7 (proof in Derek Holton in reference), these composites are in this sequence (see A346274).

Every term has m = 5+6r, resp. (7+6r, 8+6r, 10+6r (r>=0)) digits and comes from the concatenation of a(1) = 11711, resp. (7, a(4) = 11171111, a(5) = 1111711111) with one or more strings of R_6 = 111111 = 7*15873 placed before and/or after a(1), resp. (7, a(4), a(5)).

The corresponding smallest term b(m) with m = 5+6r, resp. (7+6r, 8+6r, 10+6r (r>=0)) digits is b(m) = R_m + 6*10^k with k = 2, resp. (0, 4, 5) with R_m = A002275(m) is the repunit with a string of m 1's.

Alternatively, numbers viewed as strings over {1, 7} divisible by 7 are accepted by an automaton with 12 states, {0..6, 0'..6'} - {3, 3'}, with k (resp. k') representing remainder mod 7 where 7 has not (resp. has) been seen; transition function delta(k, 1) = 10*k+1 mod 7, delta(k, 7) = (10*k+7 mod 7)', delta(k', 1) = 10*k'+1 mod 7; start state 0; and accept state 0'. Accepted strings satisfy the regular expression (111111)*(7 + 11711 + 11171111 + 1111711111 + 111117111)(111111)*.  This sequence includes all terms matching (111111)*(7 + 11711 + 11171111 + 1111711111)(111111)* except the number 7 alone. - Michael S. Branicky, Jul 22 2021

REFERENCES

Derek Holton, A Second Step to Mathematical Olympiad Problems, Vol. 7, Mathematical Olympiad Series, World Scientific, 2011, Section 8.2. USS 1 p. 260 and Section 8.14 Solutions pp. 284-287.

LINKS

Table of n, a(n) for n=1..19.

EXAMPLE

a(1) = 11711 because 11711 has 5 digits, a digital product = 7 and 11711 = 7^2 * 239.

MATHEMATICA

seq[digmax_] := Module[{dig = Select[Range[5, digmax], Mod[#, 3] > 0 &], s = {}}, Do[s = Join[s, Select[(10^d - 1)/9 + 6*10^Range[0, d - 1], Divisible[#, 7] &]], {d, dig}]; s]; seq[19] (* Amiram Eldar, Jul 22 2021 *)

PROG

(Python)

from sympy import isprime

def auptod(digs):

  return [t for t in (int('1'*(m-1-i) + '7' + '1'*i) for m in range(5, digs+1) if m%3 != 0 for i in range(m)) if t%7 == 0]

print(auptod(19)) # Michael S. Branicky, Jul 22 2021

(PARI) a(n) = { my(q = floor((-3+sqrt(1+8*n))/4), s = [1, 2, 1, 1] + [1, 1, 1, 1] * q, c, b = [2, 0, 4, 5]); n -= (2*q^2 + 3*q); for(i = 1, 4, if(s[i] < n, n-=s[i] , c = i; break; ) ); qd = ceil(6*q + 3*c/2+7/2); 10^qd\9 + 6*10^(6*(n-1)+b[c]) } \\ David A. Corneth, Jul 23 2021

CROSSREFS

Cf. A107693, A346274.

Sequence in context: A015630 A237933 A251347 * A234863 A250695 A250680

Adjacent sequences:  A346273 A346274 A346275 * A346277 A346278 A346279

KEYWORD

nonn,base,easy

AUTHOR

Bernard Schott, Jul 22 2021

STATUS

approved

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 January 16 14:30 EST 2022. Contains 350376 sequences. (Running on oeis4.)