Solving Linear Differential Systems I have no knowledge about solving these type of problems.
Neither youtube or the other websites have anything about it.
Could you help me ?
$x' - y' - 2x + 4y = t$
$x' + y' -x - y = 1$
 A: The first step is to get the system into the form $\vec{x}' = A\vec{x} + \vec{g}(t)$, where $\vec{x} = \begin{bmatrix}x\\y\end{bmatrix}$ and $A$ is a matrix.
If we add the two equations together, we get that $2x' - 3x + 3y = t+1$, which we can rearrange to get $x' = \dfrac{3}{2}x - \dfrac{3}{2}y + t + 1$.
Similarly, if we subtract the first equation from the second, we get $2y' + x - 5y = 1 - t$, which can be rearranged to get $y' = -\dfrac{1}{2}x+\dfrac{5}{2}y-t+1$.
These two equations can be rewritten as $\vec{x}'=\begin{bmatrix}\dfrac{3}{2}&-\dfrac{3}{2}\\-\dfrac{1}{2}&\dfrac{5}{2}\end{bmatrix}\vec{x}+\begin{bmatrix}t+1\\-t+1\end{bmatrix}$.
This is still a linear equation, so the principle of superposition applies. So, first we will look for solutions to the complementary equation, $\vec{x}' = \begin{bmatrix}\dfrac{3}{2}&-\dfrac{3}{2}\\-\dfrac{1}{2}&\dfrac{5}{2}\end{bmatrix}\vec{x}$.
Like with the equations you've studied in the past, it makes sense here to assume that the solution should be exponential because the derivative is some kind of multiple of the original function.
So, let's assume the form $\vec{x} = \vec{\eta}e^{rt}$, where $\vec{\eta}$ is constant. Taking the derivative gives us $\vec{x}' = r\vec{\eta}e^{rt}$, so plugging this into our equation gives us $r\vec{\eta}e^{rt} = A\cdot(\vec{\eta}e^{rt})$.
We can take advantage of the linearity of matrix multiplication by pulling out our scalar $e^{rt}$, yielding $e^{rt} \cdot r\vec{\eta} = e^{rt} \cdot A\vec{\eta}$. The exponential function is never zero, so we can divide both sides by $e^{rt}$ to get $r\vec{\eta} = A\vec{\eta}$. In linear algebra terminology, this means that $r$ must be an eigenvalue of $A$, and $\vec{\eta}$ is a corresponding eigenvector.
Now let's do some linear algebra. If $r\vec{\eta} = A\vec{\eta}$, then $A\vec{\eta}-r\vec{\eta} = \vec{0}$. Because matrix multiplication is distributive, we can rewrite this as $(A - rI)\vec{\eta} = \vec{0}$, where $I$ is the identity matrix.
$\vec{\eta} = \vec{0}$ is a trivial solution to this equation for any $A$ and $r$, but it's not very helpful because this would lead to $\vec{x} = \vec{0}$, a trivial solution to our original equation. So, we only want solutions with $\vec{\eta} \neq \vec{0}$. By the Invertible Matrix Theorem, this means that our matrix $(A - rI)$ must be non-invertible, which implies that $det(A - rI) = 0$, and conversely, if $det(A - rI) = 0$, then there is some non-zero $\vec{\eta}$ such that $(A - rI)\vec{\eta} = \vec{0}$.
So, the eigenvalues of $A$ are all of the values of $r$ such that $det(A - rI) = 0$:
$$\begin{vmatrix}\dfrac{3}{2}-r & -\dfrac{3}{2} \\-\dfrac{1}{2} &\dfrac{5}{2} - r\end{vmatrix} = 0 \to (r - \dfrac{3}{2})(r - \dfrac{5}{2}) - \dfrac{3}{4} = 0 \to r^2 - 4r + 3 = 0 \to r_1 = 1, r_2=3$$.
Now we need to find the corresponding eigenvectors. For $r_1 = 1$:
$$(A - rI)\vec{\eta} = \vec{0} \to \begin{bmatrix}\dfrac{1}{2} & -\dfrac{3}{2} \\-\dfrac{1}{2} &\dfrac{3}{2}\end{bmatrix}\begin{bmatrix}\eta_1\\ \eta_2\end{bmatrix}=\begin{bmatrix}0\\0\end{bmatrix}\to\dfrac{1}{2}\eta_1 - \dfrac{3}{2}\eta_2 = 0 \to \eta_1 = 3\eta_2$$
This equation has infinite solutions, but since we're going to multiply by an arbitrary constant later, we just need one. I typically like to let the smaller entry be $1$, so $\vec{\eta}_1 = \begin{bmatrix}3\\1\end{bmatrix}$.
Solving similarly for $r_2 = 3$ gives us $\vec{\eta}_2 = \begin{bmatrix}1\\-1\end{bmatrix}$. We are now ready to write our complementary solution:
$$\vec{x}_c = c_1\begin{bmatrix}3\\1\end{bmatrix}e^t + c_2\begin{bmatrix}1\\-1\end{bmatrix}e^{3t}$$
Now we just need to find our particular solution. Just like with a single equation, we can do this with the method of variation of parameters, although the procedure is a bit more complicated. Let's define the fundamental matrix of the system, $Y$, as the matrix where each column of the matrix is one of our homogeneous solutions. It follows from that definition and the definition of the homogeneous solutions that $Y' = AY$.
Now, let's define $\vec{y}_p = Y\vec{u}$ for some vector-valued function $\vec{u}$. From the product rule, $\vec{y}_p' = Y'\vec{u} + Y\vec{u}'$. Plugging this into our equation:
$$Y'\vec{u} + Y\vec{u}'= A(Y\vec{u}) + \vec{g}(t) \to (AY)\vec{u} + Y\vec{u}' = A(Y\vec{u}) + \vec{g}(t)$$
Matrix multiplication is associative, so $(AY)\vec{u} = A(Y\vec{u}),$ and by subtracting that from both sides it follows that $Y\vec{u}' = \vec{g}(t)$ and $\vec{u}' = Y^{-1}\vec{g}(t)$, provided that $Y$ is invertible, which follows from the linear independence of the fundamental solutions. (and my precious Invertible Matrix Theorem)
Here, we have $Y = \begin{bmatrix}3e^t&e^{3t}\\e^t&-e^{3t}\end{bmatrix}$. Sparing the details, we then have:
$$Y^{-1} = \begin{bmatrix}\dfrac{1}{4}e^{-t}&\dfrac{1}{4}e^{-t}\\\dfrac{1}{4}e^{-3t}&-\dfrac{3}{4}e^{-3t}\end{bmatrix}, \vec{u}' = \begin{bmatrix}\dfrac{1}{2}e^{-t}\\te^{-3t}-\dfrac{1}{2}e^{-3t}\end{bmatrix}, \vec{u} = \begin{bmatrix}-\dfrac{1}{2}e^{-t}\\\dfrac{-6t+1}{18}e^{-3t}\end{bmatrix}, \vec{y}_p = \begin{bmatrix}\dfrac{1}{3}t - \dfrac{13}{9}\\ -\dfrac{1}{3}t - \dfrac{5}{9}\end{bmatrix}$$
Note that we can neglect the constants when integrating $\vec{u}'$ to get $\vec{u}$ because any additional constant would simply lead to an additional term of the same form as our complementary solution, so it would essentially just correspond to different values for our arbitrary constants in the complementary solution.
So, our final solution is $\vec{x}=c_1\begin{bmatrix}3\\1\end{bmatrix}e^t + c_2\begin{bmatrix}1\\-1\end{bmatrix}e^{3t}+\begin{bmatrix}\dfrac{1}{3}t - \dfrac{13}{9}\\ -\dfrac{1}{3}t - \dfrac{5}{9}\end{bmatrix}$
A: If we add the two equations, we get
$$x' = \dfrac{1}{2}\left(3x - 3 y + t + 1\right)$$
If we subtract the first from the second, we get
$$y' = \dfrac{1}{2}\left(-x + 5 y - t + 1\right)$$
We can write this as the non-homogeneous system, $X' = AX + f$ as
$$\begin{bmatrix} x' \\ y' \end{bmatrix} = \dfrac{1}{2}\begin{bmatrix} 3 & -3 \\ -1 & 5 \end{bmatrix} \begin{bmatrix} x \\ y \end{bmatrix} + \begin{bmatrix} t+1 \\ -t+1 \end{bmatrix} $$
