Results 1 to 3 of 3

Math Help - Right angle triangle math

  1. #1
    Newbie
    Joined
    Aug 2008
    Posts
    5

    Right angle triangle math

    Hi, I'm writing a physics engine in flash, i'm attempting to avoid trigonometry as much as possible to avoid rounding issues. I've reached a point where i basically need to draw right triangles where the ratio between the two shorter sides are constant and the hypotenuse can change. So in other words i need to be able to work out the lengths of 'a' and 'b' (in the basic a^2+b^2=c^2) if i know 'c' and a/b.

    In my futile attemps i've come up with this a*a = c*c/(1+1/r*r) (r being a/b), now that will only work if a is equal to b which is a little useless.

    if b = a/r then you could write it as a^2+(a/r)^2 = c^2, now what i need to do to get this to work is get 'r' over to the other side of the equation so we have just 'a' left on one side and 'c' and 'r' on the other. It has to be in this format because 'c' and 'r' are known and 'a' isn't.

    Im not sure if this should be in the algebra forum or here but i was hoping someone might know a solution

    thanks for you help !
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Super Member

    Joined
    May 2006
    From
    Lexington, MA (USA)
    Posts
    11,663
    Thanks
    603
    Hello, Geo877!

    Hi, I'm writing a physics engine in flash, i'm attempting to avoid trigonometry
    as much as possible to avoid rounding issues. .
    . . . But there will be rounding!
    I've reached a point where i basically need to draw right triangles where the ratio
    between the two shorter sides is a constant and the hypotenuse c can change.

    I need to be able to work out a and b if i know c and \frac{a}{b}
    Let the ratio be r.

    So we have: . \frac{a}{b} \:=\:r \quad\Rightarrow\quad a \:=\:br


    Substitute into a^2+b^2\:=\:c^2

    . . (br)^2 + b^2 \:=\:c^2 \quad\Rightarrow\quad b^2r^2+ b^2 \:=\:c^2 \quad\Rightarrow\quad b^2(r^2+1) \:=\:c^2 \quad\Rightarrow\quad b^2 \:=\:\frac{c^2}{r^2+1}

    Then: . \boxed{b \;=\;\frac{c}{\sqrt{r^2+1}} }

    And: . a \:=\:br \:=\:\frac{c}{\sqrt{r^2+1}}\cdot r \quad\Rightarrow\quad \boxed{a \:=\:\frac{cr}{\sqrt{r^2+1}}}

    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    Aug 2008
    Posts
    5

    thank you so much that was exactly what I was looking for

    the title says it all
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Calculating an angle of a none right angle triangle
    Posted in the Trigonometry Forum
    Replies: 14
    Last Post: August 19th 2011, 01:42 PM
  2. Replies: 2
    Last Post: May 11th 2011, 02:28 PM
  3. Replies: 1
    Last Post: April 4th 2011, 11:36 AM
  4. angle of the triangle
    Posted in the Geometry Forum
    Replies: 8
    Last Post: April 28th 2009, 10:31 PM
  5. Replies: 27
    Last Post: April 27th 2008, 10:36 AM

Search Tags


/mathhelpforum @mathhelpforum