A337449 The numbers k for which Lucas(k) are Niven numbers.
0, 1, 2, 3, 4, 6, 12, 18, 56, 81, 130, 225, 396, 637, 854, 2034, 4059, 4095, 5985, 7650, 21105, 31059, 41998, 46860, 83106, 114129, 120555, 150705, 201285, 287937, 338265, 359757, 475839, 512194, 583825, 606594, 627102, 717025, 877305, 922095, 991590, 1076355
Offset: 1
Examples
Lucas(0) = 2 = A005349(2), so 0 is a term. Lucas(1) = 1 = A005349(1), so 1 is a term. Lucas(6) = 12 = A005349(11), so 6 is a term. Lucas(12) = 322 = A005349(90), so 12 is a term. Lucas(18) = 5778 = A005349(1013), so 18 is a term.
Links
- Chai Wah Wu, Table of n, a(n) for n = 1..57
Programs
-
Magma
niven:=func
; [k:k in [0..70000]|niven(Lucas(k))]; -
Mathematica
nivenQ[n_] := Divisible[n, Plus @@ IntegerDigits[n]]; Select[Range[6000], nivenQ[LucasL[#]] &] (* Amiram Eldar, Sep 15 2020 *)
-
PARI
isok(k) = my(l=real((2+quadgen(5))*quadgen(5)^k)); (l % sumdigits(l)) == 0; \\ Michel Marcus, Sep 15 2020
-
Python
A337449_list, k, p, q = [], 0, 2, 1 while k < 10**6: if p % sum(int(d) for d in str(p)) == 0: A337449_list.append(k) k += 1 p, q = q, p+q # Chai Wah Wu, Sep 17 2020
Comments