# Are boundary conditions required between subdomains of 1D PDE?

I am using finite difference software to solve across 1D line from x=0 to x=1 (left Domain), and x=1 to x=2 (middle/central domain) and x=2 to x=3 (right domain). The only difference between domains is that the central domain posses a source term.

I have a Left hand domain where \begin{equation} u_t(x,t) - u_{xx}(x,t) = 0 \text{ where $x\in\mathbb{R}$ and $t>0$} \end{equation}

And then a domain in the middle \begin{equation} u_t(x,t) - u_{xx}(x,t) = S \text{ where $x\in\mathbb{R}$ and $t>0$ and $S>0$} \end{equation}

And then a third right hand domain:

\begin{equation} u_t(x,t) - u_{xx}(x,t) = 0 \text{ where $x\in\mathbb{R}$ and $t>0$} \end{equation}

Boundary conditions are required at the start and end of the 1D line.

Are boundary conditions required between the domains, or can I just change the value of S to be nonzero in the middle and have no boundary conditions surrounding the central subdomain? If there are no central subdomain boundary conditions is the solutions approximately correct? Does the same principle apply to 2D and 3D pdes?

• You may want to apply some regularization as an enforced step change in partial derivatives can create unwanted effects between domains. Jun 25, 2018 at 9:30
• If not using any kind of regularization, then the effects can be catastrophic for any discrete solver. I am afraid I don't have any good book reference but I am sure there should exist many. Jun 25, 2018 at 10:03
• You could get equation system close to positive semi-definite and the solution in directions which are completely unrealistic could get norm growing completely out of control. Jun 25, 2018 at 10:05
• Yes if you miss regularization terms convergence can still give really unrealistic solutions. Imagine you try to solve an underdetermined system. There is then freedom for completely unregulated linear combinations to grow anywhere they want. Jun 26, 2018 at 8:45
• Maybe I can show example in answer some day after work. Jun 26, 2018 at 8:55

Note This is not intended to answer the question but to help understand the importance of regularization when solving differential equations using numerical schemes.

Assume we have a 2D grid with cartesian coordinates $(x,y)$ and for some reason we want to solve the function which minimizes the gradient of a scalar potential field $\phi(x,y)$ everywhere $$\min\int_\mathcal S \|\nabla \phi(x,y)\|_FdS$$ where dS is some small quadratic area element in $x$ and $y$. Given some boundary functions, say for example $\phi(x,y) = f(x,y)$ on $\mathcal C$.

Furthermore assume we make a discretization of our differential operators:

$$\nabla = \left[\frac \partial {\partial x},\frac \partial {\partial y}\right]^T : d_x = \left[\begin{array}{rr}1&-1\\1&-1\end{array}\right], d_y = \left[\begin{array}{rr}-1&-1\\1&1\end{array}\right]$$

finally we try to solve this with a big linear least squares problem:

$$\min\left\{\left\|\nabla \phi(x,y)\right\|_F^2+\left\|{\bf C}(\phi(x,y)-f(x,y))\right\|_F^2\right\}$$ Where C encodes the areas where the boundary function should hold (err.. the boundary, in other words).

Our first attempt, without any additional term, gives us a somewhat weird result..: (boundary areas $\mathcal C$ are inner circle and rectangular frame.) We can see very visible chessboard patterns in the solution. However if we add a small regularizing term with filter $h = \left[\begin{array}{rr}-1&1\\1&-1\end{array}\right]$ we see we can get a much more naturally smooth solution: • Thanks for sparing the time to clarify your comments. This is a useful demonstration.
– SPIL
Jul 1, 2018 at 21:45