This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A245342 #19 Jul 31 2025 03:48:57 %S A245342 0,1,2,3,4,5,6,2,3,4,5,6,7,8,4,5,6,7,8,9,10,6,7,8,9,10,11,12,3,4,5,6, %T A245342 7,8,9,5,6,7,8,9,10,11,7,8,9,10,11,12,13,4,5,6,7,8,9,10,6,7,8,9,10,11, %U A245342 12,8,9,10,11,12,13,14,10,11,12,13,14,15,16,7 %N A245342 Sum of digits of n written in fractional base 7/2. %C A245342 The base 7/2 expansion is unique and thus the sum of digits function is well-defined. %H A245342 Amiram Eldar, <a href="/A245342/b245342.txt">Table of n, a(n) for n = 0..10000</a> %H A245342 <a href="/index/Ba#base_fractional">Index entries for sequences related to fractional bases</a>. %F A245342 a(n) = A007953(A024639(n)). %e A245342 In base 7/2 the number 14 is represented by 40 and so a(14) = 4 + 0 = 4. %t A245342 a[n_] := a[n] = If[n == 0, 0, a[2 * Floor[n/7]] + Mod[n, 7]]; Array[a, 100, 0] (* _Amiram Eldar_, Jul 31 2025 *) %o A245342 (Sage) # uses [basepqsum from A245355] %o A245342 [basepqsum(7,2,w) for w in [0..200]] %o A245342 (PARI) a(n) = if(n == 0, 0, a(n\7 * 2) + n % 7); \\ _Amiram Eldar_, Jul 31 2025 %Y A245342 Cf. A007953, A000120, A024639, A053828, A244040. %K A245342 nonn,base,easy %O A245342 0,3 %A A245342 _Hailey R. Olafson_, Jul 18 2014