login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A337086 Number of integer-sided triangles with perimeter n where the harmonic mean of the side lengths is an integer. 2
0, 0, 1, 0, 0, 1, 0, 0, 2, 1, 0, 1, 1, 0, 1, 0, 0, 2, 0, 1, 1, 0, 0, 1, 0, 1, 2, 1, 0, 2, 1, 0, 1, 0, 1, 3, 1, 0, 2, 1, 0, 2, 0, 0, 4, 1, 1, 2, 0, 1, 1, 2, 1, 2, 1, 2, 1, 0, 0, 2, 1, 2, 3, 1, 1, 1, 0, 0, 1, 2, 1, 3, 1, 1, 1, 0, 1, 2, 0, 1, 2, 0, 0, 3, 3, 1, 1, 0, 2, 6, 3, 1, 2, 1, 0, 2 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,9
LINKS
Wikipedia, Integer Triangle
FORMULA
a(n) = Sum_{k=1..floor(n/3)} Sum_{i=k..floor((n-k)/2)} sign(floor((i+k)/(n-i-k+1))) * chi(3*i*k*(n-i-k)/(i*k+k*(n-i-k)+i*(n-i-k))), where chi(n) = 1 - ceiling(n) + floor(n).
a(n) = A005044(n) - A337087(n).
EXAMPLE
a(6) = 1; There is one integer-sided triangle with perimeter 6, [2,2,2]. The harmonic mean of its side lengths is 3*2*2*2/(2*2+2*2+2*2) = 2 (an integer).
a(10) = 1; There are 2 integer-sided triangles with perimeter 10, [2,4,4] and [3,3,4]. For the harmonic mean of the [2,4,4] triangle, we get 3*2*4*4/(2*4+2*4+4*4) = 96/32 = 3 (an integer), but the harmonic mean for the [3,3,4] triangle is 3*3*3*4/(3*3+3*4+3*4) = 108/33 (not an integer). Thus, a(10) = 1.
MATHEMATICA
Table[Sum[Sum[(1 - Ceiling[3*i*k*(n - i - k)/(i*k + k*(n - i - k) + i*(n - i - k))] + Floor[3*i*k*(n - i - k)/(i*k + k*(n - i - k) + i*(n - i - k))]) Sign[Floor[(i + k)/(n - i - k + 1)]], {i, k, Floor[(n - k)/2]}], {k, Floor[n/3]}], {n, 100}]
CROSSREFS
Sequence in context: A364048 A353657 A259896 * A113313 A342708 A074871
KEYWORD
nonn,easy
AUTHOR
Wesley Ivan Hurt, Aug 14 2020
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 09:42 EDT 2024. Contains 371935 sequences. (Running on oeis4.)