How to Solve Simultaneous Equations in Excel (3 Easy Ways)

Excel is a popular and useful tool for analyzing data and solving mathematical equations. One such case where Excel shines is effortlessly solving simultaneous equations. Keeping this in mind, this article demonstrates 3 useful ways to solve simultaneous equations in Excel.


How to Solve Simultaneous Equations in Excel: 3 Easy Ways

Say, we have the 2 linear equations that we want to solve for X and Y.

3X – Y = 5

4X – Y = 2

So, let’s see how we can solve simultaneous equations in Excel in order to obtain the values of X and Y.

solving simultaneous equations in excel

Here, we have used Microsoft Excel 365 version, you may use any other version according to your convenience.


Method-1: Utilizing MMULT and MINVERSE Functions

Let’s start with the most obvious method of solving simultaneous equations in Excel. Yes, you’re right. We’ll combine the MMULT and MINVERSE functions to solve 2 equations with 2 unknowns in Excel. Therefore, let’s see it in action.

📌 Steps:

  • In the first place, select the D13:D14 cells and enter the following expression.

=MMULT(MINVERSE(B9:C10),D9:D10)

Here, the B9:C10 and D9:D10 cells represent the X and Y coefficients and the constant values on the right-hand side of the equation.

📃 Note: Please make sure to press the CTRL + SHIFT + ENTER keys on your keyboard since this is an array formula.

Formula Breakdown:

  • MINVERSE(B9:C10) → returns the inverse matrix for the matrix stored in an array. Here, the function returns the values of the inverse matrix.
  • =MMULT(MINVERSE(B9:C10),D9:D10)→ returns the matrix product of two arrays. Here, the function multiplies the inverse matrix array with the values on the RHS and gives the output.

Utilizing MMULT and MINVERSE Functions

Finally, the results should look like the image shown below.

solving simultaneous equations with MMULT and MINVERSE Functions


Method-2: Solving Simultaneous Equations with Excel Add-in

Another simple way to solve simultaneous equations in Excel involves using the Solver Add-in. It’s simple and easy, just follow along.

📌 Steps:

  • First and foremost, move to the C13 cell >> type in the LHS of the linear equation. In this case, the expression is given below.

=3*D9-D10

Here, the D9 and D10 cells indicate the Initial Values of X and Y respectively.

Simultaneous Equations Solver with Excel’s Add-in

  • Similarly, enter the second expression in the C14 cell.

=4*D9-D10

solving simultaneous equations in excel

  • Secondly, click the File tab in the top-left corner.

Go to File

  • Now, click on Options at the bottom of the window.

Excel Options

  • Then, click the Add-ins option >> select the Solver Add-in >> hit the Go button.

g Solver add-in

Now, this opens the Add-ins dialog box.

  • In turn, choose the Solver Add-in option >> click the OK button.

Finally, this adds the Solver Add-in in Excel.

Solver Add in

  • Thirdly, move to the Data tab >> click on Analyze >> press the Solver option.

Solver option

In an instant, the Solver window pops up.

  • Now, at the Set Objective field type in the C13 cell.
  • Afterward, at the To options select the Value Of option and enter the values of the constant, here, it is 5.
  • Following this, at the By Changing Variable Cells field, enter the C8:C9 range of cells.
  • Subsequently, hit the Add button to set the constraints.

Now, the Add Constraint wizard pops out.

  • To begin with, enter the C13 cell reference in the Cell Reference field.
  • Next, choose an equal sign (=) from the dropdown list >> type in the D13 cell in the Constraint field >> hit the Add button.

Add constraints

  • Then, repeat the same procedure to add a second constraint and click on OK.

  • In turn, choose the Simplex LP option in the Select a Solving Method field.
  • Eventually, click the Solve button.

solving simultaneous equations in excel

  • Additionally, insert a check on the Keep Solver Solution option and click OK.

solving simultaneous equations in excel

Consequently, the results should look like the screenshot shown below.

solving simultaneous equations in excel

Read More: How to Solve 2 Equations with 2 Unknowns in Excel


Method-3: Solve Simultaneous Equations with 3 Variables Applying Cramer’s Rule

Cramer’s rule is a formula in linear algebra to solve a system of equations in Excel with multiple unknowns. Here, we’ll employ Cramer’s rule to solve the 3 linear equations with 3 unknowns, so, just follow these simple steps.

📌 Steps:

  • Firstly, proceed to the C11 cell and enter the C6 cell reference.

=C6

Here, the C6 cell points to the coefficient of X.

Solve Simultaneous Equation with 3 Variables Applying Cramer’s Rule

  • Next, enter all the values as shown in the image below and press the CTRL + 1 button.

