Results 1 to 3 of 3

Math Help - finding the "end points" of an orthogonal line giving the lenght

  1. #1
    Newbie
    Joined
    Mar 2011
    Posts
    2

    finding the "end points" of an orthogonal line giving the lenght

    First of all sorry if am posting on the wrong sub forum or the title is a little misleading..

    Am working on a software right now, and am really embarrassed that I dont remember the basic mathematic to solve this problem.

    this is the thing, for any given line (lets say L1) I need to create two orthogonal lines (L2 and L3) with length C, at the two ends of L1

    finding the "end points" of an orthogonal line giving the lenght-qin1p.jpg


    What I have is P1, P2 and C, and what I need is P3(x3, y3), P4(x4, y4) etc
    Attached Thumbnails Attached Thumbnails finding the "end points" of an orthogonal line giving the lenght-jaxes.jpg   finding the "end points" of an orthogonal line giving the lenght-yecqy.jpg  
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Super Member

    Joined
    May 2006
    From
    Lexington, MA (USA)
    Posts
    11,711
    Thanks
    630
    Hello, axl456!

    This takes quite a bit of work . . .


    \text{For any given line }L_1\text{, I need to create two orthogonal lines}
    L_2\text{ and }L_3\text{ with length }c\text{ at the ends of }L_1.

    We have points P_1(x_1,y_1) and P_2(x_2,y_2).

    Let: \,\theta = the angle at \,P_1.

    Let: R \:=\:\overline{P_1P_2} \:=\:\sqrt{(x_2-x_1)^2 + (y_2-y_1)^2}

    Code:
    
          |
          |                    (x2,y2)
          |                       ♥ P2
          |             R     *   |
          |               *       | y2-y1
          |           *  @        |
          |    P1 ♥---------------*
          |    (x1,y1)  x2-x1       
          |
      - - + - - - - - - - - - - - - - - -
          |
    

    Then we have: . \begin{Bmatrix}\sin\theta &=& \dfrac{y_2-y_1}{R} \\ \\[-4mm] \cos\theta &=& \dfrac{x_2-x_1}{R}\end{Bmatrix}


    Let:. . \begin{Bmatrix} \Delta x &=& \frac{1}{2}c\sin\theta \\ \\[-4mm] \Delta y &=& \frac{1}{2}c\cos\theta \end{Bmatrix}

    Code:
    
          |                   C
          |                   *
          |                   |\
          |                   | \
          |   A               |  \  ∆x
          |   *               .---♥---.
          |   |\              *  P2\  |
          | ∆y| \         *         \ | ∆y
          |   |  \P1  *              \|
          |   .---♥---.               *
          |     ∆x \  |               D
          |         \ |
          |          \|
          |           *
          |           B
          |
      - - + - - - - - - - - - - - - - - -
          |

    To move from \,P_1 to \,A: .move left \Delta x and up \Delta y.
    . . Hence: . A(x_1\! -\! \Delta x,\;y_1 \!+\! \Delta y)

    To move from \,P_1 to \,B: .move right \Delta x and down \Delta y.
    . . Hence: . B(x_1\! +\! \Delta x,\;y_1\!-\!\Delta y)

    To move from \,P_2 to \,C: .move left \Delta x and up \Delta y.
    . . Hence: . C(x_2\!-\!\Delta x,\;y_2\!+\!\Delta y)

    To move from \,P_2 to \,D: .move right \Delta x and down \Delta y.
    . . Hence: . D(x_2\!+\!\Delta x,\;y_2\!-\!\Delta y)

    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    Mar 2011
    Posts
    2
    thanks so much for your reply..

    While waiting for a reply, I keep analyzing it and found another solution..

    what I did is simple use the slope and distance equation:

    D \:=\:\sqrt{(x-x0)^2 + (y-yo)^2}

    m = (y-y0)/(x-x0)

    being (x, y) the point I need, and (x0, y0) the points I have.
    From those two I got this equation:

    x^2 - 2xx0 + xo^2 -(\dfrac{d^2}{1 + m^2}) = 0

    I solve it with the quadratic formula, and got 2 results (the two equidistant points that form the new line)


    this is the result:




    Again thank you!..
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Replies: 1
    Last Post: June 3rd 2011, 06:50 AM
  2. Replies: 2
    Last Post: April 24th 2011, 07:01 AM
  3. Replies: 1
    Last Post: October 25th 2010, 04:45 AM
  4. Finding the "normal line"
    Posted in the Calculus Forum
    Replies: 1
    Last Post: October 5th 2009, 09:29 PM
  5. Finding the "normal line" of a graph.
    Posted in the Calculus Forum
    Replies: 2
    Last Post: October 4th 2009, 02:05 PM

Search Tags


/mathhelpforum @mathhelpforum