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”).
%I #15 Nov 22 2024 15:58:53
%S 0,1,7,1782,9211,13213,212722,252333,371911,766459,3829753,5743366,
%T 6534297,6566671,13336785,15347493,15973168,17831596,17965381,
%U 19567813,27335662,33154947,37494513,47539261,51817693,78335613,93657421
%N Heptagonal numbers for which the product of the digits is also a heptagonal number.
%H Harvey P. Dale, <a href="/A117661/b117661.txt">Table of n, a(n) for n = 1..130</a>
%e 766459 is in the sequence because it is a heptagonal number and the product of its digits (45360) is also a heptagonal number
%p a:=proc(n) local hn,hnn: hn:=convert(n*(5*n-3)/2,base,10): hnn:=product(hn[j],j=1..nops(hn)): if type((3+sqrt(9+40*hnn))/10,integer)=true then n*(5*n-3)/2 else fi end: seq(a(n),n=0..10000); # _Emeric Deutsch_, Apr 16 2006
%t Join[{0},Select[LinearRecurrence[{3,-3,1},{0,1,7},7000],IntegerQ[(3+ Sqrt[ 40*Times@@IntegerDigits[#]+9])/10]&]] (* _Harvey P. Dale_, Jun 17 2015 *)
%t Module[{nn=20000,heps},heps=PolygonalNumber[7,Range[nn]];Join[{0},Select[heps,MemberQ[heps,Times@@IntegerDigits[#]]&]]] (* _Harvey P. Dale_, Nov 22 2024 *)
%Y Cf. A000566.
%K nonn,base
%O 1,3
%A Luc Stevens (lms022(AT)yahoo.com), Apr 11 2006
%E More terms from _Emeric Deutsch_, Apr 16 2006