Using Format Cells

This opens the Format Cells wizard.

  • Now, navigate to the Border tab and follow the steps for the Style, Outside Borders as shown in the picture given below.

Format borders

  • Secondly, proceed to the C15 cell >> enter the values from the RHS column.
  • Following this, enter the coefficients of Y and Z in the next two columns.

Finding Determinant

  • Similarly, enter the values for Dy in the second column.

Calculating Determinant

  • Similarly, repeat the same process for Dz and enter it in the third column.

  • Now, jump to the G12 cell and enter the formula below.

=MDETERM(C11:E13)

In this expression, the MDETERM function calculates the determinant of the C11:E13 array.

Using MDETERM Function

  • Likewise, compute the determinants of x, y, and z.

Solve Simultaneous Equation with 3 Variables Applying Cramer’s Rule

  • Finally, move to the I6 cell and enter the expression given below.

=G16/G12

Here, the G16 and G12 cells represent the values Dx and D respectively.

Solve Simultaneous Equation with 3 Variables Applying Cramer’s Rule

Subsequently, the output should look like the picture shown below.

Solve Simultaneous Equation with 3 Variables Applying Cramer’s Rule

Read More: How to Solve an Equation for X When Y is Given in Excel 


How to Solve Quadratic Equations in Excel

So far, we’ve discussed solving only linear equations, but you can also solve quadratic equations using the Goal Seek option in Excel. So, let’s begin.

📌 Steps:

  • Firstly, go to the E10 cell and type in the quadratic equation as shown below.

=5*E9^2 - 4*E9 - 9

Here, the E9 cell refers to the values of X.

Solving Quadratic Equations in Excel

  • Next, move to the Data tab >> click the What-If Analysis drop-down >> select the Goal Seek option.

Using Goal Seek

This opens the Goal Seek wizard.

  • Now, in the Set cell field, enter the E10 cell >> next, in the To value field, type in 10 >> then, in the By changing cell option >> select the E9 cell.

Goal Seek option

Lastly, your output should look like the screenshot given below.

Solving Quadratic Equations in Excel

Read More: How to Solve Polynomial Equation in Excel


How to Solve Linear Equations in Excel Using Solver

For our last method, we’ll demonstrate how to solve linear equations with Excel’s Solver Add-in. Hence, let us see the process in detail.

📌 Steps:

  • Initially, navigate to the C15 cell and type in the linear equation as shown in the picture below.

=3*D10-5*D11+D12

Here, the D10, D11, and D12 cells indicate the Initial Values of X, Y, and Z.

Solving Linear Equations in Excel Using Solver

Likewise, repeat the same process for the other two equations.

  • Secondly, navigate to the Data tab >> click the Analyze drop-down >> choose the Solver option.

Using Solver option

  • Thirdly, follow the detailed steps described in Method 2.

Solving Linear Equations in Excel Using Solver

Eventually, your output should look like the image given below.

Solving Linear Equations in Excel Using Solver


Practice Section

We have provided a Practice section on the right side of each sheet, so you can practice yourself. Please make sure to do it by yourself.

Practice Section


Download Practice Workbook

You can download the practice workbook from the link below.


Conclusion

I hope all the methods mentioned above for solving simultaneous equations in Excel will prompt you to apply them more effectively. If you have any questions or feedback, please let me know in the comment section. Or you can check out our other articles related to Excel functions on this website.


Related Articles


<< Go Back to Excel Solve Equation | Excel Solver Examples | Solver in Excel | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Kawser Ahmed
Kawser Ahmed

Kawser Ahmed is a Microsoft Excel Expert, Udemy Course Instructor, Data Analyst, Finance professional, and Chief Editor of ExcelDemy. He is the founder and CEO of SOFTEKO (a software and content marketing company). He has a B.Sc in Electrical and Electronics Engineering. As a Udemy instructor, he offers 8 acclaimed Excel courses, one selected for Udemy Business. A devoted MS Excel enthusiast, Kawser has contributed over 200 articles and reviewed thousands more. His expertise extends to Data Analysis,... Read Full Bio

5 Comments
  1. Hi,
    I am trying to solve linear equations with multiple unknowns. Sample below. Problem is I have only one equation with multiple unknows
    19.6=a+0.0124x+0.0304y+0.175z
    I need a excel function to give possible values for the variables in above equation. Anyone knows how to do it?

    P.S: I am not looking for solutions where we have three unknowns and hence we cant solve with less than three questions. I need to know what are the possible (not unique) values that satisfies the above equation

    Thanks

  2. Need more lessons on solving quadratic and linear equations.

  3. Very helpful! Thank You

  4. thank you so much it was really helpful 😀

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo