OFFSET
1,2
COMMENTS
A 10-automatic sequence. - Charles R Greathouse IV, Jun 13 2017
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
FORMULA
a(n) mod A000030(a(n)) = 0. - Reinhard Zumkeller, Sep 20 2003
MATHEMATICA
Select[Range[150], Divisible[#, IntegerDigits[#][[1]]]&] (* Harvey P. Dale, Jul 11 2017 *)
PROG
(Haskell)
import Data.Char (digitToInt)
a034837 n = a034837_list !! (n-1)
a034837_list = filter (\i -> i `mod` (a000030 i) == 0) [1..]
-- Reinhard Zumkeller, Jun 19 2011
(PARI) for(n=1, 1000, n%(Vecsmall(Str(n))[1]-48) || print1(n", ")) \\ M. F. Hasler, Jun 19 2011
(PARI) a(n)=for(k=1, 1e9, k%(Vecsmall(Str(k))[1]-48) || n-- || return(k)) \\ M. F. Hasler, Jun 19 2011
(Python)
def ok(n): return n and n%int(str(n)[0]) == 0
print([k for k in range(123) if ok(k)]) # Michael S. Branicky, Jan 15 2023
(Python)
from itertools import count, islice
def agen(): # generator of terms
yield from (i for e in count(0) for f in range(1, 10) for i in range(f*10**e, (f+1)*10**e, f))
print(list(islice(agen(), 64))) # Michael S. Branicky, Jan 15 2023
CROSSREFS
KEYWORD
AUTHOR
EXTENSIONS
Definition clarified by Harvey P. Dale, May 01 2023
STATUS
approved