Solver in Excel (Everything You Need to Know)

In the image below, we have enabled the Solver Add-in.

Overview Image of Excel Solver


What is an Excel Solver?

The Excel Solver is an add-in tool in Microsoft Excel that helps you find an optimal solution for complex problems involving mathematical equations and constraints. It is primarily used for optimization and solving linear programming problems.

Definitions of terms:

Objective Cell: A single cell with a formula in it. The constraint cells’ limitations are applied to the decision-based formula in the cell. The objective cell’s value can be decreased, increased, or fixed at the provided threshold.

Variable Cells: These are made up of variable data that the Solver modifies to accomplish the goal.

Constraint Cells: These are the prerequisites that must be met.

Solver Parameters


How to Add Solver in Excel

  • Go to the File tab >> select Options.

Selecting Options

  • From Add-ins >> select Excel Add-ins >> select Go.

Selecting Excel Add-ins

  • Select Solver Add-in >> click OK.

Selecting Solver Add In


Types of Solving Methods

1. GRG Nonlinear

Nonlinear problems can exhibit multiple feasible regions or a range of variable values that satisfy all the constraints.

GRG Nonlinear


2. Simplex LP

In a linear programming problem, the goal is to maximize or minimize a single objective while considering specific conditions.

The simplex LP and GRG nonlinear methods are employed to solve smooth problems.

Simplex LP


3. Evolutionary

This approach is useful for resolving problems with jagged patterns, which involve functions that have breaks.

Evolutionary Solver


Further Examples of the Excel Solver

1.  Finding Maximum (GRG Nonlinear)

  • Go to the Data tab >> Select Solver.

Selecting Solver from Data Tab

  • In the Set Objective box, select cell G10 >> click on Max.
  • Select cells F5:F9 in the By Changing Variables
  • Click on Add >> give the Constraints.
  • Click on Mark Unconstrained Variable Non-Negative >> select GRG Nonlinear.
  • Click on Solve.

Selecting Item in Solver Parameter Dialog Box

  • In the Solver Result dialog box, select Answer >> click OK.

Selecting Answer

You can see the result in a different Excel sheet.

Answer Report


2. Finding Magic Square (GRG Nonlinear)

  • Go to the Data tab >> Select Solver.

Selecting Solver from Data Tab

  • Keep the Set Objective box empty >> click on Max.
  • Select cells C5:E7 in the By Changing Variables
  • Click on Add >> give the Constraints.
  • Click on Mark Unconstrained Variable Non-Negative >> select GRG Nonlinear.
  • Click on Solve.

Selecting Item in Solver Parameters dialog box

You can see the rearranged magic square.

Final Magic Square


3. Interpreting Linear Programming (Simplex LP)

  • Select Solver from the Data

Selecting Solver from Data Tab

  • In the Set Objective box, select cell H10 >> click on Max.
  • Select cells C10:E10 in the By Changing Variables
  • Click on Add >> give the Constrain.
  • Click on Mark Unconstrained Variable Non-Negative >> select Simple LP.
  • Click on Solve.

Selecting item in Solver Parameter Dialog Box

  • Select Answer >> click OK.

Reporting Answer

You can see the answer report.

outcome after reporting answer

Read More: Where Is Solver in Excel – Find, Install & Use


4. Coordinates and Mapping with Solver (Evolutionary Solver)

  • Enter the following formula in cell F5:
=SQRT((C5-OFFSET($C$13,E5,0))^2+(D5-OFFSET($D$13,E5,0))^2)

Using Multiple Functions

  • Enter the following formula in cell F14:
=SUM(F5:F10)

Using SUM Function

  • From the Data tab >> select Solver.
  • In the Set Objective box, select cell F14 >> click on Min.
  • Select cells in the By Changing Variables
  • Click on Add >> give the Constrain.
  • Click on Mark Unconstrained Variable Non-Negative >> select Evolutionary.
  • Click on Solve.

  • Click OK.

Clicking OK

You can see the result in cell F14.

Output after using Evolutionary Solver

Read More: Optimization in Excel


How to Load/Save Solver Solution in Excel

  • To load/save a solver solution, select Load/Save in the Solver Parameters dialog box.

Select Load or Save

  • Select a cell >> click on Save.

Selecting a Cell and clicking Save


Download the Practice Workbook


Solver in Excel: Knowledge Hub


<< Go Back to Learn Excel

Get FREE Advanced Excel Exercises with Solutions!

Tags:

Afia Kona
Afia Kona

Afia Aziz Kona, a graduate of NAME from Bangladesh University of Engineering & Technology, Bangladesh, serves as a technical content creator in the ExcelDemy project. Possessing a passion for innovation and critical thinking, she actively embraces challenges. Beyond her engineering background, Afia exhibits a keen interest in Excel, having authored numerous articles on Excel & VBA-related issues to simplify the experience for users facing obstacles in Excel. Apart from creating Excel tutorials, she is also interested... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo