How to solve this ode $xy''-(1+x)y'+y=x^2$?












4












$begingroup$


Find the general solution of $xy''-(1+x)y'+y=x^2$ knowing that the homogeneous equation has the following solution: $e^{ax}$, where $a$ is a parameter you have to find.



I have found that $a=1$ or $a=1/x$.










share|cite|improve this question











$endgroup$








  • 1




    $begingroup$
    The parameter cannot depend on $x$.
    $endgroup$
    – dmtri
    Jan 3 at 17:04
















4












$begingroup$


Find the general solution of $xy''-(1+x)y'+y=x^2$ knowing that the homogeneous equation has the following solution: $e^{ax}$, where $a$ is a parameter you have to find.



I have found that $a=1$ or $a=1/x$.










share|cite|improve this question











$endgroup$








  • 1




    $begingroup$
    The parameter cannot depend on $x$.
    $endgroup$
    – dmtri
    Jan 3 at 17:04














4












4








4


2



$begingroup$


Find the general solution of $xy''-(1+x)y'+y=x^2$ knowing that the homogeneous equation has the following solution: $e^{ax}$, where $a$ is a parameter you have to find.



I have found that $a=1$ or $a=1/x$.










share|cite|improve this question











$endgroup$




Find the general solution of $xy''-(1+x)y'+y=x^2$ knowing that the homogeneous equation has the following solution: $e^{ax}$, where $a$ is a parameter you have to find.



I have found that $a=1$ or $a=1/x$.







ordinary-differential-equations






share|cite|improve this question















share|cite|improve this question













share|cite|improve this question




share|cite|improve this question








edited Jan 3 at 17:12









dmtri

1,5262521




1,5262521










asked Jan 3 at 16:57









Gloria GuerreroGloria Guerrero

211




211








  • 1




    $begingroup$
    The parameter cannot depend on $x$.
    $endgroup$
    – dmtri
    Jan 3 at 17:04














  • 1




    $begingroup$
    The parameter cannot depend on $x$.
    $endgroup$
    – dmtri
    Jan 3 at 17:04








1




1




$begingroup$
The parameter cannot depend on $x$.
$endgroup$
– dmtri
Jan 3 at 17:04




$begingroup$
The parameter cannot depend on $x$.
$endgroup$
– dmtri
Jan 3 at 17:04










3 Answers
3






active

oldest

votes


















1












$begingroup$

Hint. You are correct, the homogeneous case of the given linear ODE has $e^x$ as a solution (the parameter $a$ is supposed to be a constant real number). Note that $y=-x^2$ is a particular solution. Is there any other polynomial solution? Substitute $y(x)=Ax^2+Bx+C$ into the ODE, then
$$x(2A)-(1+x)(2Ax+B)+(Ax^2+Bx+C)=x^2$$
What may we conclude?






share|cite|improve this answer











