Falcon BMS Forum
    • Register
    • Login
    • Search
    • Categories
    • Unread
    • Recent
    • Unsolved
    • Popular
    • Website
    • Wiki
    • Discord

    Mathematical Formula for Navigation

    General Discussion
    11
    19
    598
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Valkyrie
      Valkyrie last edited by

      Hi,

      Is there a mathematical formula to calculate heading to fly from a radial-distance to another?

      1 Reply Last reply Reply Quote 0
      • F
        Frederf last edited by

        That’s a toughie. I would combine the math for converting two points into Cartesian (X,Y) and then find the relative vector of the two points X1,Y1 - X2,Y2. Then the usual trickery for finding the direction from point 1 to point 2. I don’t know any trig trick to get output to be 0-360° without breaking it up into the four quadrants with if/then statements.

        Assuming two locations are given as
        (R1, A1), (R2, A2)

        Cartesian positions are
        (X1, Y1), (X2, Y2)
        (R1Cos(A1), R1Sin(A1)), (R2Cos(A2), R2Sin(A2))

        Relative Cartesian position is
        (X1-X2, Y1-Y2)
        ( R1Cos(A1) - R2Cos(A2), R1Sin(A1) - R2Sin(A2) )

        Relative polar position (direction component only)
        Quadrant 1
        A12 = 0° + ( ArcTan (Y1-Y2/X1-X2) )

        Quadrant 2
        A12 = 180° + ( ArcTan (Y1-Y2/X1-X2) )

        Quadrant 3
        A12 = 180° + ( ArcTan (Y1-Y2/X1-X2) )

        Quadrant 4
        A12 = 360° + ( ArcTan (Y1-Y2/X1-X2) )

        Despite the worry that math angles start with 0° right and increase counter-clockwise and compass angles start at 0° up increase clockwise the translations from coordinate system A to B and B to A cancel so it’s alright. If you’re using this on any capable device or language, the http://en.wikipedia.org/wiki/Atan2 function is a serious time-saver.

        A S 2 Replies Last reply Reply Quote 0
        • A
          Agave_Blue @Frederf last edited by

          If you can do that in Cartesian coordinates, can’t it be done in Polar coordinates? If so, would that allow you to derive distance and radial from one point to another?

          😕

          Snowman Blu3wolf 2 Replies Last reply Reply Quote 0
          • Snowman
            Snowman @Agave_Blue last edited by

            Interesting question. But why?

            Valkyrie 1 Reply Last reply Reply Quote 0
            • Blu3wolf
              Blu3wolf @Agave_Blue last edited by

              @Agave_Blue:

              If you can do that in Cartesian coordinates, can’t it be done in Polar coordinates? If so, would that allow you to derive distance and radial from one point to another?

              😕

              We did this kind of thing in my maths class at the start of the year… in polar coords, I mean. Can’t remember much of it now…

              A 1 Reply Last reply Reply Quote 0
              • S
                sthalik @Frederf last edited by

                @Frederf:

                Relative polar position (direction component only)
                Quadrant 1

                Normalize it first as per [1]. Didn’t check!

                NB atan2 has different semantics WRT quadrants, not just confusing argument order.

                SLangner 1 Reply Last reply Reply Quote 0
                • SLangner
                  SLangner @sthalik last edited by

                  This may make for a good paper exercise for, say, a mathematics class, but applying it to the real world . . . good luck. Winds aloft will add variables which, while flying, will have to be compensated for ‘on the fly.’

                  M 1 Reply Last reply Reply Quote 0
                  • M
                    Mokong48 @SLangner last edited by

                    This is called fix to fix.

                    Did it using radials and dme.

                    Mostly estimates.

                    Netstat 1 Reply Last reply Reply Quote 0
                    • Netstat
                      Netstat @Mokong48 last edited by

                      What you want is called indeed a fix-to-fix, there is no formula for it as far as I am aware, personally I know the ‘pencil technique’.
                      For instructions on how to fly a fix-to-fix, look up AFI 11-217, it might be hard to find information on it since it has long been removed from the USAF syllabus since advanced avionics have taken over and made the method illegal/obsolete.

                      Blu3wolf 1 Reply Last reply Reply Quote 0
                      • Blu3wolf
                        Blu3wolf @Netstat last edited by

                        11-217 is superceded, I don’t know about it being illegal…

                        1 Reply Last reply Reply Quote 0
                        • A
                          Agave_Blue @Blu3wolf last edited by

                          @Blu3wolf:

                          We did this kind of thing in my maths class at the start of the year… in polar coords, I mean. Can’t remember much of it now…

                          Too long ago for me to remember as well. Seems like there ought to be something. They are all fixed points in space. It’s just the origins that are offset. We certainly describe them as polar coordinates (15 miles at 175* or 175 radial at DME 15).

                          Blu3wolf 1 Reply Last reply Reply Quote 0
                          • Blu3wolf
                            Blu3wolf @Agave_Blue last edited by

                            well on a flat plane its just simple trigonometry… sin equals opposite over adjacent and all that…

                            1 Reply Last reply Reply Quote 0
                            • Valkyrie
                              Valkyrie @Snowman last edited by

                              @Snowman:

                              Interesting question. But why?

                              Main reason is to track the shortest course to save fuel and time.
                              And other one is just love for math 🙂

                              Blu3wolf F 2 Replies Last reply Reply Quote 0
                              • Blu3wolf
                                Blu3wolf @Valkyrie last edited by

                                you have love for mentally calculating trig ratios?

                                Dee-Jay 1 Reply Last reply Reply Quote 0
                                • Dee-Jay
                                  Dee-Jay @Blu3wolf last edited by

                                  IRL, we are using graphical (mental) resolution… Like for the bulls.

                                  http://server.3rd-wing.net/public/Bureau_75th/Bullseye%20Lock-On%20A-10.pdf

                                  (Sorry, doc is in french, but looking at the pic should be enough)

                                  ASUSTeK ROG MAXIMUS X HERO / Intel Core i5-8600K (4.6 GHz) / NVIDIA GeForce RTX 3080 Ti FE 12GB / 32GB DDR4 Ballistix Elite 3200 MHz / Samsung SSD 970 EVO Plus 2TB / Be Quiet! Straight Power 11 1000W Platinum / Windows 10 Home 64-bit / HOTAS Cougar FSSB R1 (Warthog grip) / SIMPED / MFD Cougar / ViperGear ICP / SimShaker JetPad / Track IR 5 / Curved LED 27'' Monitor 1080p Samsung C27F396 / HP Reverb G2 VR Headset.

                                  toonces 1 Reply Last reply Reply Quote 0
                                  • F
                                    Frederf @Valkyrie last edited by

                                    @Agave_Blue:

                                    If you can do that in Cartesian coordinates, can’t it be done in Polar coordinates? If so, would that allow you to derive distance and radial from one point to another?😕

                                    I don’t really know what you mean “do it in polar.” What OP wants is a function which maps a 4-space (two coordinates) to 1-space (one angle). The functional dependence of the result on the inputs is one mechanism only, regardless if its expressed in equivalent ways. The final form of the function is completely devoid of the interim X and Y (I didn’t in my post simply because of the space it takes up). It’s a function f(x1, x2, x3, x4) = y.

                                    Here’s the substitution for X and Y with their original input identities just to show just how long the equation gets:
                                    Q1 A12 = 0° + ( ( R1Cos(A1) - R2Cos(A2) ) / ( R1Cos(A1) - R2Cos(A2) ) )
                                    Notice there is nothing Cartesian about the above equation. The fact it made a temporary excursion into X-Y land is obscured when all is said and done. You might think it looks suspiciously written but since that describes the unique solution, there’s no other way to express the above that isn’t a trivial algebraic equivalent expression.

                                    Previously I said it was a 4-space to 1-space functional mapping. That’s not strictly true as the relative bearing between the points is invariant on scaling the picture. The direction between BZ 148 40nm and BZ 063 60nm is the same as between BZ 148 1nm and BZ 063 1.5nm. The direction depends on really the ratio of R1 and R2 so it’s really a mapping from 3-space (A1, A2, R1/R2) to 1-space (A12). The problem can be slightly simplified further if only only cares about the difference A1-A2, that is the output direction will be relative to the first angle instead of north which is easy to fix at the last minute. So, excluding the north-orientation fix at the last minute, it’s really a map from R-2 to R-1; f(X1-X2, X3/X4) = y for example.

                                    I’ll see if I can construct some graphs using the 2-space mapping described above.

                                    A 1 Reply Last reply Reply Quote 0
                                    • A
                                      Agave_Blue @Frederf last edited by

                                      @Frederf:

                                      I don’t really know what you mean “do it in polar.” ……

                                      Well, first, just to clarify, what I meant by “😕” was that I am not sure if what I’m suggesting makes sense.

                                      My thinking goes like this: We are presented information in Polar Coordinates - Distance, Angle. I guess I’m asking why add the ‘extra’ step of converting that to Cartesian Coordinates - X,Y? If you’re starting with Polar Coord, working in a world that typically gives you Polar Coords and ending in Polar Coords, then why not just do the distance/direction calculation in Polar Coords?

                                      That’s my thinking … the initial “😕” disclaimer still applies.

                                      Although if you had BZ of the various points in question …

                                      F 1 Reply Last reply Reply Quote 0
                                      • F
                                        Frederf @Agave_Blue last edited by

                                        I didn’t mean to be harsh, just sharing what I was thinking. I too thought pretty hard about how to express a solution without resorting to x and y components. I invoked the Law of cosines; see if this goes anywhere.

                                        Take the position vectors of the current location (A) and destination (B). Define a vector © that travels from A to B. The direction of C is the goal. To inform us about C we take the dot product of vector C with the unit vector in the 0° direction (i) and compare that with the Law that says that C*i = |C||i| cosine Θ. C dot i is just the x-component of C. |C| is the length of |C|. The length of |i| is one by definition. And Θ is the goal.

                                        So
                                        Cx = |C| cosine Θ
                                        If
                                        Cx = Bx-Ax
                                        |C| = sqrt( (Bx-Ax)^2 + (By-Ay)^2)

                                        Cosine Θ = (Bx-Ax) / sqrt( (Bx-Ax)^2 + (By-Ay)^2)

                                        We know how to write expressions of A and B in the x and y directions with sine and cosine. Knowing Theta gives double solutions that only requires one additional step to narrow the real answer within the sets of two even or odd-numbered quadrants. For example -23° lets you know it’s either in quadrant II or IV; +41° let’s you know it’s in quadrant I or III.

                                        Again, we end up with the components of the original two vectors defined by their components in the 0° direction and their components orthogonal to the 0° direction. This seems very Cartesian but it’s really just a consequence of orthogonality. We needn’t call them X and Y, just the direction which is aligned totally with the reference direction and that which totally isn’t. Sine and cosine themselves a defined by their mutual orthogonality and so you’ll always run into this component breakdown I fear. It seems inescapable unless you can find angular functions which are not trigonometric.

                                        1 Reply Last reply Reply Quote 0
                                        • toonces
                                          toonces @Dee-Jay last edited by

                                          @Dee-Jay:

                                          IRL, we are using graphical (mental) resolution… Like for the bulls.

                                          http://server.3rd-wing.net/public/Bureau_75th/Bullseye%20Lock-On%20A-10.pdf

                                          (Sorry, doc is in french, but looking at the pic should be enough)

                                          This is how I was taught to do it (nice pdf DJ!).

                                          I can’t help on the math. I suck at math!

                                          1 Reply Last reply Reply Quote 0
                                          • First post
                                            Last post

                                          35
                                          Online

                                          10.6k
                                          Users

                                          21.0k
                                          Topics

                                          348.8k
                                          Posts

                                          Benchmark Sims - All rights reserved ©