How to Solve an Equation for X When Y is Given in Excel (2 Methods)

Method 1 – Use of Solver Feature

Enable Solver Feature

  • Go to the File tab.

Use of Solver Feature to Solve an Equation for X When Y is Given in Excel

  • Select Options.

  • Click on Add-ins and select Go.

Adding Solver Feature on the Ribbon to Solve an Equation for X When Y is Given in Excel

  • Check the Solver Add-in and click OK.

Adding Solver Feature on the ribbon to Solve an Equation for X When Y is Given in Excel

  • You’ll find the Solver feature under the Data tab.

Solving the Equation

  • Suppose we have the equation: (Y = 2X + 7), and the Y value is 5.

Use of Solver Feature to Solve an Equation for X When Y is Given in Excel

  • In cell D5, enter the formula:
=2*B5+7

Using Formula to Solve an Equation for X When Y is Given in Excel

  • Go to the Data tab and click on Solver.

Use of Solver Feature to Solve an Equation for X When Y is Given in Excel

  • In the Solver Parameters dialog, set the objective to cell $D$5 with a value of 5 (since Y = 5).
  • Specify that cell $B$5 contains the X value.
  • Uncheck Make Unconstrained Variables Non-Negative.
  • Click Solve.

  • A Solver Results dialog box will open like the image below.
  • Click OK to Keep Solver Solution.

  • The solved X value will appear in cell B5.

  • You can repeat this process for different Y values.

Use of Solver Feature to Solve an Equation for X When Y is Given in Excel

Read More: How to Solve Algebraic Equations with Multiple Variables


Method 2 – Manual Solution

Manually Solving an Equation for X When Y is Given in Excel

Equation Setup

  • In cell C6, enter the equation with the Y value inserted.

Typing Equation to Solve an Equation for X When Y is Given in Excel

  • Simplify the equation manually and enter the simplified version in cell C7.

Simplifying to Solve an Equation for X When Y is Given in Excel

Calculate X

  • In cell C8, enter the formula:
=(5-7)/2
  • Press Enter to calculate the X value.

Using Formula to Solve an Equation for X When Y is Given in Excel

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


Things to Remember

  • The Solver feature is quicker but automatic.
  • Manual solving gives more flexibility but is time-consuming

Download Practice Workbook

You can download the practice workbook from here:


Related Articles


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

Get FREE Advanced Excel Exercises with Solutions!
Md. Asaduzzaman
Md. Asaduzzaman

Hello! I am Md. Asaduzzaman. Currently, I am working as an Excel and VBA Content Developer and I will be posting my articles related to this here. I graduated from Bangladesh University of Science and Technology(BUET) in 2022. I completed my BSc in Naval Architecture and Marine Engineering. I like to solve real-life problems in Microsoft Excel and share the solutions through articles. I post here regularly. Hope you find the articles helpful.

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo