login
Positive numbers from the children's game "Buzz" or "Sevens": positive integers which are divisible by seven, or which contain a seven as a digit.
13

%I #35 Sep 09 2024 06:56:21

%S 7,14,17,21,27,28,35,37,42,47,49,56,57,63,67,70,71,72,73,74,75,76,77,

%T 78,79,84,87,91,97,98,105,107,112,117,119,126,127,133,137,140,147,154,

%U 157,161,167,168,170,171,172,173,174,175,176,177,178,179,182,187,189,196

%N Positive numbers from the children's game "Buzz" or "Sevens": positive integers which are divisible by seven, or which contain a seven as a digit.

%C Almost all integers are in this sequence: It has asymptotic density 1 since the percentage of n-digit numbers with no digit 7 tends to 0 as n -> oo. - _M. F. Hasler_, Oct 12 2020

%C Does not contain 114.

%H David A. Corneth, <a href="/A092433/b092433.txt">Table of n, a(n) for n = 1..10000</a>

%H Darren Gerson, <a href="http://www.gameskidsplay.net/games/xtra_games.htm#Buzz">Buzz</a>.

%H LoGirl, <a href="http://www.dailymotion.com/video/k5dvmUOmXCndCMiDzA0">The game 887</a>, Japanese TV program for junior high and primary school student, Jul 11 2016

%H Partygamecentral.com, <a href="http://www.partygamecentral.com/games.php?gnm=156&amp;flagtype=search&amp;searchquery=Buzz&amp;offset=0">Buzz</a> [broken link]

%H TeachingTips, <a href="https://web.archive.org/web/20050204081131/http://www.teachingtips.com/articles/Hgames1.html">Academic Games</a>, Buzz.

%F Integers n for which the coefficient of x^n is nonzero in x^7 / (1 - x^7) + Sum_{k>=0} (x^(7*10^k)*(1 - x^(10^k)) / ((1 - x)*(1 - x^(10^(k+1)))).

%e 7 is the first term, both because it is a multiple of 7 and because it contains a 7. 14 is next, being a multiple of 7. 17 is the third term: it contains a 7.

%p isA092433 := proc(n)

%p if modp(n,7) = 0 then

%p true;

%p else

%p convert(convert(n,base,10),set) ;

%p if 7 in % then

%p true;

%p else

%p false;

%p end if;

%p end if;

%p end proc:

%p for n from 1 to 200 do

%p if isA092433(n) then

%p printf("%d,",n);

%p end if;

%p end do: # _R. J. Mathar_, Jul 19 2016

%t Select[Range[300], Mod[ #, 7] == 0 || MemberQ[IntegerDigits[ # ], 7] &]

%o (PARI) is(n) = n % 7 == 0 || setsearch(Set(digits(n)),7) \\ _David A. Corneth_, Oct 01 2019, simplified by _M. F. Hasler_, Oct 12 2020

%Y Cf. A008589 (divisible by 7), A011537 (containing digit 7).

%Y Cf. A092451-A092457.

%Y Complement is A376047.

%K base,easy,nonn

%O 1,1

%A Jim Ferry (jferry(AT)uiuc.edu), Mar 23 2004