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 A119957 #15 Jun 27 2021 12:35:33 %S A119957 0,0,3,0,10,6,7,0,27,20,55,12,78,14,15,0,68,54,171,40,42,110,92,24, %T A119957 250,156,243,28,406,30,31,0,165,136,175,108,666,342,156,80,410,84,301, %U A119957 220,225,184,423,48,490,500,102,312,1378,486,440,56,513,812,1711,60,1830,62 %N A119957 a(n) is the sum of p consecutive residues of 2^x modulo n, starting with a sufficiently large x and where p = period of binary representation of 1/n. %C A119957 Notice that a(n) is divisible by n. %C A119957 a(n)=0 for any n of the form 2^i. %F A119957 a(n) = Sum_{i=x..x+P-1} (2^i mod n) having: P=Period of binary representation of 1/n; x large enough for the period to start. %e A119957 a(1)=0 because 2^i mod 1 = {0,0,0,0,0,0,0,0,0...} and p=1; %e A119957 a(2)=0 because 2^i mod 2 = {1,0,0,0,0,0,0,0,0...}, p=1, x>1; %e A119957 a(14)=14 because 2^i mod 14 = {1,2,4,8,2,4,8,2,4,8,...}, p=3, x>1 ---> a=2+4+8=14; %e A119957 a(35)=175 because 2^i mod 35 = {1,2,4,8,16,32,29,23,11,22,9,18,1,2,4,...}, p=12, x>0 ---> a = 1+2+4+8+16+32+29+23+11+22+9+18 = 175. %Y A119957 Cf. A007733. %K A119957 base,easy,nonn %O A119957 1,3 %A A119957 _Néstor Romeral Andrés_, Aug 02 2006