3
$\begingroup$

I am trying to get numeric solution for equations: $$ \left\{x^{(2,0)}(u,t) \left(1-\frac{y^{(1,0)}(u,t)^2}{\left(x^{(1,0)}(u,t)^2+y^{(1,0)}(u,t)^2\right)^{3/2}}\right)+\frac{x^{(1,0)}(u,t) y^{(1,0)}(u,t) y^{(2,0)}(u,t)}{\left(x^{(1,0)}(u,t)^2+y^{(1,0)}(u,t)^2\right)^{3/2}}-x^{(0,2)}(u,t)=0,-\frac{x^{(1,0)}(u,t)^2 y^{(2,0)}(u,t)}{\left(x^{(1,0)}(u,t)^2+y^{(1,0)}(u,t)^2\right)^{3/2}}+\frac{x^{(2,0)}(u,t) x^{(1,0)}(u,t) y^{(1,0)}(u,t)}{\left(x^{(1,0)}(u,t)^2+y^{(1,0)}(u,t)^2\right)^{3/2}}-y^{(0,2)}(u,t)+y^{(2,0)}(u,t)=0\right\} $$ with boundary conditions: $x(0,t)=0,x(1,t)=1,y(0,t)=0,y(1,t)=0,x(u,0)=u,y(u,0)=0,x^{(0,1)}(u,10)=0,y^{(0,1)}(u,10)=0$ Wolfram mathematica says:

CoefficientArrays::poly: $-\text{x$\$$4346}+\text{x$\$$4349} \left(1-\frac{\text{y$\$$4347}^2}{\left(\text{x$\$$4348}^2+\text{y$\$$4347}^2\right)^{3/2}}\right)+\frac{\text{x$\$$4348} \text{y$\$$4347} \text{y$\$$4350}}{\left(\text{x$\$$4348}^2+\text{y$\$$4347}^2\right)^{3/2}}$ is not a polynomial.

NDSolve::femper: PDE parsing error of $\left\{-\text{x$\$$4346}+\text{x$\$$4349} \left(1-\frac{\text{y$\$$4347}^2}{\left(\text{x$\$$4348}^2+\text{y$\$$4347}^2\right)^{3/2}}\right)+\frac{\text{x$\$$4348} \text{y$\$$4347} \text{y$\$$4350}}{\left(\text{x$\$$4348}^2+\text{y$\$$4347}^2\right)^{3/2}},\frac{\text{x$\$$4348} \text{x$\$$4349} \text{y$\$$4347}}{\left(\text{x$\$$4348}^2+\langle\langle 6\rangle\rangle ^2\right)^{\frac{3}{2}}}+\text{y$\$$4350}-\frac{\text{x$\$$4348}^2 \text{y$\$$4350}}{(\langle\langle 1\rangle\rangle +\langle\langle 1\rangle\rangle )^{\frac{3}{2}}}-\text{y$\$$4351}\right\}$ . Inconsistent equation dimensions.

What am I doing wrong?

Add, code in mathematica:

<< VariationalMethods`

L = 1/2 ((D[x[u, t], t]^2 + D[y[u, t], t]^2) - 
    (Sqrt[D[x[u, t], u]^2 + D[y[u, t], u]^2] - 1)^2)

eq = EulerEquations[L, {x[u, t], y[u, t]}, {u, t}]

cond = {x[0, t] == 0, x[1, t] == 1, y[0, t] == 0, y[1, t] == 0}

addcond = {x[u, 0] == u, y[u, 0] == 0, (D[L, D[x[u, t], t]] /. {t -> 10}) == 0, 
    (D[L, D[y[u, t], t]] /. {t -> 10}) == 0}

NDSolve[{eq, cond, addcond}, {x[u, t], y[u, t]}, {u, 0, 1}, {t, 0, 10}]
$\endgroup$
  • 3
    $\begingroup$ Please copy the actual code you used into your question in Mathematica format so that readers can copy and run it. $\endgroup$ – bbgodfrey Aug 30 '16 at 22:22
  • $\begingroup$ Welcome to Mathematica.SE! I hope you will become a regular contributor. To get started, 1) take the introductory tour now, 2) when you see good questions and answers, vote them up by clicking the gray triangles, because the credibility of the system is based on the reputation gained by users sharing their knowledge, 3) remember to accept the answer, if any, that solves your problem, by clicking the checkmark sign, and 4) give help too, by answering questions in your areas of expertise. $\endgroup$ – bbgodfrey Aug 30 '16 at 22:24
  • $\begingroup$ I added actual code. $\endgroup$ – qwe8013 Sep 2 '16 at 15:24
  • $\begingroup$ Euler's equations usually are solved as an initial value problem. Here, it is posed as a boundary value problem, with positions specified at t == 0 and velocities at t == 10. Is this intentional? With both defined at t == 0, the code runs fine. $\endgroup$ – bbgodfrey Sep 2 '16 at 16:38
  • $\begingroup$ You are right. I had to solve it as an initial value problem. But why mathematica can not solve a boundary value problem? $\endgroup$ – qwe8013 Sep 2 '16 at 17:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.