In the help document, we know that EulerEquations[y[x] Sqrt[1 + Derivative[1][y][x]^2], y[x], x] can solve the following Euler equation of equation :$$∫_{x_{\min}}^{x_{\max}}y(x)\sqrt{1+y'(x)^{2}} dx$$

But how can we solve the Euler equation in the following mixed case with integral and others terms by using MMA? enter image description here

The result of the variation of the above functional in the textbook is : enter image description here

Using the boundary conditions ${w(0)=0,w(L)=0,w'(0)=0}$, we can reduce the above results to: enter image description here

I did this, but it turned out to be obviously wrong:

 Integrate[(1/2 \[DoubleStruckCapitalE]*\[DoubleStruckCapitalJ]*
      w''[x] - q*w[x]), {x, 0, L}] + M*w'[L], w[x], x]

I need to find the first derivative of a functional according to the above textbook definition.

And the results in this link don't meet my needs.

  • 1
    $\begingroup$ I think you may need MMA's code to find the first derivative of functional by definition. I'm also interested in this problem. $\endgroup$
    – user69323
    Feb 17, 2020 at 5:58

1 Answer 1


First, as much as I see from documentation the function EulerEquations takes the Lagrangian as the argument, rather than the action. Therefore, there should be no Integratestatement. Just the expression staying under the integral. Second, EulerEquations do not treat the boundary terms such as M*w'[L]. And as a minor note, you have forgotten to square the w''[x] term. Like this it is

EulerEquations[(1/2 e*j*(w''[x])^2 - q*w[x]), w[x], x]

enter image description here

which is reasonable. You will have to add the boundary condition by hand.

Have fun!

  • $\begingroup$ Thank you very much for your help. I want to know if there is any way to achieve the $\delta$ result form in the textbook. $\endgroup$ Feb 17, 2020 at 23:09
  • 1
    $\begingroup$ Not that I know. $\endgroup$ Feb 18, 2020 at 8:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.