login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Lucky numbers for which both the sum of the digits and the product of the digits is also a lucky number.
1

%I #11 Nov 18 2019 03:21:31

%S 1,3,7,9,111,133,135,171,331,357,535,537,553,717,735,11113,11137,

%T 11173,11371,11373,11535,11731,11911,13113,13117,13179,13317,13335,

%U 13371,13515,13533,13551,15333,15511,15531,17313,17391,17737,17913,17997

%N Lucky numbers for which both the sum of the digits and the product of the digits is also a lucky number.

%H Amiram Eldar, <a href="/A118559/b118559.txt">Table of n, a(n) for n = 1..10000</a>

%e 133 is in the sequence because: (1) it is a lucky number, (2) the sum of its digits 1+3+3=7 is a lucky number, (3) the product of its digits 1*3*3=9 is a lucky number.

%t lst = Range[1, 19172, 2]; i = 2; While[ i <= (len = Length@lst) && (k = lst[[i]]) <= len, lst = Drop[lst, {k, len, k}]; i++ ]; Select[lst, MemberQ[lst, Plus @@ IntegerDigits@# ] && MemberQ[lst, Times @@ IntegerDigits@# ] &] (* _Robert G. Wilson v_ *)

%Y Cf. A000959, A007953, A007954.

%K base,nonn

%O 1,2

%A Luc Stevens (lms022(AT)yahoo.com), May 07 2006

%E Corrected and extended by Adam Panagos (adam.panagos(AT)gmail.com) and _Robert G. Wilson v_, May 10 2006