\documentclass[a4paper,french,12pt]{article}

\title{Analyse --- Exercices}
\author{}
\date{Dernière compilation~: \today{} à \currenttime}

\usepackage{../../cours}
\usepackage{enumitem}
\usepackage{xfrac}

\begin{document}

\maketitle

\section{Équations différentielles d'ordre 1}

    \paragraph{$(E_1)$}

        $y' - 2y = x^2$

        \begin{enumerate}[label=\alph*)]

            \item Solution homogène
                \begin{align*}
                    r = 2 \implies y_0 = \lambda e^{2x}
                \end{align*}

            \item Solution particulière
                \begin{align*}
                    \left\{
                    \begin{array}{l}
                        y_1 = ax^2 + bx + c \\
                        y_1' = 2ax + b \\
                    \end{array}
                    \right.
                \end{align*}
                \begin{align*}
                    y_1' - 2 y_1 = x^2
                    &\Leftrightarrow
                    2ax + b - 2(ax^2 + bx + c) = x^2 \\
                    &\Leftrightarrow
                    \left\{
                    \begin{array}{l}
                        -2a = 1 \\
                        2a - 2b = 0 \\
                        b - 2c = 0 \\
                    \end{array}
                    \right.
                    \Leftrightarrow
                    \left\{
                    \begin{array}{l}
                        a = \sfrac{-1}{2} \\
                        b = \sfrac{-1}{2} \\
                        c = \sfrac{-1}{4} \\
                    \end{array}
                    \right.
                \end{align*}
                \begin{align*}
                    \implies y_1 = -\frac{1}{2}x^2 -\frac{1}{2}x -\frac{1}{4}
                \end{align*}

            \item Solution générale
                \begin{equation*}
                    y = y_0 + y_1 = \boxed{-\frac{1}{2}x^2 -\frac{1}{2}x -\frac{1}{4} + \lambda e^{2x}}
                \end{equation*}

        \end{enumerate}

    \paragraph{$(E_2)$}

        $3y' - 9y = 7e^{3x}$

        \begin{enumerate}[label=\alph*)]

            \item Solution homogène
                \begin{align*}
                    r = 3 \implies y_0 = \lambda e^{3x}
                \end{align*}

            \item Solution particulière
                \begin{align*}
                    \left\{
                    \begin{array}{l}
                        y_1 = ax e^{3x} \\
                        y_1' = ae^{3x} + 3axe^{3x} = (3ax + a)e^{3x} \\
                    \end{array}
                    \right.
                \end{align*}
                \begin{align*}
                    3y_1' - 9y_1 = 7e^{3x}
                    &\Leftrightarrow 3(3ax + a)e^{3x} - 9axe^{3x} = 7e^{3x} \\
                    &\Leftrightarrow (9ax + 3a)e^{3x} - 9axe^{3x} = 7e^{3x} \\
                    &\Leftrightarrow 9ax + 3a - 9ax = 7 \\
                    &\Leftrightarrow 3a = 7 \\
                    &\Leftrightarrow a = \frac{7}{3}
                \end{align*}
                \begin{align*}
                    \implies y_1 = \frac{7}{3}xe^{3x}
                \end{align*}

            \item Solution générale
                \begin{equation*}
                    y = y_0 + y_1 = \lambda e^{3x} + \frac{7}{3}xe^{3x} = \boxed{(\frac{7}{3}x + \lambda)e^{3x}}
                \end{equation*}

        \end{enumerate}

    \paragraph{$(E_3)$}

        $2y' - 4y = 5e^{3x}$

        \begin{enumerate}[label=\alph*)]

            \item Solution homogène
                \begin{align*}
                    r = 2 \implies y_0 = \lambda e^{2x}
                \end{align*}

            \item Solution particulière
                \begin{align*}
                    \left\{
                    \begin{array}{l}
                        y_1 = ae^{3x} \\
                        y_1' = 3ae^{3x} \\
                    \end{array}
                    \right.
                \end{align*}
                \begin{align*}
                    2y_1' - 4y_1 = 5e^{3x}
                    &\Leftrightarrow 6ae^{3x} - 4ae^{3x} = 5e^{3x} \\
                    &\Leftrightarrow 2a = 5 \\
                    &\Leftrightarrow a = \frac{5}{2}
                \end{align*}
                \begin{align*}
                    \implies y_1 = \frac{5}{2}e^{3x}
                \end{align*}

            \item Solution générale
                \begin{equation*}
                    y = y_0 + y_1 = \boxed{\lambda e^{2x} + \frac{5}{2}e^{3x}}
                \end{equation*}

        \end{enumerate}

    \paragraph{$(E_4)$}

        $y' + 4y = 3\cos(2x)$

        \begin{enumerate}[label=\alph*)]

            \item Solution homogène
                \begin{align*}
                    r = -4 \implies y_0 = \lambda e^{-4x}
                \end{align*}

            \item Solution particulière
                \begin{align*}
                    \left\{
                    \begin{array}{l}
                        y_1 = a\cos(2x) + b\sin(2x) \\
                        y_1' = -2a\sin(2x) + 2b\cos(2x) \\
                    \end{array}
                    \right.
                \end{align*}
                \begin{align*}
                    y_1' + 4y_1 = 3\cos(2x)
                    &\Leftrightarrow -2a\sin(2x) + 2b\cos(2x) + 4(a\cos(2x) + b\sin(2x)) = 3\cos(2x) \\
                    &\Leftrightarrow
                    \left\{
                    \begin{array}{l}
                        4a + 2b = 3 \\
                        4b - 2a = 0 \\
                    \end{array}
                    \right.
                    \Leftrightarrow
                    \left\{
                    \begin{array}{l}
                        4a + 2b = 3 \\
                        4a - 8b = 0 \\
                    \end{array}
                    \right.
                    \Leftrightarrow
                    \left\{
                    \begin{array}{l}
                        10b = 3 \\
                        4b - 2a = 0 \\
                    \end{array}
                    \right. \\
                    &\Leftrightarrow
                    \left\{
                    \begin{array}{l}
                        b = \sfrac{3}{10} \\
                        a = \sfrac{12}{20} = \sfrac{3}{5} \\
                    \end{array}
                    \right.
                \end{align*}
                \begin{align*}
                    \implies y_1 = \frac{3}{5}\cos(2x) + \frac{3}{10}\sin(2x)
                \end{align*}

            \item Solution générale
                \begin{equation*}
                    y = y_0 + y_1 = \boxed{\lambda e^{-4x} + \frac{3}{5}\cos(2x) + \frac{3}{10}\sin(2x)}
                \end{equation*}

        \end{enumerate}

\section{Équations différentielles d'ordre 2}

\end{document}
