# Solutions to differential equation with differentiation with respect to two variables

I am attempting to numerically solve the following differential equation that includes differentiation with respect to two variables with two separate boundary conditions.

$y^{\prime\prime}(x) + \frac{3}{x}y^{\prime}(x) = \frac{dU}{dy}; y(\infty) = 0,\ y^{\prime}(0) = 0, U(y) = \frac{1}{4}y^{4}(\gamma +\alpha\ln^{2}y + \beta\ln^{4}y),$

where ${}^{\prime}$ indicates differentiation with respect to $x$.

Here is my attempt thus far is:

U[y_] = 1/4 y^{4}*({\[Gamma] + \[Alpha]*(Log[y/Mp])^{2} + \[Beta]*(Log[y/Mp])^{4}});
eqn = D[y[x], {x, 2}] + 3 D[y[x], x]/x - U'[y[x]] == 0;
NDSolve[{eqn, y[100] == 0, y'[0.1] == 0}, y[x], {x, 0, 100}]


The value of the constants in the equation are as follows:

Mp = 2.435*10^18;
\[Alpha] = 1.4*10^-5;
\[Beta] = 6.3*10^-8;
\[Gamma] = -0.013;
\[Lambda]6 = 0;


But unfortunately I receive the following error messages:

Power: Infinite expression 1/0 encountered.

Any help on this matter would be greatly appreciated.

Update: I feel this might be possible to solve via a shooting method but I am unsure how to implement this.

• Define $U(y)$ as just a function of $y$, U[y_]=, and then write U'[y[x]] in eqn. That'll fix the first issue, but you still have a problem with U'(y) being undefined when y=0, which you have at the right boundary condition. – KraZug Mar 20 '18 at 16:36
• It's always good to give all coefficients. – user21 Mar 21 '18 at 8:36

Something like this works:

Mp = 1;
\[Beta] = 1;
\[Alpha] = 1;
\[Gamma] = 1;
left = 10^-6;
U[y_] := 1/
4 y^4*(\[Gamma] + \[Alpha]*Log[y/Mp]^2 + \[Beta]*Log[y/Mp]^4);
eqn = D[y[x], {x, 2}] + 3 D[y[x], x]/x - D[U[y[x]], x] == 0;
NDSolveValue[{eqn, y[100] == 0, y'[left] == 10^-4},
y[x], {x, left, 100}]

• Thank you for your response, but the values for the constants are Mp = 2.435*10^18; [Alpha] = 1.4*10^-5; [Beta] = 6.3*10^-8; [Gamma] = -0.013; [Lambda]6 = 0; – Ben Leather Mar 21 '18 at 10:16
• Hence this method still doesn't give me a very good solution. I think it might be possible by a shooting method but I'm unsure how this is implemented. I have no edited my question above. – Ben Leather Mar 21 '18 at 10:17