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!)
A031944 Numbers in which digits 0,1,2 all occur in base 3. 6

%I #20 Nov 15 2021 08:55:10

%S 11,15,19,21,29,32,33,34,35,38,42,45,46,47,48,51,55,57,58,59,61,63,64,

%T 65,66,69,73,75,83,86,87,88,89,92,95,96,97,98,99,100,101,102,103,104,

%U 105,106,107,110,113,114,115,116,119,123,126,127,128,129,132,135

%N Numbers in which digits 0,1,2 all occur in base 3.

%C A043530(a(n)) = 3; complement of A154314. - _Reinhard Zumkeller_, Jan 07 2009

%C A212193(a(n)) = 3. - _Reinhard Zumkeller_, May 04 2012

%H Reinhard Zumkeller, <a href="/A031944/b031944.txt">Table of n, a(n) for n = 1..10000</a>

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/Ternary.html">Ternary</a>

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/PandigitalNumber.html">Pandigital Number</a>

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Ternary_numeral_system">Ternary numeral system</a>

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Pandigital_number">Pandigital number</a>

%t Select[Range[200],Min[DigitCount[#,3]]>0&] (* _Harvey P. Dale_, Nov 21 2015 *)

%o (Haskell)

%o import Data.List (elemIndices)

%o a031944 n = a031944_list !! (n-1)

%o a031944_list = elemIndices 3 a212193_list

%o -- _Reinhard Zumkeller_, May 04 2012

%o (Python)

%o from sympy.ntheory import count_digits

%o def ok(n): c = count_digits(n, 3); return all(c[d] > 0 for d in [0, 1, 2])

%o print([k for k in range(136) if ok(k)]) # _Michael S. Branicky_, Nov 15 2021

%Y Cf. A043530, A049354, A154314, A212193.

%K nonn,base

%O 1,1

%A _Clark Kimberling_

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 14 07:57 EDT 2024. Contains 372530 sequences. (Running on oeis4.)