Announcement

Collapse
No announcement yet.

Converting a 2nd order O.D.E to two 1st order O.D.E's

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Converting a 2nd order O.D.E to two 1st order O.D.E's

    Is there a general formula that can be used to convert a 2nd order O.D.E into a system of two 1st order O.D.E's (or an Nth order O.D.E into a system of N 1st order O.D.E's)? F'rinstance, I'd like to convert the O.D.E.
    y" - (1 - y2)y' + y = 0, [y(0) = .5, y'(0) = .5]
    into two 1st order O.D.E's
    u' = f(u, y)
    y' = f(y, t)
    ...but I've no idea where to begin. I can solve 1st order O.D.E's without too much difficulty, but 2nd order O.D.E's are hating on me...
    <p style="font-size:1024px">HTML is disabled in signatures </p>

  • #2
    Whoops, never mind, I managed to find my old diff eq textbook hiding under a pile of junk in the basement.
    y' = u
    u' = (1 - y2)u - y
    [y(0) = .5, u(0) = .5]
    Woot! Take that, second order!
    <p style="font-size:1024px">HTML is disabled in signatures </p>

    Comment


    • #3
      that is aneasy way

      there are many other ways also



      Jon Miller
      Jon Miller-
      I AM.CANADIAN
      GENERATION 35: The first time you see this, copy it into your sig on any forum and add 1 to the generation. Social experiment.

      Comment


      • #4
        I'll probably only need the easy way. I'm numerically solving these things, so the 1st order O.D.E's don't need to look especially pretty -- they just need to be 1st order.
        <p style="font-size:1024px">HTML is disabled in signatures </p>

        Comment


        • #5
          that was what I was expecting

          Jon Miller
          Jon Miller-
          I AM.CANADIAN
          GENERATION 35: The first time you see this, copy it into your sig on any forum and add 1 to the generation. Social experiment.

          Comment


          • #6


            Sorry, did something boring wake me there?

            Speaking of Erith:

            "It's not twinned with anywhere, but it does have a suicide pact with Dagenham" - Linda Smith

            Comment


            • #7
              If you are suffering from O.D.E, shouldn't you go to a doctor ASAP?
              Within weeks they'll be re-opening the shipyards
              And notifying the next of kin
              Once again...

              Comment


              • #8
                Originally posted by loinburger
                I'll probably only need the easy way. I'm numerically solving these things, so the 1st order O.D.E's don't need to look especially pretty -- they just need to be 1st order.
                Oh. For numerical analysis?
                (\__/) 07/07/1937 - Never forget
                (='.'=) "Claims demand evidence; extraordinary claims demand extraordinary evidence." -- Carl Sagan
                (")_(") "Starting the fire from within."

                Comment


                • #9
                  Yup, the prof gave us a whole slew of nasty 2nd order O.D.E's to solve for the midterm (take-home test).
                  <p style="font-size:1024px">HTML is disabled in signatures </p>

                  Comment


                  • #10
                    Do you need to write your own program, or use something like Maple or Mathematica?

                    I have always hated take home exams, they are always evil beyond belief.
                    (\__/) 07/07/1937 - Never forget
                    (='.'=) "Claims demand evidence; extraordinary claims demand extraordinary evidence." -- Carl Sagan
                    (")_(") "Starting the fire from within."

                    Comment


                    • #11
                      We need to submit our own, but we're allowed to test our solutions against Mathematica or Matlab in order to get error estimates, and we're also allowed to borrow code (our text is chock full of pseudocode).

                      Yeah, basically take-home exams are an excuse to give a 20-hour test. Fortunately, once I get my method programmed in, the rest should be pretty easy.
                      <p style="font-size:1024px">HTML is disabled in signatures </p>

                      Comment


                      • #12
                        Oh yeah, the programming is the hard part. C++? Fortran is the best for this, but you probably don't know it.
                        (\__/) 07/07/1937 - Never forget
                        (='.'=) "Claims demand evidence; extraordinary claims demand extraordinary evidence." -- Carl Sagan
                        (")_(") "Starting the fire from within."

                        Comment


                        • #13
                          Mathematica or Matlab. I don't know Matlab very well, but I've programmed O.D.E. solvers in Mathematica before. (Those were just basic implementations of Euler's method, though, while these equations are probably going to need something more like an Adams-Multivalue or Bulirsch-Stoer, but the principle's the same.)
                          <p style="font-size:1024px">HTML is disabled in signatures </p>

                          Comment


                          • #14
                            Never used Mathematica before. IIRC, it looks sort of like Lisp.
                            (\__/) 07/07/1937 - Never forget
                            (='.'=) "Claims demand evidence; extraordinary claims demand extraordinary evidence." -- Carl Sagan
                            (")_(") "Starting the fire from within."

                            Comment


                            • #15
                              Yeah, it's basically LISP with better built-in functions (it autmatically handles derivatives, f'rinstance). It's also not so anal about the parentheses.
                              <p style="font-size:1024px">HTML is disabled in signatures </p>

                              Comment

                              Working...
                              X