# Nakafa Learning Content

> For AI agents: use [llms.txt](https://nakafa.com/llms.txt) for the site index. Markdown versions are available by appending `.md` to content URLs or sending `Accept: text/markdown`.

URL: https://nakafa.com/en/subjects/mathematics/polynomial/polynomial-graph
Source: https://raw.githubusercontent.com/nakafaai/nakafa.com/refs/heads/main/packages/contents/material/lesson/mathematics/polynomial/polynomial-graph/en.mdx

Learn polynomial graphing with point plotting, end behavior analysis, and visual patterns. Learn to sketch linear, quadratic, and cubic graphs one step at a time.

---

## Graphing Polynomial Functions

The graph of a polynomial function provides a visual representation of how the function's value changes as the input value $$x$$ changes. The shape of this graph can vary greatly depending on the degree and coefficients of the function.

Visible text: The graph of a polynomial function provides a visual representation of how the function's value changes as the input value changes. The shape of this graph can vary greatly depending on the degree and coefficients of the function.

## Point Plotting Method

The most fundamental way to draw a graph is by determining several $$(x, y)$$ point pairs that satisfy the function, then connecting them with a smooth curve.

Visible text: The most fundamental way to draw a graph is by determining several point pairs that satisfy the function, then connecting them with a smooth curve.

**Steps:**

1.  Choose several different values for $$x$$.
2.  Calculate the value $$y = P(x)$$ for each chosen $$x$$ value.
3.  Create a table of $$(x, y)$$ value pairs.
4.  Plot these points on the coordinate plane.
5.  Connect the points with a smooth and continuous curve.

Visible text: 1. Choose several different values for .
2. Calculate the value for each chosen value.
3. Create a table of value pairs.
4. Plot these points on the coordinate plane.
5. Connect the points with a smooth and continuous curve.

### Linear Function Degree One

Graph the function $$f(x) = 2x + 5$$.

Visible text: Graph the function .

We choose several $$x$$ values and calculate $$y$$:

Visible text: We choose several values and calculate :

| $$x$$ | $$y = f(x)$$ | $$(x, y)$$   |
| :---------------------- | :----------------------------- | :----------------------------- |
| $$-3$$ | $$-1$$ | $$(-3, -1)$$ |
| $$-2$$ | $$1$$ | $$(-2, 1)$$  |
| $$-1$$ | $$3$$ | $$(-1, 3)$$  |
| $$0$$ | $$5$$ | $$(0, 5)$$   |
| $$1$$ | $$7$$ | $$(1, 7)$$   |
| $$2$$ | $$9$$ | $$(2, 9)$$   |
| $$3$$ | $$11$$ | $$(3, 11)$$  |

Visible text: | | | |
| :---------------------- | :----------------------------- | :----------------------------- |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |

Plot the points and connect them:

Component: LineEquation
Props:
- title: Graph of $$f(x) = 2x + 5$$
  Visible text: Graph of
- description: Graph of a linear function with degree $$1$$.
  Visible text: Graph of a linear function with degree .
- showZAxis: false
- cameraPosition: [0, 0, 15]
- data: [
{
points: Array.from({ length: 7 }, (_, i) => {
const x = -3 + i;
return { x, y: 2 * x + 5, z: 0 };
}),
color: getColor("YELLOW"),
},
]

### Quadratic Function Degree Two

Graph the function $$g(x) = x^2 - 2x - 3$$.

Visible text: Graph the function .

Table of values:

| $$x$$ | $$y = g(x)$$ | $$(x, y)$$  |
| :---------------------- | :----------------------------- | :---------------------------- |
| $$-2$$ | $$5$$ | $$(-2, 5)$$ |
| $$-1$$ | $$0$$ | $$(-1, 0)$$ |
| $$0$$ | $$-3$$ | $$(0, -3)$$ |
| $$1$$ | $$-4$$ | $$(1, -4)$$ |
| $$2$$ | $$-3$$ | $$(2, -3)$$ |
| $$3$$ | $$0$$ | $$(3, 0)$$  |
| $$4$$ | $$5$$ | $$(4, 5)$$  |

Visible text: | | | |
| :---------------------- | :----------------------------- | :---------------------------- |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |

Plot the points and connect with a smooth curve (parabola):

Component: LineEquation
Props:
- title: Graph of $$g(x) = x^2 - 2x - 3$$
  Visible text: Graph of
- description: Graph of a quadratic function with degree $$2$$.
  Visible text: Graph of a quadratic function with degree .
- showZAxis: false
- cameraPosition: [0, 0, 10]
- data: [
{
points: Array.from({ length: 7 }, (_, i) => {
const x = -2 + i;
return { x, y: x * x - 2 * x - 3, z: 0 };
}),
color: getColor("CYAN"),
},
]

### Cubic Function Degree Three

Graph the function $$h(x) = x^3 + 3x^2 - 4$$.

Visible text: Graph the function .

Table of values:

| $$x$$ | $$y = h(x)$$ | $$(x, y)$$    |
| :---------------------- | :----------------------------- | :------------------------------ |
| $$-4$$ | $$-20$$ | $$(-4, -20)$$ |
| $$-3$$ | $$-4$$ | $$(-3, -4)$$  |
| $$-2$$ | $$0$$ | $$(-2, 0)$$   |
| $$-1$$ | $$-2$$ | $$(-1, -2)$$  |
| $$0$$ | $$-4$$ | $$(0, -4)$$   |
| $$1$$ | $$0$$ | $$(1, 0)$$    |
| $$2$$ | $$16$$ | $$(2, 16)$$   |

Visible text: | | | |
| :---------------------- | :----------------------------- | :------------------------------ |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |

Plot the points and connect with a smooth curve:

Component: LineEquation
Props:
- title: Graph of $$h(x) = x^3 + 3x^2 - 4$$
  Visible text: Graph of
- description: Graph of a cubic function with degree $$3$$.
  Visible text: Graph of a cubic function with degree .
- showZAxis: false
- cameraPosition: [0, 0, 12]
- data: [
{
points: Array.from({ length: 61 }, (_, i) => {
// Increased points for smoothness
const x = -4 + i * 0.1;
return { x, y: x * x * x + 3 * x * x - 4, z: 0 };
}),
color: getColor("VIOLET"),
showPoints: false,
},
]

## General Characteristics of Polynomial Graphs

Graphs of polynomial functions are always **smooth** (no sharp corners) and **continuous** (no jumps or breaks). Their general shape is heavily influenced by the **degree** of the polynomial.

- **Degree** $$0$$: $$P(x) = c$$. The graph is a horizontal line.
- **Degree** $$1$$: $$P(x) = ax + b$$. The graph is a straight (slanted) line.
- **Degree** $$2$$: $$P(x) = ax^2 + bx + c$$. The graph is a parabola.
- **Degree** $$3$$: $$P(x) = ax^3 + \dots$$. The graph has a shape like the letter 'S' or a reverse 'S', and can have up to two 'peaks' or 'valleys'.
- **Degree** $$4$$: The graph can have up to three 'peaks' or 'valleys'.
- **Degree** $$5$$: The graph can have up to four 'peaks' or 'valleys'.

Visible text: - **Degree** : . The graph is a horizontal line.
- **Degree** : . The graph is a straight (slanted) line.
- **Degree** : . The graph is a parabola.
- **Degree** : . The graph has a shape like the letter 'S' or a reverse 'S', and can have up to two 'peaks' or 'valleys'.
- **Degree** : The graph can have up to three 'peaks' or 'valleys'.
- **Degree** : The graph can have up to four 'peaks' or 'valleys'.

In general, the graph of a polynomial function of degree $$n$$ can intersect the $$x$$-axis **at most** $$n\text{ times}$$ and has **at most** $$n-1$$ turning points (peaks or valleys).

Visible text: In general, the graph of a polynomial function of degree can intersect the -axis **at most** and has **at most** turning points (peaks or valleys).

## End Behavior

One important characteristic of polynomial graphs is their **end behavior**, which describes the direction of the graph as $$x$$ approaches positive infinity ($$x \to \infty$$) or negative infinity ($$x \to -\infty$$).

Visible text: One important characteristic of polynomial graphs is their **end behavior**, which describes the direction of the graph as approaches positive infinity () or negative infinity ().

The end behavior is determined **solely** by the **leading term** $$a_n x^n$$:

Visible text: The end behavior is determined **solely** by the **leading term** :

1.  **Degree $$n$$ (Even or Odd)**
2.  **Sign of the Leading Coefficient $$a_n$$ (Positive or Negative)**

Visible text: 1. **Degree (Even or Odd)**
2. **Sign of the Leading Coefficient (Positive or Negative)**

There are four possible combinations:

1.  **$$n$$ Even, $$a_n > 0$$ (Positive):**

    - As $$x \to \infty$$, $$y \to \infty$$ (rises right $$\nearrow$$)
    - As $$x \to -\infty$$, $$y \to \infty$$ (rises left $$\nwarrow$$)
    - Examples: $$y = x^2$$, $$y = x^4$$

      <LineEquation
        title={
          <>
            Graph of $$y = x^2$$ (Even, Positive)
          </>
        }
        description="Graph rises to the left and right."
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 7 }, (_, i) => {
              const x = -3 + i;
              return { x, y: x * x, z: 0 };
            }),
            color: getColor("LIME"),
          },
        ]}
      />

