Define and solve a problem by using Excel Solver

 Oct 21, 2016

Solver is a Microsoft Excel add-in program you can use for What-If Analysis. You can use Solver to determine the maximum or minimum value of one cell by changing other cells. For example, you can change the amount of your projected expenses or revenue and see the effect on your projected profit amount. Solver must be used on a cell containing a formula.

To Use Solver

  1. On the Data tab, in the Analysis group, click Solver.
  2. In the Set Objective box, enter a cell reference or name for the objective cell. The objective cell must contain a formula.
  3. Do one of the following:
    1. If you want the value of the objective cell to be as large as possible, click Max.
    2. If you want the value of the objective cell to be as small as possible, click Min.
    3. If you want the objective cell to be a certain value, click Value of, and then type the value in the box
    4. In the By Changing Variable Cells box, enter a name or reference for each decision variable cell range. Separate the non-adjacent references with commas. The variable cells must be related directly or indirectly to the objective cell. You can specify up to 200 variable cells.

  4. In the Subject to the Constraints box, enter any constraints that you want to apply by doing the following:
    1. In the Solver Parameters dialog box, click Add.
    2. In the Cell Reference box, enter the cell reference or name of the cell range for which you want to constrain the value.
    3. Click the relationship ( <=, =, >=, int, bin, or dif ) that you want between the referenced cell and the constraint. If you click int, integer appears in the Constraint box. If you click bin, binary appears in the Constraint box. If you click dif, alldifferent appears in the Constraint box.
    4. If If you choose <=, =, or >= for the relationship in the Constraint box, type a number, a cell reference or name, or a formula.
    5. Do one of the following:
      • To accept the constraint and add another, click Add.
      • To accept the constraint and return to the Solver Parameters dialog box, click OK.
      • Note: You can apply the int, bin, and dif relationships only in constraints on decision variable cells.
      • You can change or delete an existing constraint by doing the following:
    6. In the Solver Parameters dialog box, click the constraint that you want to change or delete.
    7. Click Change and then make your changes, or click Delete.

  5. Click Solve and do one of the following:
    1. To keep the solution values on the worksheet, in the Solver Results dialog box, click Keep Solver Solution.
    2. To restore the original values before you clicked Solve, click Restore Original Values.
    3. You can interrupt the solution process by pressing Esc. Excel recalculates the worksheet with the last values that are found for the decision variable cells.
    4. To create a report that is based on your solution after Solver finds a solution, you can click a report type in the Reports box and then click OK. The report is created on a new worksheet in your workbook. If Solver doesn't find a solution, only certain reports or no reports are available.
    5. To save your decision variable cell values as a scenario that you can display later, click Save Scenario in the Solver Results dialog box, and then type a name for the scenario in the Scenario Name box.

    For more information, take a look at our Excel training courses.


    How do your Excel skills stack up?   

    Test Now  

    How do your Excel skills stack up?   

    Test Now  

About the Author:

Alice Antonsen  

Alice is one of New Horizons’ most experienced Desktop Applications trainers. She is qualified with a Diploma of Business (Computing) and a Diploma of Information Technology. Since joining New Horizons in 2006, Alice has achieved the prestigious status of a certified Microsoft Office Master and for the past 4 years, has been placed in the Top 25 Desktop Applications trainers for New Horizons Worldwide. Throughout her career, she has gained a wealth of knowledge and experience in providing training to individuals and groups of varying skill levels. Alice delivers each training session with great care and consideration ensuring each one is tailored to the learning needs of her students.

Read full bio
top
Back to top