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 A378820 #5 Jan 07 2025 10:21:25 %S A378820 1,3,3,6,3,11,3,10,6,10,3,26,3,10,11,15,3,23,3,23,10,10,3,46,6,10,10, %T A378820 22,3,45,3,21,10,10,11,57,3,10,10,43,3,41,3,21,24,10,3,70,6,21,10,21, %U A378820 3,39,10,42,10,10,3,114,3,10,23,28,10,39,3,21,10,42,3,108 %N A378820 a(n) is the number of distinct nondegenerate triangles whose sides are divisors of n. %C A378820 A divisor can be used for several sides. %C A378820 A nondegenerate triangle is a triangle whose sides (u, v, w) are such that u + v > w, v + w > u and u + w > v. %H A378820 Felix Huber, <a href="/A378820/b378820.txt">Table of n, a(n) for n = 1..10000</a> %H A378820 Wikipedia, <a href="https://en.wikipedia.org/wiki/Triangle_inequality">Triangle Inequality</a> %F A378820 a(p) = 3 for prime p. %e A378820 a(4) = 6 because there are the 6 distinct nondegenerate triangles (1, 1, 1), (1, 2, 2), (1, 4, 4), (2, 2, 2), (2, 4, 4), (4, 4, 4) whose sides are divisors of 4. The triples (1, 1, 2), (1, 1, 4), (1, 2, 4), (2, 2, 4) are not sides of (nondegenerate) triangles. %p A378820 A378820:=proc(n) %p A378820 local a,i,j,k,L; %p A378820 L:=NumberTheory:-Divisors(n); %p A378820 a:=0; %p A378820 for i to nops(L) do %p A378820 for j from i to nops(L) do %p A378820 for k from j to nops(L) while L[k]<L[i]+L[j] do %p A378820 a:=a+1; %p A378820 od %p A378820 od %p A378820 od; %p A378820 return a %p A378820 end proc; %p A378820 seq(A378820(n),n=1..72); %Y A378820 Cf. A000005, A316841, A316842, A378819. %K A378820 nonn %O A378820 1,2 %A A378820 _Felix Huber_, Dec 27 2024