2.  **$$n$$ Even, $$a_n < 0$$ (Negative):**

    - As $$x \to \infty$$, $$y \to -\infty$$ (falls right $$\searrow$$)
    - As $$x \to -\infty$$, $$y \to -\infty$$ (falls left $$\swarrow$$)
    - Examples: $$y = -x^2$$, $$y = -x^6$$

      <LineEquation
        title={
          <>
            Graph of $$y = -x^2$$ (Even, Negative)
          </>
        }
        description="Graph falls to the left and right."
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 7 }, (_, i) => {
              const x = -3 + i;
              return { x, y: -(x * x), z: 0 };
            }),
            color: getColor("ROSE"),
          },
        ]}
      />

3.  **$$n$$ Odd, $$a_n > 0$$ (Positive):**

    - As $$x \to \infty$$, $$y \to \infty$$ (rises right $$\nearrow$$)
    - As $$x \to -\infty$$, $$y \to -\infty$$ (falls left $$\swarrow$$)
    - Examples: $$y = x$$, $$y = x^3$$, $$y = x^5$$

      <LineEquation
        title={
          <>
            Graph of $$y = x^3$$ (Odd, Positive)
          </>
        }
        description="Graph falls to the left and rises to the right."
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 41 }, (_, i) => {
              const x = -3 + i * 0.15;
              return { x, y: x * x * x, z: 0 };
            }),
            color: getColor("SKY"),
            showPoints: false,
          },
        ]}
      />

