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 A226519 #14 Oct 06 2024 09:15:52 %S A226519 1,1,0,1,0,-1,0,1,2,1,2,1,0,1,0,1,2,3,2,1,0,1,0,1,0,1,2,1,0,-1,-2,-1, %T A226519 0,-1,0,1,2,1,2,1,0,-1,0,1,0,-1,-2,-1,-2,-1,0,1,0,-1,0,1,2,3,2,3,2,3, %U A226519 2,1,0,-1,0,1,0,1,2,3,4,3,4,3,4,5,4,3,4,5,4,3,4,3,4,3,2,1,0 %N A226519 Irregular triangle read by rows: T(n,k) = Sum_{i=0..k} Legendre(i,prime(n)). %C A226519 Strictly speaking, the symbol in the definition is the Legendre-Jacobi-Kronecker symbol, since the Legendre symbol is defined only for odd primes. %D A226519 József Beck, Inevitable randomness in discrete mathematics, University Lecture Series, 49. American Mathematical Society, Providence, RI, 2009. xii+250 pp. ISBN: 978-0-8218-4756-5; MR2543141 (2010m:60026). See page 23. %H A226519 G. C. Greubel, <a href="/A226519/b226519.txt">Rows n = 1..50 of the irregular triangle, flattened</a> %e A226519 Triangle begins: %e A226519 1; %e A226519 1, 0; %e A226519 1, 0, -1, 0; %e A226519 1, 2, 1, 2, 1, 0; %e A226519 1, 0, 1, 2, 3, 2, 1, 0, 1, 0; %e A226519 1, 0, 1, 2, 1, 0, -1, -2, -1, 0, -1, 0; %e A226519 1, 2, 1, 2, 1, 0, -1, 0, 1, 0, -1, -2, -1, -2, -1, 0; %e A226519 ... %p A226519 with(numtheory); %p A226519 T:=(n,k)->add(legendre(i,ithprime(n)),i=1..k); %p A226519 f:=n->[seq(T(n,k),k=1..ithprime(n)-1)]; %p A226519 [seq(f(n),n=1..15)]; %t A226519 Table[P = Prime[n]; Table[JacobiSymbol[k,P], {k,P-1}]//Accumulate, {n,15}]// Flatten (* _G. C. Greubel_, Oct 05 2024 *) %o A226519 (Magma) %o A226519 A226519:= func< n,k | n eq 1 select k else (&+[JacobiSymbol(j, NthPrime(n)): j in [0..k]]) >; %o A226519 [A226519(n,k) : k in [1..NthPrime(n)-1], n in [1..15]]; // _G. C. Greubel_, Oct 05 2024 %o A226519 (SageMath) %o A226519 def A226519(n,k): return k if n==1 else sum(jacobi_symbol(j, nth_prime(n)) for j in range(k+1)) %o A226519 flatten([[A226519(n,k) for k in range(1,nth_prime(n))] for n in range(1,16)]) # _G. C. Greubel_, Oct 05 2024 %Y A226519 A variant of A226518, which is the main entry for this triangle. %Y A226519 Cf. A165582, A226518. %K A226519 sign,tabf %O A226519 1,9 %A A226519 _N. J. A. Sloane_, Jun 19 2013