login
A070201
Number of integer triangles with perimeter n having integral inradius.
11
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 2, 0, 0, 0, 1, 0, 2, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 3, 0, 0, 0, 2, 0, 1, 0, 1, 0, 2, 0, 2, 0, 0, 0, 1, 0, 1, 0, 2, 0, 0, 0, 8, 0, 0, 0, 1, 0, 3
OFFSET
1,36
COMMENTS
a(n) = #{k | A070083(k) = n and A070200(k) = exact inradius};
a(n) = A070203(n) + A070204(n);
a(n) = A070205(n) + A070206(n) + A024155(n);
a(odd) = 0.
LINKS
Mohammad K. Azarian, Solution to Problem S125: Circumradius and Inradius, Math Horizons, Vol. 16, Issue 2, November 2008, p. 32.
Eric Weisstein's World of Mathematics, Incircle.
Eric Weisstein's World of Mathematics, Heron's Formula.
Reinhard Zumkeller, Integer-sided triangles
EXAMPLE
a(36)=2, as there are two integer triangles with integer inradius having perimeter=32:
First: [A070080(368), A070081(368), A070082(368)] = [9,10,17], for s = A070083(368)/2 = (9+10+17)/2 = 18: inradius = sqrt((s-9)*(s-10)*(s-17)/s) = sqrt(9*8*1/18) = sqrt(4) = 2; therefore A070200(368) = 2.
2nd: [A070080(370), A070081(370), A070082(370)] = [9,12,15], for s = A070083(370)/2 = (9+12+15)/2 = 18: inradius = sqrt((s-9)*(s-12)*(s-15)/s) = sqrt(9*6*3/18) = sqrt(9) = 3; therefore A070200(370) = 3.
PROG
(Ruby)
def A(n)
cnt = 0
(1..n / 3).each{|a|
(a..(n - a) / 2).each{|b|
c = n - a - b
if a + b > c
s = n / 2r
t = (s - a) * (s - b) * (s - c) / s
if t.denominator == 1
t = t.to_i
cnt += 1 if Math.sqrt(t).to_i ** 2 == t
end
end
}
}
cnt
end
def A070201(n)
(1..n).map{|i| A(i)}
end
p A070201(100) # Seiichi Manyama, Oct 06 2017
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, May 05 2002
STATUS
approved