###### tags: `fiche` `S1` `maths`
<div style="display: flex; justify-content: space-between;">
<span>Version 1.1.0</span>
<span>2020/11/22</span>
</div>
<div style="height:25em"></div>
<div style="text-align:center">
<h1 style="font-size:3.5em;line-height: 2.5;">S1 Maths - Arithmetics in R[x] : Cours</h1>
<div>
Adam Alani <a href="mailto:adam.alani@epita.fr"><adam.alani@epita.fr></a> <br>
Jules Lefebvre <a href="mailto:jules.lefebvre@epita.fr"><jules.lefebvre@epita.fr></a>
</div>
</div>
<div style="height:25em"></div>
----
[TOC]
----
# 1. Polynomial
Let $\mathbb K$ a corps, $\forall n \in \mathbb N , (a_0 , ... , a_n) \in \mathbb K^{n+1}$
A polynomial is an expression of the form:
$$
P(X) = a_0 + a_1X + \cdots + a_nX^n \\
= \sum_{i=0}^{n} a_iX^i
$$
A polynomial is defined by its coefficients $(a_0, \cdots , a_n)$. Formally, a polynomial is defined as a sequence with a finite number of non-null terms corresponding to the coefficients $(a_0 , \dots , a_n)$
## 1.1. Notations
$\mathbb K[x]$ is the set of polynomials with $\mathbb K$ coefficients.
$$
\mathbb K[x] = \{P(X) = \}
$$
## 1.2. Example
$\mathbb R[X]$ is the sel of all the polynomials with reel coefficents.
$$
\begin{align}
X^3 + 2X - 1 &\in \mathbb R[x] \\
\mathbb R[x] &\subset \mathbb C[x]
\end{align}
$$
# 2. Degree
The degree of a polynomial is the highest of the degrees of its monomial (individual terms) with non-zero coefficients. It's denoted $d^\circ P$.
$$
P(X) = \sum_{i=0}^n a_i X^n | a_n \ne 0 \implies d^\circ(P) = n
$$
By convention $d^\circ(0) = -\infty$. This convention is useful to simplify the operations on polynomial's degrees.
### Examples
$$
\begin{align}
d^\circ(3) &= 0 \\
d^\circ(2x) &= 1\\
d^\circ((X+1)^2) &= 2
\end{align}
$$
## 2.1. Properties
Let $(P, Q) \in (\mathbb R[X])^2, (\lambda, n) \in \mathbb R \times \mathbb N$
$$
\begin{align}
d^\circ\left(\frac{dP}{dx}\right) &= \begin{cases}
-\infty & \text{if } d^\circ(P) \le 1 \\
d^\circ(P) - 1 & \text{if } d^\circ(P) > 1
\end{cases} \\
\\
d^\circ(P+Q) &\begin{cases}
= \max(d^\circ(P), d^\circ(Q)) & \text{if } d^\circ(P) \ne d^\circ(Q)\\
\le \max(d^\circ(P), d^\circ(Q)) & \text{if } d^\circ(P) = d^\circ(Q)\\
\end{cases} \\
\\
d^\circ(\lambda P) &= \begin{cases}
-\infty & \text{if } \lambda = 0 \\
d^\circ(P) & \text{if } \lambda \ne 0 \\
\end{cases}\\
\\
d^\circ(P^n) &= d^\circ(P) \times n \\
\end{align}
$$
## 2.2. Notation
$\mathbb R_n[x]$ is the set of all the polynome with a degree less or equal to $n$.
$$
\mathbb R_n[x] = \{P \in \mathbb R[x] | d^\circ(P) \le n \}
$$
### Examples
$$
\begin{align}
(x+2)^3 \in \mathbb R_3[x] &\rightarrow \mathbb R_2[x] \subset \mathbb R_3[x] \\
X + 1 \in \mathbb R_3[x] &\rightarrow X^2 + i \not\subset\mathbb R_2[x] \\
X^4 \not\in \mathbb R_3[x] &\rightarrow \mathbb R_2[x] \subset \mathbb C_2[x]
\end{align}
$$
**Operations in R[x]**
Let $(P , Q) \in R[x]^2$ such that
$P = \sum_{k=0}^{n} a_kX^k \qquad Q = \sum_{k=0}^{n}b_kX^k$
Then we have:
- $P = Q$ if and only if there exists k [| 0 , n |] , $a_k = b_k$
Useful to switch from an equation with polynomials to an equation with coefficients
- $P + Q = Q + P = \sum_{k=0}^n (a_k +b_k) X^k \text{and} \\
(P + Q) + R = P + (Q+R)$
- $\lambda P = \sum \lambda_{k=0}^n a_k X^k$
- $(PQ)R = P(QR)$
- $P(Q+R) = PQ + PR$
Remark:
Additions and multiplications are performed in a very intuitive way, but! you **MAY NOT divide polynomials!**