3 Boundary value problem
Usually some differential equation problems requires some condition that are not defined at the initial time t=0 of the time axes, but in a more general point t=t^\star: in order to solve this problem a parametric approach is recomended. As example let’s consider the following problem:
\left\{ \begin{aligned} x''(t) + y'(t) &= \sin(t) \\ y'(t) + x'(t) &= 1 + \sin(t) \\ x(0) &= 0 , \quad y(0) = -1,\quad x(1) = 1 \end{aligned} \right.
As we can see the last condition constrains the solution x(t),y(t) at the time t=1; in order to solve the problem in the Laplace domain we apply the transform on the system of differential equation and so
\left\{ \begin{aligned} s^2 \hat x(s) - x'(0) - s x(0) + s\hat y(s) - y(0) & = \frac 1 {s^2+1} \\ s \hat y(s) - y(0) + s\hat x(s) - x(0) &= \frac 1 s + \frac{1}{s^2+1} \end{aligned} \right.
If we now try to substitute the boundary condition on the problem we can see that we have no information for x'(t) at the initial time: the idea now is to solve the problem parametrically (assign a variable, in this case A, to the initial condition x'(0) ) and solve the problem this way. At the and we have to find the constant value A such that x(1) = 1. So by substituting we get
\left\{ \begin{aligned} s^2 \hat x(s) - A + s\hat y(s) +1 & = \frac 1 {s^2+1} \\ s \hat y(s) +1 + s\hat x(s) & = \frac 1 s + \frac{1}{s^2+1} \end{aligned} \right.
To simplify the calculation of the algebraic solution of the functions \hat x,\hat y we rewrite the system in matrix form that, by inversion, can determine the solutions (by using the Kramer method):
\begin{aligned} \begin{bmatrix} s^2 & s \\[1em] s & s \end{bmatrix} \begin{pmatrix} \hat x(s) \\[1em] \hat y(s) \end{pmatrix} & = \begin{pmatrix} \dfrac{1}{s^2+1} + A - 1 \\[1em] \dfrac{1}{s} + \dfrac{1}{s^2+1} - 1 \end{pmatrix} \\[1em] \implies \qquad \hat x(s) & = \dfrac{\det\begin{bmatrix} \dfrac{1}{s^2+1} + A - 1 & s \\[1em] \dfrac{1}{s} + \dfrac{1}{s^2+1} - 1 & s\end{bmatrix} } {\mathrm{det}\begin{bmatrix} s^2 & s \\[1em] s & s \end{bmatrix}} = \dfrac{sA - 1}{s^2(s-1)} \end{aligned}
Having the boundary condition set on x(t), our focus is to invert only the related transform \hat x(s) (because, for the sake of the problem, it’s not relevant determining y(t) ); by doing the parametric partial fraction expansion we have
\frac{sA - 1}{s^2(s-1)} = \frac{c_1}{s-1} + \frac{c_2}{s} + \frac{c_3}{s^2}
where, by solving the linear system, the coefficients are equals to c_1 = A-1, c_2 = 1-A and c_3 = 1. At this point we have everything in order to compute the inverted function of \hat x(s):
x(t) = \mathscr{L}^{-1}\{\hat x(s)\}(t) = (A-1)\mathrm{e}^t + (1-A) + t
The last thing to do now is to evaluate the function x(t) at the time t=1 and equal the result to 1 in order to determine the coefficient A related to the initial first derivative of x:
x(1) = (A-1) e + (1-A) + 1 = 1 \qquad \implies \quad A = 1
Example 3.1 (boundary value problem) Considering the parametric differential equation problem depending on the parameter A\in\Bbb{R} \left\{ \begin{aligned} x''(t) - x'(t) &= t \\ x(0) &= 1 \\ x'(0) &= A \end{aligned} \right.
the solution can be found in the Laplace domain; starting off with the transformation of the problem using the \mathscr L operator we have that
\begin{aligned} \mathscr{L}\{x''(t)\}(s) &= s^2 \hat x(s) - x'(0) - s x(0) \\ \mathscr{L}\{x'(t)\}(s) &= s \hat x(s) - x(0) \\ \mathscr{L}\{t\}(s) &= \dfrac{1}{s^2} \end{aligned}
\mathscr{L}\{x''(t) - x'(t) = t\}(s) \quad \mapsto \quad s^2 \hat x(s) - A - s -s\hat x(s) +1 = \frac{1}{s^2}
Solving this expression for \hat x(s) and performing the partial fraction expansion on the result (whose computation is here skipped) we obtain
\begin{aligned} \hat x(s) & = \frac{\frac 1 {s^2} + s + A - 1}{s^2-s} = \frac{s^3 + As^2 - s^2 + 1}{s^3(s-1)} \\ & = \frac{A+1}{s-1} - \frac A s - \frac 1 {s^2} - \frac 1 {s^3} \end{aligned}
If we now want to compute the parameter A such that x(1) = - \frac 1 2 we need to invert \hat x(s) in order to have the solution in the time domain. Considering so that
\begin{aligned} \mathscr{L}^{-1}\left\{\frac{1}{s-1}\right\}(t) & = \mathrm{e}^t \\ \mathscr{L}^{-1}\left\{\frac 1 s\right\}(t) &= 1 \\ \mathscr{L}^{-1}\left\{\frac 1 {s^2}\right\}(t) & = t \\ \mathscr{L}^{-1}\left\{ \frac 1 {s^3}\right\}(t) & = \frac {t^2}{2!} \end{aligned}
and so
\begin{aligned} x(t) & = \mathscr{L}^{-1}\left\{\hat x(s)\right\}(t) = (A+1)\mathrm{e}^t - A - t -\frac {t^2}2 \\ x(1) & = (A+1) e - A - 1 - \frac{1}{2} = -\frac{1}{2} \end{aligned}
Solving the equation we retrieve the value of A that’s -1.