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!)
A242491 Numbers avoiding subtractive notation when written in Roman numerals. 0

%I #19 Mar 05 2024 15:54:03

%S 1,2,3,5,6,7,8,10,11,12,13,15,16,17,18,20,21,22,23,25,26,27,28,30,31,

%T 32,33,35,36,37,38,50,51,52,53,55,56,57,58,60,61,62,63,65,66,67,68,70,

%U 71,72,73,75,76,77,78,80,81,82,83,85,86,87,88,100,101,102,103,105

%N Numbers avoiding subtractive notation when written in Roman numerals.

%C Numbers with only digits 0,1,2,3,5,6,7,8.

%C So this is a subsequence of A039145 with same number of 4 and 9: zero. - _Michel Marcus_, May 17 2014

%e 4 in Roman numerals is IV (5 - 1) and so 4 is not in this sequence.

%o (PARI) isok(n) = my(v = vecsort(digits(n))); ! (vecsearch(v, 4) || vecsearch(v, 9)); \\ _Michel Marcus_, May 19 2014

%o (Python)

%o from itertools import count, islice

%o from sympy.ntheory.factor_ import digits

%o def A242491_gen(): # generator of terms

%o return (int(''.join(str(d) if d<4 else str(d+1) for d in digits(n,8)[1:])) for n in count(1))

%o A242491_list = list(islice(A242491_gen(),40)) # _Chai Wah Wu_, Mar 05 2024

%K nonn,base,easy

%O 1,2

%A _J. Lowell_, May 16 2014

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 March 28 08:02 EDT 2024. Contains 371236 sequences. (Running on oeis4.)