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!)
A038186 Numbers divisible by the sum and product of their digits. 15

%I #47 Feb 16 2024 10:10:13

%S 1,2,3,4,5,6,7,8,9,12,24,36,111,112,132,135,144,216,224,312,315,432,

%T 612,624,735,1116,1212,1296,1332,1344,1416,2112,2232,2916,3132,3168,

%U 3276,3312,4112,4224,6624,6912,8112,9612,11112,11115,11133,11172,11232

%N Numbers divisible by the sum and product of their digits.

%C The property "numbers divisible by the sum and product of their digits" leads to the Diophantine equation t*x1*x2*...*xr=s*(x1+x2+...+xr), where t and s are divisors of n; xi is from [1...9]. This corresponds to some arithmetic problems in geometry, see Sándor, 2002. - _Ctibor O. Zizka_, Mar 04 2008

%H David A. Corneth, <a href="/A038186/b038186.txt">Table of n, a(n) for n = 1..10352</a> (first 1000 terms from T. D. Noe)

%H József Sándor, <a href="http://www.gallup.unm.edu/~smarandache/JozsefSandor2.pdf">Geometric Theorems, Diophantine Equations and Arithmetic Functions</a>, American Research Press, Rehoboth, 2002.

%F A188641(a(n)) * A188642(a(n)) = 1. - _Reinhard Zumkeller_, Apr 07 2011

%t dspQ[n_]:=Module[{idn=IntegerDigits[n],t},t=Times@@idn;t!=0 && Divisible[n,Total[idn]] && Divisible[n,t]]; Select[Range[11500],dspQ] (* _Harvey P. Dale_, Jul 11 2011 *)

%o (Haskell)

%o import Data.List (elemIndices)

%o a038186 n = a038186_list !! (n-1)

%o a038186_list = map succ $ elemIndices 1

%o $ zipWith (*) (map a188641 [1..]) (map a188642 [1..])

%o -- _Reinhard Zumkeller_, Apr 07 2011

%o (PARI) for(n=1,10^4,d=digits(n);s=sumdigits(n);p=prod(i=1,#d,d[i]);if(p&&!(n%s+n%p),print1(n,", "))) \\ _Derek Orr_, Apr 29 2015

%o (Python)

%o from math import prod

%o def sd(n): return sum(map(int, str(n)))

%o def pd(n): return prod(map(int, str(n)))

%o def ok(n): return n%sd(n) == 0 and pd(n) and n%pd(n) == 0

%o def aupto(limit): return [m for m in range(1, limit+1) if ok(m)]

%o print(aupto(11233)) # _Michael S. Branicky_, Jan 28 2021

%Y Intersection of A005349 and A007602. - _Reinhard Zumkeller_, Apr 07 2011

%Y Cf. A188641, A188642.

%K nonn,base,nice,look

%O 1,2

%A _Felice Russo_

%E More terms from _Patrick De Geest_, Jun 15 1999

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 18:16 EDT 2024. Contains 371916 sequences. (Running on oeis4.)