# Polynomials

(from *"A Programmer's introduction to Mathematics" - Jeremy Kun, 2018*)

## Definition

A **single variable polynomial with real coefficients** is a function $$f$$ that takes a real number as input, produces a real number as output, and has the form:

$$\displaystyle f(x) = a*n x^n + a*{n-1} x^{n-1} + \cdots + a*2 x^2 + a\_1 x^1 + a\_0 x^0 \ \qquad = a\_n x^n + a*{n-1} x^{n-1} + \cdots + a\_2 x^2 + a\_1 x  + a\_0

$$$
where $$a\_i$$ are real numbers, called the **coefficients** of $$f$$. The **polynomial's degree** of the polynomial is the integer $$n:n \in \mathbb{N}$$.

$$\displaystyle f(x) = \sum\_{i=0}^n a\_i x^i
$$$

It is a summation of terms, enumerated with $$i=(0..n)$$, where each $$i^{th}$$ term consisting of a constant $$a\_i$$ multiplied with the variable $$x$$ raised to the $$i^{th}$$ power, $$x^i$$.

The definition mentions 3 things: 1. a polynomial with real coefficients, i.e. a function $$f$$ 2. coefficients $$a\_i$$, i.e. an array of reals $$\[a\_0,\cdots,a\_n]$$ 3. a polynomial's degree, i.e. a natural number $$n$$

> The concept of a polynomial is a bit more general: it is any function of a single numeric input that can be expressed using only addition and multiplication and constants.

**Example**\
If $$g$$ is the function name, $$t$$ is the input (variable) name, $$b\_i$$ is an array of coefficients defined as $$\[2,0,4,−1]$$ and $$n=3$$ is the degree of the polynomial. By definition, the polynomial $$g$$ has the form:

$$\displaystyle g(t) = 2 + 0t + 4t^2 + (−1)t^3 \ \quad  = 2 + 4t^2 − t^3

$$

A polynomial, like a function, can be represented as a set of ordered pairs, sometimes called *points* - pairing each input with its output we can obtain a set of tuples which we can plot. A polynomial's graph, plotted as a curve in space, will reveal an interesting property: the number of curvey direction-changes depends on a polynomial's degree.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://mandober.gitbook.io/math-debrief/400-abstract-algebra/terms/polynomials.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
