Not sure what is wrong with the boundary conditions for this problem:

NDSolve[{D[u[x, y], x, x] + D[u[x, y], y, y] - 
    u[x, y] == -DiracDelta[x, y], u[10, y] == 0, u[x, 10] == 0, 
  u[-10, y] == 0}, u, {x, 0, 10}, {y, 0, 10}].

The error message is:

NDSolve::ivone: Boundary values may only be specified for one independent variable. Initial values may only be specified at one value of the other independent variable.

  • 2
    $\begingroup$ There are two problems: Mathematica doesn't support elliptic PDEs. Please see here. Some of this is explained if you click the >> after the error message. The other problem (which is not the cause of the error) is that you can't (it doesn't make sense to) use DiracDelta in a numerical method. $\endgroup$
    – Szabolcs
    Commented Feb 5, 2013 at 17:19
  • $\begingroup$ @Yong, could you explain a bit what you wanted to achieve? Then, perhaps, there may be a solution. $\endgroup$
    – user21
    Commented Feb 5, 2013 at 19:28

1 Answer 1


Mathematica does not support the numerical solution of elliptic PDEs. This is explained here. It is also mentioned in the page that opens if you click the >> after the error message. It only supports initial value problems.

Another problem with your input is the use of DiracDelta. It doesn't make sense to use this function in a numerical method. But this is not the cause of the error message.

  • $\begingroup$ Are you aware any Methmatica tool for this type of problem? It appears DSolve works for a similar 1-D problem with a delta function $\endgroup$
    – Yong
    Commented Feb 5, 2013 at 18:56
  • $\begingroup$ Hi Ruebenko, what we are trying to solve is a steady-state 2-D diffusion equation with a "decay term", -u[x,y] and a generation term at the orgin x = y = 0, -DiracDelta[x, y]. I understand the comment of Szabolcs regarding the delta-function. It can be replaced by a highly localizaed fucntion. If Mathematica can only handel an initial value problem, we could perhaps set it up as a time-dependent problem and later let t becomes very large. I am puzzled about how to set-up the boundary conditions. ">>" does not explain it well (sometime showing nothing). Thanks! $\endgroup$
    – Yong
    Commented Feb 8, 2013 at 14:29

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.