4.  **$$n$$ Odd, $$a_n < 0$$ (Negative):**

    - As $$x \to \infty$$, $$y \to -\infty$$ (falls right $$\searrow$$)
    - As $$x \to -\infty$$, $$y \to \infty$$ (rises left $$\nwarrow$$)
    - Examples: $$y = -x$$, $$y = -x^3$$

      <LineEquation
        title={
          <>
            Graph of $$y = -x^3$$ (Odd, Negative)
          </>
        }
        description="Graph rises to the left and falls to the right."
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 41 }, (_, i) => {
              const x = -3 + i * 0.15;
              return { x, y: -(x * x * x), z: 0 };
            }),
            color: getColor("AMBER"),
            showPoints: false,
          },
        ]}
      />

Visible text: 1. ** Even, (Positive):**

 - As , (rises right )
 - As , (rises left )
 - Examples: , 

 <LineEquation
 title={
 <>
 Graph of (Even, Positive)
 </>
 }
 description="Graph rises to the left and right."
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 7 }, (_, i) => {
 const x = -3 + i;
 return { x, y: x * x, z: 0 };
 }),
 color: getColor("LIME"),
 },
 ]}
 />

2. ** Even, (Negative):**

 - As , (falls right )
 - As , (falls left )
 - Examples: , 

 <LineEquation
 title={
 <>
 Graph of (Even, Negative)
 </>
 }
 description="Graph falls to the left and right."
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 7 }, (_, i) => {
 const x = -3 + i;
 return { x, y: -(x * x), z: 0 };
 }),
 color: getColor("ROSE"),
 },
 ]}
 />