$endgroup$





















    1












    $begingroup$

    The equation $xy''-(1+x)y'+y=x^2$ can be rewritten as $(xy''-y')+(y-xy')=x^2.$ After division by $x^2$ we have
    $$
    frac{xy''-y'}{x^2} + frac{y-xy'}{x^2} = 1,
    $$

    which can be rewritten as
    $$
    Big( frac{y'}{x} Big)' - Big( frac{y}{x} Big)' = 1.
    $$



    Taking the antiderivative gives
    $$
    frac{y'}{x} - frac{y}{x} = x + C,
    $$

    which after multiplication with $x$ gives
    $$y' - y = x^2+ Cx.$$



    Now we multiply with the integrating factor $e^{-x}$:
    $$e^{-x} y' - e^{-x} y = x^2 e^{-x} + Cx e^{-x}.$$



    The left hand side can be rewritten as a derivative:
    $$( e^{-x} y )' = x^2 e^{-x} + Cx e^{-x}.$$



    Taking the antiderivative gives
    $$e^{-x} y = -(x^2+2x+2) e^{-x} - C(x+1) e^{-x} + D.$$



    Thus, all solutions to the original differential equation are given by
    $$y = -(x^2+2x+2) - C(x+1) + D e^x,$$
    where $C$ and $D$ are two constants.






    share|cite|improve this answer









    $endgroup$





















      0












      $begingroup$

      Substitute $$y(x)=(-x-1)v(x)$$ then we get
      $$-xfrac{d^2v(x)}{dx^2(x+1)}+frac{dv(x)}{dx}(x^2+1)=x^2$$
      let $$frac{dv(x)}{dx}=u(x)$$ then we get
      $$frac{du(x)}{dx}+frac{-x^2-1)u(x)}{x(x+1)}=-frac{x}{x+1}$$
      with $$mu(x)=e^{intfrac{-x^2-1}{x(x+1)}dx}=frac{e^{-x}(x+1)^2}{x}$$ we get
      $$frac{e^{-x}(x+1)^2}{x}frac{du(x)}{dx}+frac{d}{dx}left(frac{e^{-x}(x+1)^2}{x}right)u(x)=-e^{-x}(x+1)$$ and this is
      $$intfrac{d}{dx}left(frac{e^{-x}(x+1)^2u(x)}{x}right)=int-e^{-x}(x+1)dx$$
      Can you finish?






      share|cite|improve this answer









      $endgroup$













        Your Answer





        StackExchange.ifUsing("editor", function () {
        return StackExchange.using("mathjaxEditing", function () {
        StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
        StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
        });
        });
        }, "mathjax-editing");

        StackExchange.ready(function() {
        var channelOptions = {
        tags: "".split(" "),
        id: "69"
        };
        initTagRenderer("".split(" "), "".split(" "), channelOptions);

        StackExchange.using("externalEditor", function() {
        // Have to fire editor after snippets, if snippets enabled
        if (StackExchange.settings.snippets.snippetsEnabled) {
        StackExchange.using("snippets", function() {
        createEditor();
        });
        }
        else {
        createEditor();
        }
        });

        function createEditor() {
        StackExchange.prepareEditor({
        heartbeatType: 'answer',
        autoActivateHeartbeat: false,
        convertImagesToLinks: true,
        noModals: true,
        showLowRepImageUploadWarning: true,
        reputationToPostImages: 10,
        bindNavPrevention: true,
        postfix: "",
        imageUploader: {
        brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
        contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
        allowUrls: true
        },
        noCode: true, onDemand: true,
        discardSelector: ".discard-answer"
        ,immediatelyShowMarkdownHelp:true
        });


        }
        });














        draft saved

        draft discarded


















        StackExchange.ready(
        function () {
        StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3060774%2fhow-to-solve-this-ode-xy-1xyy-x2%23new-answer', 'question_page');
        }
        );

        Post as a guest















        Required, but never shown

























        3 Answers
        3






        active

        oldest

        votes








        3 Answers
        3






        active

        oldest

        votes









        active

        oldest

        votes






        active

        oldest

        votes









        1












        $begingroup$

        Hint. You are correct, the homogeneous case of the given linear ODE has $e^x$ as a solution (the parameter $a$ is supposed to be a constant real number). Note that $y=-x^2$ is a particular solution. Is there any other polynomial solution? Substitute $y(x)=Ax^2+Bx+C$ into the ODE, then
        $$x(2A)-(1+x)(2Ax+B)+(Ax^2+Bx+C)=x^2$$
        What may we conclude?






        share|cite|improve this answer











        $endgroup$


















          1












          $begingroup$

          Hint. You are correct, the homogeneous case of the given linear ODE has $e^x$ as a solution (the parameter $a$ is supposed to be a constant real number). Note that $y=-x^2$ is a particular solution. Is there any other polynomial solution? Substitute $y(x)=Ax^2+Bx+C$ into the ODE, then
          $$x(2A)-(1+x)(2Ax+B)+(Ax^2+Bx+C)=x^2$$
          What may we conclude?






          share|cite|improve this answer











          $endgroup$
















            1












            1








            1





            $begingroup$

            Hint. You are correct, the homogeneous case of the given linear ODE has $e^x$ as a solution (the parameter $a$ is supposed to be a constant real number). Note that $y=-x^2$ is a particular solution. Is there any other polynomial solution? Substitute $y(x)=Ax^2+Bx+C$ into the ODE, then
            $$x(2A)-(1+x)(2Ax+B)+(Ax^2+Bx+C)=x^2$$
            What may we conclude?






            share|cite|improve this answer











            $endgroup$



            Hint. You are correct, the homogeneous case of the given linear ODE has $e^x$ as a solution (the parameter $a$ is supposed to be a constant real number). Note that $y=-x^2$ is a particular solution. Is there any other polynomial solution? Substitute $y(x)=Ax^2+Bx+C$ into the ODE, then
            $$x(2A)-(1+x)(2Ax+B)+(Ax^2+Bx+C)=x^2$$
            What may we conclude?







            share|cite|improve this answer














            share|cite|improve this answer



            share|cite|improve this answer








            edited Jan 3 at 17:28

























            answered Jan 3 at 17:05









            Robert ZRobert Z

            99.1k1068139




            99.1k1068139























                1












                $begingroup$

                The equation $xy''-(1+x)y'+y=x^2$ can be rewritten as $(xy''-y')+(y-xy')=x^2.$ After division by $x^2$ we have
                $$
                frac{xy''-y'}{x^2} + frac{y-xy'}{x^2} = 1,
                $$

                which can be rewritten as
                $$
                Big( frac{y'}{x} Big)' - Big( frac{y}{x} Big)' = 1.
                $$



                Taking the antiderivative gives
                $$
                frac{y'}{x} - frac{y}{x} = x + C,
                $$

                which after multiplication with $x$ gives
                $$y' - y = x^2+ Cx.$$



                Now we multiply with the integrating factor $e^{-x}$:
                $$e^{-x} y' - e^{-x} y = x^2 e^{-x} + Cx e^{-x}.$$



                The left hand side can be rewritten as a derivative:
                $$( e^{-x} y )' = x^2 e^{-x} + Cx e^{-x}.$$



                Taking the antiderivative gives
                $$e^{-x} y = -(x^2+2x+2) e^{-x} - C(x+1) e^{-x} + D.$$



                Thus, all solutions to the original differential equation are given by
                $$y = -(x^2+2x+2) - C(x+1) + D e^x,$$
                where $C$ and $D$ are two constants.






                share|cite|improve this answer









                $endgroup$


















                  1












                  $begingroup$

                  The equation $xy''-(1+x)y'+y=x^2$ can be rewritten as $(xy''-y')+(y-xy')=x^2.$ After division by $x^2$ we have
                  $$
                  frac{xy''-y'}{x^2} + frac{y-xy'}{x^2} = 1,
                  $$

                  which can be rewritten as
                  $$
                  Big( frac{y'}{x} Big)' - Big( frac{y}{x} Big)' = 1.
                  $$



                  Taking the antiderivative gives
                  $$
                  frac{y'}{x} - frac{y}{x} = x + C,
                  $$

                  which after multiplication with $x$ gives
                  $$y' - y = x^2+ Cx.$$



                  Now we multiply with the integrating factor $e^{-x}$:
                  $$e^{-x} y' - e^{-x} y = x^2 e^{-x} + Cx e^{-x}.$$



                  The left hand side can be rewritten as a derivative:
                  $$( e^{-x} y )' = x^2 e^{-x} + Cx e^{-x}.$$



                  Taking the antiderivative gives
                  $$e^{-x} y = -(x^2+2x+2) e^{-x} - C(x+1) e^{-x} + D.$$



                  Thus, all solutions to the original differential equation are given by
                  $$y = -(x^2+2x+2) - C(x+1) + D e^x,$$
                  where $C$ and $D$ are two constants.






                  share|cite|improve this answer









                  $endgroup$
















                    1












                    1








                    1





                    $begingroup$

                    The equation $xy''-(1+x)y'+y=x^2$ can be rewritten as $(xy''-y')+(y-xy')=x^2.$ After division by $x^2$ we have
                    $$
                    frac{xy''-y'}{x^2} + frac{y-xy'}{x^2} = 1,
                    $$

                    which can be rewritten as
                    $$
                    Big( frac{y'}{x} Big)' - Big( frac{y}{x} Big)' = 1.
                    $$



                    Taking the antiderivative gives
                    $$
                    frac{y'}{x} - frac{y}{x} = x + C,
                    $$

                    which after multiplication with $x$ gives
                    $$y' - y = x^2+ Cx.$$



                    Now we multiply with the integrating factor $e^{-x}$:
                    $$e^{-x} y' - e^{-x} y = x^2 e^{-x} + Cx e^{-x}.$$



                    The left hand side can be rewritten as a derivative:
                    $$( e^{-x} y )' = x^2 e^{-x} + Cx e^{-x}.$$



                    Taking the antiderivative gives
                    $$e^{-x} y = -(x^2+2x+2) e^{-x} - C(x+1) e^{-x} + D.$$



                    Thus, all solutions to the original differential equation are given by
                    $$y = -(x^2+2x+2) - C(x+1) + D e^x,$$
                    where $C$ and $D$ are two constants.






                    share|cite|improve this answer









                    $endgroup$



                    The equation $xy''-(1+x)y'+y=x^2$ can be rewritten as $(xy''-y')+(y-xy')=x^2.$ After division by $x^2$ we have
                    $$
                    frac{xy''-y'}{x^2} + frac{y-xy'}{x^2} = 1,
                    $$

                    which can be rewritten as
                    $$
                    Big( frac{y'}{x} Big)' - Big( frac{y}{x} Big)' = 1.
                    $$



                    Taking the antiderivative gives
                    $$
                    frac{y'}{x} - frac{y}{x} = x + C,
                    $$

                    which after multiplication with $x$ gives
                    $$y' - y = x^2+ Cx.$$



                    Now we multiply with the integrating factor $e^{-x}$:
                    $$e^{-x} y' - e^{-x} y = x^2 e^{-x} + Cx e^{-x}.$$



                    The left hand side can be rewritten as a derivative:
                    $$( e^{-x} y )' = x^2 e^{-x} + Cx e^{-x}.$$



                    Taking the antiderivative gives
                    $$e^{-x} y = -(x^2+2x+2) e^{-x} - C(x+1) e^{-x} + D.$$



                    Thus, all solutions to the original differential equation are given by
                    $$y = -(x^2+2x+2) - C(x+1) + D e^x,$$
                    where $C$ and $D$ are two constants.







                    share|cite|improve this answer












                    share|cite|improve this answer



                    share|cite|improve this answer










                    answered Jan 3 at 17:48









                    md2perpemd2perpe

                    8,11611028




                    8,11611028























                        0












                        $begingroup$

                        Substitute $$y(x)=(-x-1)v(x)$$ then we get
                        $$-xfrac{d^2v(x)}{dx^2(x+1)}+frac{dv(x)}{dx}(x^2+1)=x^2$$
                        let $$frac{dv(x)}{dx}=u(x)$$ then we get
                        $$frac{du(x)}{dx}+frac{-x^2-1)u(x)}{x(x+1)}=-frac{x}{x+1}$$
                        with $$mu(x)=e^{intfrac{-x^2-1}{x(x+1)}dx}=frac{e^{-x}(x+1)^2}{x}$$ we get
                        $$frac{e^{-x}(x+1)^2}{x}frac{du(x)}{dx}+frac{d}{dx}left(frac{e^{-x}(x+1)^2}{x}right)u(x)=-e^{-x}(x+1)$$ and this is
                        $$intfrac{d}{dx}left(frac{e^{-x}(x+1)^2u(x)}{x}right)=int-e^{-x}(x+1)dx$$
                        Can you finish?






                        share|cite|improve this answer









                        $endgroup$


















                          0












                          $begingroup$

                          Substitute $$y(x)=(-x-1)v(x)$$ then we get
                          $$-xfrac{d^2v(x)}{dx^2(x+1)}+frac{dv(x)}{dx}(x^2+1)=x^2$$
                          let $$frac{dv(x)}{dx}=u(x)$$ then we get
                          $$frac{du(x)}{dx}+frac{-x^2-1)u(x)}{x(x+1)}=-frac{x}{x+1}$$
                          with $$mu(x)=e^{intfrac{-x^2-1}{x(x+1)}dx}=frac{e^{-x}(x+1)^2}{x}$$ we get
                          $$frac{e^{-x}(x+1)^2}{x}frac{du(x)}{dx}+frac{d}{dx}left(frac{e^{-x}(x+1)^2}{x}right)u(x)=-e^{-x}(x+1)$$ and this is
                          $$intfrac{d}{dx}left(frac{e^{-x}(x+1)^2u(x)}{x}right)=int-e^{-x}(x+1)dx$$
                          Can you finish?






                          share|cite|improve this answer









                          $endgroup$
















                            0












                            0








                            0





                            $begingroup$

                            Substitute $$y(x)=(-x-1)v(x)$$ then we get
                            $$-xfrac{d^2v(x)}{dx^2(x+1)}+frac{dv(x)}{dx}(x^2+1)=x^2$$
                            let $$frac{dv(x)}{dx}=u(x)$$ then we get
                            $$frac{du(x)}{dx}+frac{-x^2-1)u(x)}{x(x+1)}=-frac{x}{x+1}$$
                            with $$mu(x)=e^{intfrac{-x^2-1}{x(x+1)}dx}=frac{e^{-x}(x+1)^2}{x}$$ we get
                            $$frac{e^{-x}(x+1)^2}{x}frac{du(x)}{dx}+frac{d}{dx}left(frac{e^{-x}(x+1)^2}{x}right)u(x)=-e^{-x}(x+1)$$ and this is
                            $$intfrac{d}{dx}left(frac{e^{-x}(x+1)^2u(x)}{x}right)=int-e^{-x}(x+1)dx$$
                            Can you finish?






                            share|cite|improve this answer









                            $endgroup$



                            Substitute $$y(x)=(-x-1)v(x)$$ then we get
                            $$-xfrac{d^2v(x)}{dx^2(x+1)}+frac{dv(x)}{dx}(x^2+1)=x^2$$
                            let $$frac{dv(x)}{dx}=u(x)$$ then we get
                            $$frac{du(x)}{dx}+frac{-x^2-1)u(x)}{x(x+1)}=-frac{x}{x+1}$$
                            with $$mu(x)=e^{intfrac{-x^2-1}{x(x+1)}dx}=frac{e^{-x}(x+1)^2}{x}$$ we get
                            $$frac{e^{-x}(x+1)^2}{x}frac{du(x)}{dx}+frac{d}{dx}left(frac{e^{-x}(x+1)^2}{x}right)u(x)=-e^{-x}(x+1)$$ and this is
                            $$intfrac{d}{dx}left(frac{e^{-x}(x+1)^2u(x)}{x}right)=int-e^{-x}(x+1)dx$$
                            Can you finish?







                            share|cite|improve this answer












                            share|cite|improve this answer



                            share|cite|improve this answer










                            answered Jan 3 at 17:18









                            Dr. Sonnhard GraubnerDr. Sonnhard Graubner

                            76.8k42866




                            76.8k42866






























                                draft saved

                                draft discarded




















































                                Thanks for contributing an answer to Mathematics Stack Exchange!


                                • Please be sure to answer the question. Provide details and share your research!

                                But avoid



                                • Asking for help, clarification, or responding to other answers.

                                • Making statements based on opinion; back them up with references or personal experience.


                                Use MathJax to format equations. MathJax reference.


                                To learn more, see our tips on writing great answers.




                                draft saved


                                draft discarded














                                StackExchange.ready(
                                function () {
                                StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3060774%2fhow-to-solve-this-ode-xy-1xyy-x2%23new-answer', 'question_page');
                                }
                                );

                                Post as a guest















                                Required, but never shown





















































                                Required, but never shown














                                Required, but never shown












                                Required, but never shown







                                Required, but never shown

































                                Required, but never shown














                                Required, but never shown












                                Required, but never shown







                                Required, but never shown







                                Popular posts from this blog

                                Ellipse (mathématiques)

                                Quarter-circle Tiles

                                Mont Emei