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 A199408 #20 Aug 04 2018 10:36:03 %S A199408 1,2,2,3,4,3,4,4,6,4,5,6,7,8,5,6,6,6,8,10,6,7,8,9,10,11,12,7,8,8,10,8, %T A199408 12,12,14,8,9,10,9,12,13,12,15,16,9,10,10,12,12,10,14,16,16,18,10,11, %U A199408 12,13,14,15,16,17,18,19,20,11,12,12,12,12,16,12 %N A199408 Triangle T(n,k) = n + k - gcd(n,k) read by rows, 1 <= n, 1 <= k <= n. %C A199408 A diagonal of an n by k rectangle drawn on a square grid passes through T(n,k) squares: the diagonal enters n squares crossing horizontal segments and enters k squares crossing vertical segments. Gcd(n,k) counts the squares entered at a lattice point, which have been over-counted. %D A199408 M. Ollerton, Mathematics Teacher's Handbook, Continuum, 2009, pp. 14-15. %H A199408 Seiichi Manyama, <a href="/A199408/b199408.txt">Rows n = 1..140, flattened</a> %H A199408 Association of Teachers of Mathematics, <a href="https://www.atm.org.uk/Shop/Points-of-Departure-1---PDF/dnl003">Points of Departure 1</a>, Derby, 1972. %F A199408 T(d*a,d*b) = d*T(a,b). %e A199408 T(6,4) = 6 + 4 - 2 = 8. %e A199408 Triangular array begins %e A199408 1 %e A199408 2 2 %e A199408 3 4 3 %e A199408 4 4 6 4 %e A199408 5 6 7 8 5 %e A199408 6 6 6 8 10 6 %e A199408 7 8 9 10 11 12 7 %e A199408 8 8 10 8 12 12 14 8 %o A199408 (PARI) T(n,k) = n + k - gcd(n,k); \\ _Michel Marcus_, Aug 04 2018 %Y A199408 Cf. A049627, A074712. Third column A061800. %K A199408 nonn,tabl,easy %O A199408 1,2 %A A199408 _Brian Hopkins_, Nov 05 2011