3. ** Odd, (Positive):**

 - As , (rises right )
 - As , (falls left )
 - Examples: , , 

 <LineEquation
 title={
 <>
 Graph of (Odd, Positive)
 </>
 }
 description="Graph falls to the left and rises to the right."
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 41 }, (_, i) => {
 const x = -3 + i * 0.15;
 return { x, y: x * x * x, z: 0 };
 }),
 color: getColor("SKY"),
 showPoints: false,
 },
 ]}
 />

4. ** Odd, (Negative):**

 - As , (falls right )
 - As , (rises left )
 - Examples: , 

 <LineEquation
 title={
 <>
 Graph of (Odd, Negative)
 </>
 }
 description="Graph rises to the left and falls to the right."
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 41 }, (_, i) => {
 const x = -3 + i * 0.15;
 return { x, y: -(x * x * x), z: 0 };
 }),
 color: getColor("AMBER"),
 showPoints: false,
 },
 ]}
 />

### Using End Behavior

Knowing the end behavior is very helpful for identifying the graph of a polynomial function without having to plot it in detail.

**Application Example:**

Match the following functions with their likely end behavior:

1.  $$f(x) = x^4 + 2x^3 - 2x - 3$$

    - Leading term: $$x^4$$
    - Degree $$n=4$$ (Even)
    - Leading coefficient $$a_n=1$$ (Positive)
    - End behavior: Rises left ($$\nwarrow$$), Rises right ($$\nearrow$$)

    <ContentBlock>
      <LineEquation
        title={
          <>
            Graph of $$f(x) = x^4 + 2x^3 - 2x - 3$$
          </>
        }
        description={
          <>
            End Behavior: $$\nwarrow$${" "}
            $$\nearrow$$
          </>
        }
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 51 }, (_, i) => {
              const x = -2.5 + i * (4.3 / 50);
              const y = x ** 4 + 2 * x ** 3 - 2 * x - 3;
              return { x, y, z: 0 };
            }),
            color: getColor("TEAL"),
            showPoints: false,
          },
        ]}
      />
    </ContentBlock>

2.  $$g(x) = -x^3 + 2x^2 - x + 1$$

    - Leading term: $$-x^3$$
    - Degree $$n=3$$ (Odd)
    - Leading coefficient $$a_n=-1$$ (Negative)
    - End behavior: Rises left ($$\nwarrow$$), Falls right ($$\searrow$$)

    <ContentBlock>
      <LineEquation
        title={
          <>
            Graph of $$g(x) = -x^3 + 2x^2 - x + 1$$
          </>
        }
        description={
          <>
            End Behavior: $$\nwarrow$${" "}
            $$\searrow$$
          </>
        }
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 51 }, (_, i) => {
              const x = -2.5 + i * 0.1;
              const y = -(x ** 3) + 2 * x ** 2 - x + 1;
              return { x, y, z: 0 };
            }),
            color: getColor("ORANGE"),
            showPoints: false,
          },
        ]}
      />
    </ContentBlock>

3.  $$h(x) = -x^6 - \frac{11}{4}x^5 + x^4 + 5x^3 + 2$$

    - Leading term: $$-x^6$$
    - Degree $$n=6$$ (Even)
    - Leading coefficient $$a_n=-1$$ (Negative)
    - End behavior: Falls left ($$\swarrow$$), Falls right ($$\searrow$$)

    <ContentBlock>
      <LineEquation
        title={
          <>
            Graph of{" "}
            $$h(x) = -x^6 - \frac{11}{4}x^5 + x^4 + 5x^3 + 2$$
          </>
        }
        description={
          <>
            End Behavior: $$\swarrow$${" "}
            $$\searrow$$
          </>
        }
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 111 }, (_, i) => {
              const x = -2.5 + i * (4.1 / 110);
              const y = -(x ** 6) - (11 / 4) * x ** 5 + x ** 4 + 5 * x ** 3 + 2;
              return { x, y, z: 0 };
            }),
            color: getColor("FUCHSIA"),
            showPoints: false,
          },
        ]}
      />
    </ContentBlock>

