Results 1 to 12 of 12

Thread: [SOLVED] Someone please figure this out.

  1. #1

    Thread Starter
    Hyperactive Member Q_Me's Avatar
    Join Date
    Dec 2001
    Posts
    327

    Arrow [SOLVED] Someone please figure this out.

    I made it in Geo-SketchPad to give an idea to my delima. I don't know how to find G or P when it is rotated to the given angle of m<roa

    Someone help, I need an equation so I can put it into VB, and translate the points to a given angle.
    Attached Images Attached Images  
    Last edited by Q_Me; Oct 3rd, 2004 at 01:58 PM.
    53323737 15 743 313402 05 740313063. 17 15 4150 743 313402 05 140393403437 5203 743 30210.


  2. #2

    Thread Starter
    Hyperactive Member Q_Me's Avatar
    Join Date
    Dec 2001
    Posts
    327
    53323737 15 743 313402 05 740313063. 17 15 4150 743 313402 05 140393403437 5203 743 30210.


  3. #3
    Only Slightly Obsessive jemidiah's Avatar
    Join Date
    Apr 2002
    Posts
    2,431
    For G...

    Think in Polar mode, rotation is easy there.

    m(angle)Goa = 90 + 57 = 147. So theta is 147 degrees, and r (radius) is d, 224.84 px. Translating from Polar to Rectanglular gives x = rcos(theta), y = rsin(theta) or
    x = 224.84*cos(147 deg)
    x = -188.57 px
    y = 224.84*sin(147 deg)
    y = 122.46 px

    G = (-188.57, 122.46)

    Now, the others are more difficult.... lemme think on P

    We need r and theta. For r, we can simply use the Pythagorean Theorem.
    n2 + lo2 = r2
    r = sqrt(n2 + lo2)
    r = sqrt(59.022 + 91.672)
    r = 109.03 px

    Theta is a bit more difficult, though we can use the nice fact that the angle Gol is known and we have Trig functions.
    m(angle)Poa = m(angle)loa - m(angle)Pol
    m(angle)Poa = m(angle)Goa + 90 - m(angle)Pol
    m(angle)Poa = m(angle)Roa + 90 + 90 - m(angle)Pol
    m(angle)Poa = 57 + 90 + 90 - m(angle)Pol
    m(angle)Poa = 237 - m(angle)Pol
    ----tan(m(angle)Pol) = n/lo
    ----m(angle)Pol = atan(n/lo) 'atan = inverse tangent; arctangent (not 1/tan(x))
    ----m(angle)Pol = atan(59.02/91.67)
    ----m(angle)Pol = atan(0.6438)
    ----m(angle)Pol = 32.77 deg
    m(angle)Poa = 237 - 32.77
    m(angle)Poa = 204.23 deg

    Now that we have r and theta, plug in as before
    x = 109.03*cos(204.23 deg)
    x = -99.43 px
    y = 109.03*sin(204.23 deg)
    y = -44.75 px
    P = (-99.43 px, -44.75 px)


    Now, finally, slope is simple.
    Py - Gy
    -------
    Px - Gx

    M = -167.21/89.14
    M = -1.876


    To summarize,
    G = (-188.57, 122.46)
    P = (-99.43 px, -44.75 px)
    M = -1.876

    I do truly hope my math is right, but the reasoning is sound. Good luck!
    The time you enjoy wasting is not wasted time.
    Bertrand Russell

    <- Remember to rate posts you find helpful.

  4. #4

    Thread Starter
    Hyperactive Member Q_Me's Avatar
    Join Date
    Dec 2001
    Posts
    327


    I find that facinating. Do you have a 1 or 2 line expression to solve each points with given Theta? In other words, instead of plugging in the numbers, like you so nicely did , use variables. Because I don't see the numbers, I evaluate the expressions.

    Other than that. WOW
    53323737 15 743 313402 05 740313063. 17 15 4150 743 313402 05 140393403437 5203 743 30210.


  5. #5
    Fanatic Member alkatran's Avatar
    Join Date
    Apr 2002
    Location
    Canada
    Posts
    860
    If you know l, o and n you can find P

    Find the angle from l to o, add 90, and extend a line of n length in that direction to get P.

    Now since you know d is parrallel to n, you can find G too.

    With G and P you can find m

    etc

    These kinds of problems are all about finding ONE thing. Then it's a big domino effect.
    Don't pay attention to this signature, it's contradictory.

  6. #6
    Only Slightly Obsessive jemidiah's Avatar
    Join Date
    Apr 2002
    Posts
    2,431
    G(x, y)

    x = d*cos(90 + m(angle)Roa)
    y = d*sin(90 + m(angle)Roa)


    P(x, y)

    x = sqrt(n2 + lo2)*cos(m(angle)Roa + 180 - atan(n/lo))
    y = sqrt(n2 + lo2)*sin(m(angle)Roa + 180 - atan(n/lo))


    M

    Py - Gy
    -------
    Px - Gx

    (sqrt(n2 + lo2)*sin(m(angle)Roa + 180 - atan(n/lo)) - d*sin(90 + m(angle)Roa))
    ------------------------------------------------------------------------------
    (sqrt(n2 + lo2)*cos(m(angle)Roa + 180 - atan(n/lo)) - d*cos(90 + m(angle)Roa))

    Note: All trig functions are in degrees. If you need Radians (VB uses them) you need to multiply the argument in Sine and Cosine by Pi / 180 = 3.14159265 / 180 = 0.0174532925
    The time you enjoy wasting is not wasted time.
    Bertrand Russell

    <- Remember to rate posts you find helpful.

  7. #7

    Thread Starter
    Hyperactive Member Q_Me's Avatar
    Join Date
    Dec 2001
    Posts
    327
    Awesome. I'll check the math when I get to my evening class to use GeoSketch.

    53323737 15 743 313402 05 740313063. 17 15 4150 743 313402 05 140393403437 5203 743 30210.


  8. #8
    type Woss is new Grumpy; wossname's Avatar
    Join Date
    Aug 2002
    Location
    #!/bin/bash
    Posts
    5,682
    Jesus Christ! This is the scariest thread I have ever seen Not seen so much algebra since I nailed the Nuclear and Particle Physics module exam of my A-Levels.

    Respect.
    I don't live here any more.

  9. #9

    Thread Starter
    Hyperactive Member Q_Me's Avatar
    Join Date
    Dec 2001
    Posts
    327
    Is there a subistute for atan? I found "G" easily. But I relized the troubles with "atan" in previous applications I have made due to the "reversal" way of plotting points. So is there a way to just use Sine and Cosine instead of Atan in the usage of finding point P?
    53323737 15 743 313402 05 740313063. 17 15 4150 743 313402 05 140393403437 5203 743 30210.


  10. #10
    Fanatic Member alkatran's Avatar
    Join Date
    Apr 2002
    Location
    Canada
    Posts
    860
    What in the world are you talking about with atan being reversed??
    Don't pay attention to this signature, it's contradictory.

  11. #11
    Only Slightly Obsessive jemidiah's Avatar
    Join Date
    Apr 2002
    Posts
    2,431
    http://mathworld.wolfram.com/InverseTangent.html

    Number 19 gives a good definition in terms of inverse sine. I checked it in VB6.0 using their derived math function for inverse sine (Atn(X / Sqr(-X * X + 1))) and, if it was innacurate, it was only so by about 0.000000000000008 from the value given by straight inverse tangent. Hope that helps.

    In terms of sine and cosine... I haven't been able to find a definition of atan in terms of either one. It would probably be easier to use one of the summation series given in that link on the top. They're ugly, but they sure should work.


    btw wossname:
    The time you enjoy wasting is not wasted time.
    Bertrand Russell

    <- Remember to rate posts you find helpful.

  12. #12

    Thread Starter
    Hyperactive Member Q_Me's Avatar
    Join Date
    Dec 2001
    Posts
    327
    Awesome. Thanks.

    Atan is sometimes used to plot points in reverse order of code.

    eg. The most common rotation of rotating 4 vectors at a time. It finds the pixel at the specified rotation then plots it as normal as if it were a boxed picture.
    53323737 15 743 313402 05 740313063. 17 15 4150 743 313402 05 140393403437 5203 743 30210.


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