Problems solving a nonlinear PDE

94 Views Asked by At

I'm working on a problem where I want to find the function $f(r,\theta)$ that minimizes the following integral: $$ I=\int_{0}^{\pi/4}{\int_{a/\cos\theta}^{b/\cos\theta}{\left(A\sqrt{1+\left(\frac{\partial f(r,\theta)}{\partial r}\right)^2+\frac{1}{r^2}\left(\frac{\partial f(r,\theta)}{\partial \theta}\right)^2}+B+C\left(D-f(r,\theta)\right)\right)rdrd\theta}} $$ Where $A,B,C$ and $D$ are constants. Applying the Euler-Lagrange equation to it for the case where the functional contains a single function of several variables, I get the following nonlinear PDE for the stationary condition: $$ \frac{r^2f_{,rr}+rf_{,r}+f_{,\theta\theta}}{r\sqrt{1+f_{,r}^2+\frac{f_{,\theta}^2}{r^2}}}-\frac{\left[r^2f_{,r}\left(f_{,r}f_{,rr}+\frac{f_{,\theta}f_{,r\theta}}{r^2}-\frac{f_{,\theta}^2}{r^3}\right)+f_{,\theta}\left(f_{,r}f_{,r\theta}+\frac{f_{,\theta}f_{,\theta\theta}}{r^2} \right)\right]}{r\left(1+f_{,r}^2+\frac{f_{,\theta}^2}{r^2}\right)^{3/2}} = \frac{C}{A}r $$ Which does not look pretty at all. Since my experience with PDEs is very small, I tried to program a code to solve it by the finite difference method adopting a Newton scheme to solve the nonlinear system. However, I'm getting some inconsistencies in the results, even with finer meshes and more iterations in the Newton scheme (which is converging). For example, I may get: enter image description here

Which clearly has some problems (it was suppose to be a smooth function) that change the position with the discretization number and other variables. I've checked all the equations and the programming with other solutions and it seems right. I believe that if this is the right path to go, maybe my discretization in the $r$ direction could be wrong since it depends on $\theta$ and I just made a rectangular grid (which covers the dependence on $\theta$).

My point is, should I look for another method to solve it numerically? If so, could anyone provide me what should I learn to solve this nonlinear PDE? Any hint will be truly appreciated. Thank you in advance.

EDIT: The only boundary conditions that I have is that at $f(a/\cos\theta,\theta)=0$ and $f(b/\cos\theta,\theta)=H$, since I'll need more BCs I thought about estimate an initial value for $f_{,\theta}(r,0)$ and $f_{,\theta}(r,\pi/4)$ which can be handled later. Is it possible to solve the PDE this additional BCs using a mix between Neumann and Dirichlet conditions adopting a finite difference scheme?