A Flash Developer Resource Site

Results 1 to 13 of 13

Thread: Tricky trigonometry question

Hybrid View

  1. #1
    Senior Member rachil0's Avatar
    Join Date
    Jul 2007
    Location
    Columbus, OH.
    Posts
    465
    Heh, a pack of math nerds on the prowl Took 'er down like a limpy gazelle.

  2. #2
    Member
    Join Date
    Mar 2008
    Posts
    82
    Lmao, you guys are freaks!
    Thankyou!! I've been struggling with this for days.

    ----------------------------------------------------------------------1
    5-------------3-------------2-------------1-------------0-------------0
    -------0-------------0-------------0-------------0-------------0------0
    ----------------------------------------------------------------------0
    3-------------2-------------0-------------0---------------------------2
    --------------------------------------------------------3-------------3

  3. #3
    Member
    Join Date
    Mar 2008
    Posts
    82
    Okay fun's not over yet though. I was just considering if this can be done by using the rule of sines too? Here's what I mean...

    The dark gray triangle has two known sides and I think angle 'b' can be found too. So is that enough to find the third side of the triangle? If so then we can subtract that length from H and presto, blue triangle can be solved!

    So Pythagora for totalDist:
    PHP Code:
    totalDist Math.sqrt((dx) * (dx) + (dy) * (dy)); 
    and angle 'b' my trig is not so good but I'm pretty sure it could be done. Maybe find the top angle of the imaginary triangle just used in that last pythagora step above and subtract the top angle of the dotted line triangle (180 - (a + 90)).

    ----------------------------------------------------------------------1
    5-------------3-------------2-------------1-------------0-------------0
    -------0-------------0-------------0-------------0-------------0------0
    ----------------------------------------------------------------------0
    3-------------2-------------0-------------0---------------------------2
    --------------------------------------------------------3-------------3

  4. #4
    Member
    Join Date
    Mar 2008
    Posts
    82
    Would leave this to solve...

    Question 1) Is this way even possible or am I assuming too much?
    Question 2) Even if it does work would it just take longer to do it this way anyway?

    ----------------------------------------------------------------------1
    5-------------3-------------2-------------1-------------0-------------0
    -------0-------------0-------------0-------------0-------------0------0
    ----------------------------------------------------------------------0
    3-------------2-------------0-------------0---------------------------2
    --------------------------------------------------------3-------------3

  5. #5
    Senior Member rachil0's Avatar
    Join Date
    Jul 2007
    Location
    Columbus, OH.
    Posts
    465
    That might work, although it will have the same branch cut issue as the parametric solution. Recalling vaguely from geometry, SAS (side-angle-side) SSS and ASA all uniquely specify a triangle, but SSA does not. The figure you drew has this SSA arrangement and your triangle is not unique. I can make a second triangle with the same SSA - by picking the same other point, behind the car.

    Not to say you couldn't tackle the problem going that way - always more than one way to get the job done. Wikipedia's article on the law of sines appears to have a special section on this, entitled "the ambiguous case".

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center