The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A061827 Number of partitions of n into parts which are the digits of n. 9

%I #36 Oct 27 2023 19:56:42

%S 1,1,1,1,1,1,1,1,1,1,1,7,5,4,4,3,3,3,3,1,11,1,4,7,3,5,2,4,2,1,11,6,1,

%T 3,3,7,2,2,5,1,11,11,4,1,3,4,2,7,2,1,11,6,4,3,1,2,2,2,2,1,11,11,11,6,

%U 3,1,2,3,4,1,11,6,4,3,3,2,1,2,2,1,11,11,4,11,3,4,2,1,2,1,11,6,11,3,3,6,2,2

%N Number of partitions of n into parts which are the digits of n.

%C a(A125289(n)) = 1, a(A125290(n)) > 1.

%H Alois P. Heinz, <a href="/A061827/b061827.txt">Table of n, a(n) for n = 1..15000</a> (first 1250 terms from Reinhard Zumkeller)

%e For n = 11, 1+1+1+1+1+1+1+1+1+1+1. so a(11) = 1. For n = 12, 2+2+2+2+2+2 = 2+2+1+1+1+1+1+1+1+1 = ...etc

%e a(20) = 1: the only partitions permitted use the digits 0 and 2, so there is just 1, 20 = 2+2+2... ten times.

%t Length[IntegerPartitions[#,All,DeleteDuplicates@DeleteCases[IntegerDigits[#],0]]]&/@Range[200] (* _Sander G. Huisman_, Nov 14 2022 *)

%o (Haskell)

%o import Data.List (sort, nub)

%o import Data.Char (digitToInt)

%o a061827 n =

%o p n (map digitToInt $ nub $ sort $ filter (/= '0') $ show n) where

%o p _ [] = 0

%o p 0 _ = 1

%o p m ds'@(d:ds)

%o | m < d = 0

%o | otherwise = p (m - d) ds' + p m ds

%o -- _Reinhard Zumkeller_, Aug 01 2011

%Y Cf. A061828, A109950, A119999, A125291, A136460, A193513.

%K nonn,base,easy,look

%O 1,12

%A _Amarnath Murthy_, May 28 2001

%E More terms from _David Wasserman_, Jul 29 2002

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 May 13 00:07 EDT 2024. Contains 372497 sequences. (Running on oeis4.)