title: Trigonometric Equation only works with specific input ( 5 ) doesn't work with other inputs
body: <p>I try to write code for that calculation angles from lengths of triangle. formula is
  cos(a)=b^2+c^2-a^2/2bc. <a href="https://i.stack.imgur.com/dxoqd.png" rel="nofollow noreferrer">(Triangle is here)</a></p>
  <pre><code>angle1 = acosf((powf(length2,2) + powf(length3,2) - powf(length1,2)) / 2 * length2 * length3)* 180 / 3.14153;
  angle2 = acosf((powf(length1,2) + powf(length3,2) - powf(length2,2)) / 2 * length1 * length3)* 180 / 3.14153;
  angle3 = 180 - (angle2 + angle1);
  </code></pre>
  <p>Everything is float. When entered 5-4-3 inputs outcome this.</p>
  <pre><code>angle one is 90.0018
  angle two is nan
  angle three is nan
  </code></pre>
  <p>changing order doesn't matter, only gives output for 5.</p>