A352508 Catalan-Niven numbers: numbers that are divisible by the sum of the digits in their representation in terms of the Catalan numbers (A014418).
1, 2, 4, 5, 6, 9, 10, 12, 14, 16, 18, 21, 24, 28, 30, 32, 33, 40, 42, 44, 45, 48, 55, 56, 57, 60, 65, 72, 78, 80, 84, 88, 95, 100, 105, 112, 126, 128, 130, 132, 134, 135, 138, 140, 144, 145, 146, 147, 152, 155, 156, 168, 170, 174, 180, 184, 185, 195, 210, 216
Offset: 1
Examples
4 is a term since its Catalan representation, A014418(4) = 20, has the sum of digits A014420(4) = 2 + 0 = 2 and 4 is divisible by 2. 9 is a term since its Catalan representation, A014418(9) = 120, has the sum of digits A014420(9) = 1 + 2 + 0 = 3 and 9 is divisible by 3.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Crossrefs
Programs
-
Mathematica
c[n_] := c[n] = CatalanNumber[n]; q[n_] := Module[{s = {}, m = n, i}, While[m > 0, i = 1; While[c[i] <= m, i++]; i--; m -= c[i]; AppendTo[s, i]]; Divisible[n, Plus @@ IntegerDigits[Total[4^(s - 1)], 4]]]; Select[Range[216], q]
Comments