Example 1. Solve the system by the method of variation of parameters

$$
\left\{\begin{array}{l}
\frac{d x}{d t}=-2 x-4 y+1+4 t \\
\frac{d y}{d t}=-x+y+\frac{3}{2} t^{2}
\end{array}\right.
$$
Solution. First, we solve the corresponding homogeneous system

$$
\left\{\begin{array}{l}
\frac{d x}{d t}=-2 x-4 y \\
\frac{d y}{d t}=-x+y
\end{array}\right.
$$

From the second equation of the system (8) we have

$$
x=y-\frac{d y}{d t}, \quad \text { so } \frac{d x}{d t}=\frac{d y}{d t}-\frac{d^{2} y}{d t^{2}}
$$

Substituting these expressions for $x$ and $\frac{d x}{d t}$ into the first equation of the system (8):

$$
\frac{d^{2} y}{d t^{2}}+\frac{d y}{d t}-6 y=0
$$

The general solution of this equation is

$$
y=C_{1} e^{2 t}+C_{2} e^{-3 t}
$$

Since $x=y-\frac{d y}{d t}$, we will have

$$
x=-C_{1} e^{2 t}+4 C_{2} e^{-3 t}
$$

The general solution of the homogeneous system (8) is

$$
x=-C_{1} e^{2 t}+4 C_{2} e^{-3 t}, \quad y=C_{1} e^{2 t}+C_{2} e^{-3 t}
$$

The solution of the non-homogeneous system (7) is sought in the form

$$
x=-C_{1}(t) e^{2 t}+4 C_{2}(t) e^{-3 t}, \quad y=C_{1}(t) e^{2 t}+C_{2}(t) e^{-3 t}
$$

Substituting (9) into (7) and combining like terms, we get

$$
\left\{\begin{aligned}
-C_{1}^{\prime}(t) e^{2 t}+4 C_{2}^{\prime}(t) e^{-3 t} & =1+4 t \\
C_{1}^{\prime}(t) e^{2 t}+C_{2}^{\prime}(t) e^{-3 t} & =\frac{3}{2} t^{2}
\end{aligned}\right.
$$

from which

$$
C_{1}^{\prime}(t)=\frac{\left(6 t^{2}-4 t-1\right) e^{-2 t}}{5}, \quad C_{2}^{\prime}(t)=\frac{\left(3 t^{2}+8 t+2\right) e^{3 t}}{10}
$$

Integrating, we find

$$
\begin{aligned}
& C_{1}(t)=-\frac{1}{5}\left(t+3 t^{2}\right) e^{-2 t}+C_{1} \\
& C_{2}(t)=\frac{1}{10}\left(2 t+t^{2}\right) e^{3 t}+C_{2}
\end{aligned}
$$

where $C_{1}$ and $C_{2}$ are arbitrary constants. Substituting (10) into (9), we get the general solution of the system (7)

$$
x=-C_{1} e^{2 t}+4 C_{2} e^{-3 t}+t+t^{2}, \quad y=C_{1} e^{2 t}+C_{2} e^{-3 t}-\frac{1}{2}+t^{2}
$$

## Problems for Independent Solution

Find the general solution of the following linear non-homogeneous systems using the method of variation of arbitrary constants:

812. $\left\{\begin{array}{l}\frac{d x}{d t}=-2 x+y-e^{2 t}, \\ \frac{d y}{d t}=-3 x+2 y+6 e^{2 t} .\end{array}\right.$
813. 

$$
\left\{\begin{array}{l}
\frac{d x}{d t}=x+y-\cos t \\
x(0)=1 \\
\frac{d y}{d t}=-y-2 x+\cos t+\sin t \\
y(0)=-2
\end{array}\right.
$$

814. $\left\{\begin{array}{l}\frac{d x}{d t}=y+\operatorname{tg}^{2} t-1, \\ \frac{d y}{d t}=\operatorname{tg} t-x .\end{array}\right.$
815. $\left\{\begin{array}{l}\frac{d x}{d t}=-4 x-2 y+\frac{2}{e^{t}-1}, \\ \frac{d y}{d t}=6 x+3 y-\frac{3}{e^{t}-1} .\end{array}\right.$
816. $\left\{\begin{array}{l}\frac{d x}{d t}=y, \\ \frac{d y}{d t}=-x+\frac{1}{\cos t} \text {. }\end{array}\right.$

$2^{\circ}$. Method of undetermined coefficients (method of trial). This method is used to solve non-homogeneous systems of linear equations when the functions $f_{i}(t)$ on the right-hand side of the system have a special form: polynomials $P_{k}(t)$, exponential functions $e^{\alpha t}$, sines and cosines $\sin \beta t, \cos \beta t$ and products of these functions. We will illustrate this method with examples.