How to Plot a Polynomial in Excel Using Its Coefficients
Question details
The user needs an efficient way to graph a 4th-degree polynomial function over a specific range of x values based on its coefficients.

- Product
- Excel
- Device & OS
- not provided
- Scenario
- Visualizing complex mathematical equations dynamically by changing the coefficient values without needing to manually rewrite the formula for every row.
- Observed behavior
- The goal state is to generate x values from 0 to 150 and calculate the corresponding y values using only the stored coefficients (a, b, c, d, e), then plot the results smoothly.
Set up a dedicated area in your worksheet to store the coefficients (a, b, c, d, e) so they can be easily referenced and modified later without changing the core mathematical formula.
Use SUMPRODUCT and an XY Scatter Chart
This is the most efficient method to plot polynomials in Excel. It calculates the powers of x dynamically and multiplies them by the coefficient array, avoiding long and messy formulas.
By utilizing Excel's SUMPRODUCT function alongside an inline array constant for the exponents, you can condense the entire polynomial equation into a single, clean formula.
An XY Scatter chart with smooth lines is ideal for mathematical graphing because it correctly plots the true numerical distance between x values.
List your coefficients (a, b, c, d, e) in a vertical column, for example, from cell B1 to B5.
In a new column, starting from cell A8, generate your sequence of x values from 0 down to 150.
In cell B8 (the adjacent y column), enter the formula: =SUMPRODUCT($B$1:$B$5, A8^{0,1,2,3,4}). Drag this formula down to apply it to all x values up to 150.
Highlight both the x and y data columns. Go to the Insert tab on the ribbon, click the Scatter Chart icon, and select 'Scatter with Smooth Lines'.

Use Defined Named Ranges for the Coefficients
Defining names for your coefficient cells allows you to write the polynomial formula in a highly readable format that resembles standard algebraic notation.
Plot Complex Mathematical Equations Easily in WPS Spreadsheet
You can dynamically graph polynomial equations in WPS Spreadsheet utilizing its comprehensive array functions and built-in smooth line scatter charts. WPS Spreadsheet offers a seamless environment for performing advanced data analysis and visualization.
- 1. Input Coefficients: Open a new WPS Spreadsheet and list your polynomial coefficients in a designated column.
- 2. Generate x Series: Create your sequence of x values (e.g., 0 to 150) using the built-in Fill Series feature.
- 3. Calculate y Values: Use the SUMPRODUCT formula referencing the coefficient cells and powers of x to dynamically calculate the y column.
- 4. Insert Chart: Highlight both columns and insert an XY Scatter Chart with smooth lines from the Insert tab to visualize the polynomial.

Frequently Asked Questions
Can I change the polynomial coefficients after creating the chart?
Yes. As long as you reference the specific cells containing the coefficients in your formula (using absolute references like $B$1 or defined names), the chart will automatically update the curve whenever you modify those cell values.
Why should I use an XY Scatter chart instead of a Line chart for plotting polynomials?
An XY Scatter chart treats the x-axis as numeric values with true scale spacing, which is essential for accurate mathematical functions. A Line chart treats the x-axis as categorical text labels, meaning spacing between points might not properly reflect the data's scale.
Does the SUMPRODUCT method work for polynomials of higher degrees?
Yes. You can expand the array of powers in the formula to handle polynomials of any degree. For example, for a 6th-degree polynomial, you would change the power array to {0,1,2,3,4,5,6} and ensure your coefficient range includes 7 corresponding cells.




