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 A316707 #9 Jul 12 2018 00:53:27 %S A316707 0,1,1,1,1,5,10,8,2,4,5,4,10,8,2,5,2,4,10,8,5,8,2,4,10,25,32,34,20,18, %T A316707 50,61,61,41,41,40,45,53,37,29,10,13,17,9,5,20,29,25,13,17,25,18,32, %U A316707 34,20,20,17,29,25,13,50,41,61,61,41,40,29,45,53,37,10 %N A316707 For any n >= 0 with base-5 expansion Sum_{k=0..w} d_k * 5^k, let f(n) = Sum_{k=0..w} [d_k > 0] * (2 + i)^k * i^(d_k - 1) (where [] is an Iverson bracket and i denotes the imaginary unit); a(n) equals the square of the modulus of f(n). %C A316707 See A316657 for the real part of f and additional comments. %H A316707 Rémy Sigrist, <a href="/A316707/b316707.txt">Table of n, a(n) for n = 0..10000</a> %F A316707 a(n) = A316657(n)^2 + A316658(n)^2. %F A316707 a(5 * n) = 5 * a(n) for any n >= 0. %F A316707 a(5^k) = 5^k for any k >= 0. %o A316707 (PARI) a(n) = my (d=Vecrev(digits(n, 5)), z=sum(i=1, #d, if (d[i], (2+I)^(i-1) * I^(d[i]-1), 0))); real(z)^2 + imag(z)^2 %Y A316707 Cf. A316657, A316658. %K A316707 nonn,base %O A316707 0,6 %A A316707 _Rémy Sigrist_, Jul 11 2018