General Linear Programming: Feasible Polygon and Optimal Solution

General Linear Programming: Feasible Polygon and Optimal Solution
Loading the math board and drawing, please wait…
2021-01-02 03:51
This example demonstrates how to find the optimal value of a linear objective function under a set of linear inequality constraints by working directly on the geometric feasible region (a polygon). It highlights that the optimum can be identified by checking candidate extreme points (typically the feasible vertices). The core mathematics includes general linear programming, linear inequalities, feasible region construction, objective-function maximization/minimization, and the vertex/extrama-based optimality idea. Construction details reflect the GeoGebra workflow: Sequence generates candidate data, RemoveUndefined and Unique clean and deduplicate intermediate results, Min/Max compute minimal and maximal objective values, Element extracts selected objects (such as vertices and matched values), and Segment builds boundary segments for the constraint lines. Frequency plus First/Last are used to organize candidates and retrieve meaningful endpoints, while Textfield places input parameters and computed outcomes onto the diagram. Key objects—regiones (feasible region), cortes (cuts/boundary segments), verticesregion (feasible vertices), posiblesextremos (possible extrema), valores, maximo, and minimo—connect the computation to visible geometry and labeled results. Suitable for advanced secondary school, introductory university optimization/operations research, and math modeling lessons focused on geometric intuition for LP/linear optimization.

GeoGebra Commands & Parameters

  1. Element(regiones, n) → b
  2. RemoveUndefined({Vertex[b]}) → cortes
  3. RemoveUndefined(Sequence[If[cortes(k) ∈ b, cortes(k)], k, 1, Length[cortes]]) → verticesregion
  4. Unique(verticesregion) → posiblesextremos
  5. Sequence(f(Element[posiblesextremos, i]), i, 1, Length[posiblesextremos]) → valores, {3000}
  6. Max(valores) → maximo
  7. Segment(A, C) → i
  8. Textfield(res3) → CasillaDeEntrada3
  9. Textfield(res4) → CasillaDeEntrada4
  10. Textfield(res6) → CasillaDeEntrada6
  11. Textfield(f) → CasillaDeEntrada8
  12. Textfield(res1) → CasillaDeEntrada1
  13. Textfield(res2) → CasillaDeEntrada2
  14. Textfield(res5) → CasillaDeEntrada5
  15. Min(valores) → minimo
  16. Element(posiblesextremos, 1) → V_1
  17. Element(posiblesextremos, 2) → V_2
  18. Element(posiblesextremos, 3) → V_3
  19. Element(posiblesextremos, 4) → V_4
  20. Element(posiblesextremos, 5) → V_5
  21. Element(posiblesextremos, 6) → V_6
  22. Element(posiblesextremos, 7) → V_7
  23. Frequency(valores) → frec
  24. Last(frec) → ultimofrec
  25. First(frec) → primerofrec
  26. Segment(B, D) → j

AI Drawing Prompt Reference

Draw a feasible region defined by a set of linear inequalities. Find the maximum and minimum values of the objective function, which are attained at the vertices of the feasible region. Draw the boundary lines of the feasible region, mark all vertices, and show the maximum and minimum values on the diagram.
The prompt above was compiled from the original drawing commands and is for reference only.