Skip to content

Commit f717845

Browse files
Merge pull request #351 from Quantum-Software-Development/FabianaCampanari-patch-1
Update README.md
2 parents 139b59d + 0ed7afe commit f717845

File tree

1 file changed

+71
-55
lines changed

1 file changed

+71
-55
lines changed

README.md

Lines changed: 71 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,55 @@ In the context of Linear Programming (LP) and the Simplex Method, Excel Solver c
415415
<br>
416416

417417

418-
## [Solver Configuration (Simplex LP)]():
418+
## Simplex Method using Excel Solver
419+
420+
This example shows how to solve a Linear Programming (LP) problem using the **Simplex Method** via **Excel Solver**.
421+
422+
---
423+
424+
### Problem
425+
426+
Maximize the objective function:
427+
428+
Z = 3x + 5y
429+
430+
Subject to the constraints:
431+
432+
x + 2y ≤ 100
433+
2x + y ≤ 80
434+
x, y ≥ 0
435+
436+
---
437+
438+
### Excel Spreadsheet Setup
439+
440+
Fill the spreadsheet with the following structure:
441+
442+
#### Variables and Objective
443+
444+
| Cell | Description | Formula / Value |
445+
|------|------------------------|----------------------|
446+
| B1 | x (Decision Variable) | *(leave blank)* |
447+
| B2 | y (Decision Variable) | *(leave blank)* |
448+
| B3 | Objective Function Z | `=3*B1 + 5*B2` |
449+
450+
#### Constraints Left-Hand Side (LHS)
451+
452+
| Cell | Description | Formula |
453+
|------|----------------------------|---------------------|
454+
| B5 | Constraint 1 LHS | `=1*B1 + 2*B2` |
455+
| B6 | Constraint 2 LHS | `=2*B1 + 1*B2` |
456+
457+
#### Constraints Right-Hand Side (RHS)
458+
459+
| Cell | Description | Value |
460+
|------|----------------------------|---------------------|
461+
| C5 | Constraint 1 RHS | `100` |
462+
| C6 | Constraint 2 RHS | `80` |
463+
464+
---
465+
466+
### Solver Configuration (Simplex LP)
419467

420468
1. Go to `Data` > `Solver`.
421469
2. Set Objective Cell: `B3`
@@ -429,15 +477,30 @@ In the context of Linear Programming (LP) and the Simplex Method, Excel Solver c
429477
6. Choose **Simplex LP** as the solving method.
430478
7. Click **Solve**.
431479

432-
<br>
480+
---
481+
482+
### Solution
483+
484+
After running Solver
485+
486+
x = 20
487+
y = 40
488+
Z = 320 + 540 = 260
433489

434-
## [Example Excel Solver Example – Linear Programming with Simplex]()
490+
491+
Z = 260
492+
493+
494+
——
495+
496+
497+
## Excel Solver Example – Linear Programming with Simplex
435498

436499
This example demonstrates how to use Excel Solver to solve a Linear Programming problem using the **Simplex Method**.
437500

438-
### [Problem Statement]():
501+
### Problem Statement
439502

440-
[Maximize]():
503+
Maximize:
441504

442505
Z = 40x + 30y
443506

@@ -448,9 +511,7 @@ x + 2y ≤ 50
448511
x, y ≥ 0
449512

450513

451-
<br>
452-
453-
### [Excel Setup]():
514+
### Excel Setup
454515

455516
| Cell | Description | Formula / Value |
456517
|------|--------------------------|---------------------|
@@ -460,17 +521,12 @@ x, y ≥ 0
460521
| B5 | Constraint 1 (LHS) | `=2*B1 + 1*B2` |
461522
| B6 | Constraint 2 (LHS) | `=1*B1 + 2*B2` |
462523

463-
464-
<br>
465-
466524
| Cell | Constraint RHS | Value |
467525
|------|--------------------------|---------------------|
468526
| C5 | Constraint 1 (RHS) | 40 |
469527
| C6 | Constraint 2 (RHS) | 50 |
470528

471-
<br>
472-
473-
### [Solver Configuration]():
529+
### Solver Configuration
474530

475531
1. Set Objective: **B3**
476532
2. To: **Maximize**
@@ -484,53 +540,13 @@ x, y ≥ 0
484540

485541
Click **Solve** to find the optimal solution.
486542

487-
<br>
488-
489-
### [Solution Output]():
543+
### Solution Output
490544

491545
After running Solver:
492546

493547
- **x = 10**
494548
- **y = 20**
495549
- **Z = 40×10 + 30×20 = 1000**
496-
497-
<br>
498-
499-
### Solver Configuration (Simplex LP)
500-
501-
1. Go to `Data` > `Solver`.
502-
2. Set Objective Cell: `B3`
503-
3. Select: **Max**
504-
4. By Changing Variable Cells: `B1:B2`
505-
5. Add Constraints:
506-
- `B5 <= C5`
507-
- `B6 <= C6`
508-
- `B1 >= 0`
509-
- `B2 >= 0`
510-
6. Choose **Simplex LP** as the solving method.
511-
7. Click **Solve**.
512-
513-
514-
### [Solution]()
515-
516-
After running Solver
517-
518-
x = 20
519-
y = 40
520-
Z = 320 + 540 = 260
521-
522-
523-
Z = 260
524-
525-
526-
527-
528-
529-
530-
531-
532-
533-
534550

535551

536552

0 commit comments

Comments
 (0)