4.  $$k(x) = 25x^5 - 20x^4 - 26x^3 + 12x^2 + 9x - 1$$

    - Leading term: $$25x^5$$
    - Degree $$n=5$$ (Odd)
    - Leading coefficient $$a_n=25$$ (Positive)
    - End behavior: Falls left ($$\swarrow$$), Rises right ($$\nearrow$$)

    <ContentBlock>
      <LineEquation
        title={
          <>
            Graph of{" "}
            $$k(x) = 25x^5 - 20x^4 - 26x^3 + 12x^2 + 9x - 1$$
          </>
        }
        description={
          <>
            End Behavior: $$\swarrow$${" "}
            $$\nearrow$$
          </>
        }
        showZAxis={false}
        cameraPosition={[0, 0, 15]}
        data={[
          {
            points: Array.from({ length: 71 }, (_, i) => {
              const x = -1.2 + i * 0.035;
              const y =
                25 * x ** 5 -
                20 * x ** 4 -
                26 * x ** 3 +
                12 * x ** 2 +
                9 * x -
                1;
              return { x, y, z: 0 };
            }),
            color: getColor("INDIGO"),
            showPoints: false,
          },
        ]}
      />
    </ContentBlock>

Visible text: 1. 

 - Leading term: 
 - Degree (Even)
 - Leading coefficient (Positive)
 - End behavior: Rises left (), Rises right ()

 <ContentBlock>
 <LineEquation
 title={
 <>
 Graph of 
 </>
 }
 description={
 <>
 End Behavior: {" "}
 
 </>
 }
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 51 }, (_, i) => {
 const x = -2.5 + i * (4.3 / 50);
 const y = x ** 4 + 2 * x ** 3 - 2 * x - 3;
 return { x, y, z: 0 };
 }),
 color: getColor("TEAL"),
 showPoints: false,
 },
 ]}
 />
 </ContentBlock>

2. 

 - Leading term: 
 - Degree (Odd)
 - Leading coefficient (Negative)
 - End behavior: Rises left (), Falls right ()

 <ContentBlock>
 <LineEquation
 title={
 <>
 Graph of 
 </>
 }
 description={
 <>
 End Behavior: {" "}
 
 </>
 }
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 51 }, (_, i) => {
 const x = -2.5 + i * 0.1;
 const y = -(x ** 3) + 2 * x ** 2 - x + 1;
 return { x, y, z: 0 };
 }),
 color: getColor("ORANGE"),
 showPoints: false,
 },
 ]}
 />
 </ContentBlock>

3. 

 - Leading term: 
 - Degree (Even)
 - Leading coefficient (Negative)
 - End behavior: Falls left (), Falls right ()

 <ContentBlock>
 <LineEquation
 title={
 <>
 Graph of{" "}
 
 </>
 }
 description={
 <>
 End Behavior: {" "}
 
 </>
 }
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 111 }, (_, i) => {
 const x = -2.5 + i * (4.1 / 110);
 const y = -(x ** 6) - (11 / 4) * x ** 5 + x ** 4 + 5 * x ** 3 + 2;
 return { x, y, z: 0 };
 }),
 color: getColor("FUCHSIA"),
 showPoints: false,
 },
 ]}
 />
 </ContentBlock>

4. 

 - Leading term: 
 - Degree (Odd)
 - Leading coefficient (Positive)
 - End behavior: Falls left (), Rises right ()

 <ContentBlock>
 <LineEquation
 title={
 <>
 Graph of{" "}
 
 </>
 }
 description={
 <>
 End Behavior: {" "}
 
 </>
 }
 showZAxis={false}
 cameraPosition={[0, 0, 15]}
 data={[
 {
 points: Array.from({ length: 71 }, (_, i) => {
 const x = -1.2 + i * 0.035;
 const y =
 25 * x ** 5 -
 20 * x ** 4 -
 26 * x ** 3 +
 12 * x ** 2 +
 9 * x -
 1;
 return { x, y, z: 0 };
 }),
 color: getColor("INDIGO"),
 showPoints: false,
 },
 ]}
 />
 </ContentBlock>

By analyzing the leading term, we can predict the general shape of the graph at its ends.