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 A107348 #27 Jan 14 2025 09:07:21 %S A107348 0,1,6,1,11,20,1,18,35,62,1,27,52,93,140,1,38,75,136,207,306,1,51,100, %T A107348 181,274,405,536,1,66,131,238,361,534,709,938,1,83,164,299,454,673, %U A107348 894,1183,1492,1,102,203,370,563,836,1111,1470,1855,2306 %N A107348 Triangle read by rows: T(m,n) = number of different lines in a rectangular m X n array of points with integer coordinates (x,y): 0 <= x <= m, 0 <= y <= n. %C A107348 We may assume n <= m since T(m,n)=T(n,m). %H A107348 M. A. Alekseyev, M. Basova, and N. Yu. Zolotykh, <a href="http://dx.doi.org/10.1137/140978090">On the minimal teaching sets of two-dimensional threshold functions</a>, SIAM J. Disc. Math. 29(1), 2015, pp. 157-165. %H A107348 Les Reid, <a href="https://problemcorner.missouristate.edu/POW07_04.html">Problem #7: How Many Lines Does the Lattice of Points Generate?</a>, Problems from the 04-05 academic year, Challenge Archive, Missouri State University's Problem Corner. %F A107348 T(0, 0) = 0; T(m, 0) = 1, m >= 1. %F A107348 When both m,n -> +oo, T(m,n) / 2Cmn -> 9/(2*pi^2). - _Dan Dima_, Mar 18 2006 %F A107348 T(n,m) = A295707(n,m). - _R. J. Mathar_, Dec 17 2017 %e A107348 Triangle begins %e A107348 0, %e A107348 1, 6, %e A107348 1, 11, 20, %e A107348 1, 18, 35, 62, %e A107348 1, 27, 52, 93, 140, %e A107348 1, 38, 75, 136, 207, 306, %e A107348 1, 51, 100, 181, 274, 405, 536, %e A107348 1, 66, 131, 238, 361, 534, 709, 938, %e A107348 1, 83, 164, 299, 454, 673, 894, 1183, 1492, %e A107348 1, 102, 203, 370, 563, 836, 1111, 1470, 1855, 2306, %e A107348 ... %p A107348 VR := proc(m,n,q) local a,i,j; a:=0; %p A107348 for i from -m+1 to m-1 do for j from -n+1 to n-1 do %p A107348 if gcd(i,j)=q then a:=a+(m-abs(i))*(n-abs(j)); fi; od: od: a; end; %p A107348 LL:=(m,n)->(VR(m,n,1)-VR(m,n,2))/2; %p A107348 for m from 1 to 12 do lprint([seq(LL(m,n),n=1..m)]); od: # _N. J. A. Sloane_, Feb 10 2020 %t A107348 VR[m_, n_, q_] := Sum[If[GCD[i, j] == q, (m - Abs[i])(n - Abs[j]), 0], {i, -m + 1, m - 1}, {j, -n + 1, n - 1}]; %t A107348 LL[m_, n_] := (1/2)(VR[m, n, 1] - VR[m, n, 2]); %t A107348 Table[LL[m, n], {m, 1, 10}, {n, 1, m}] // Flatten (* _Jean-François Alcover_, Jun 04 2023, after _N. J. A. Sloane_ *) %Y A107348 Cf. A295707 (symmetric array), A018808 (diagonal). A160842 - A160850 (columns). %K A107348 nonn,tabl %O A107348 0,3 %A A107348 _Dan Dima_, May 23 2005 %E A107348 T(3,3) corrected and sequence extended by _R. J. Mathar_, Dec 17 2017