The graphical method for multivariable functions locates and classifies the critical points of an unconstrained objective function by solvingDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/FabianeloV/Metodo-simplex/llms.txt
Use this file to discover all available pages before exploring further.
∇f(x) = 0 numerically. Rather than relying on sympy.solve (which can hang or return parametric solution sets for non-polynomial expressions), the engine uses multivariate Newton’s method seeded from a grid of starting points inside the user-supplied bounds:
Endpoint
Request
The objective function as a SymPy-compatible symbolic string. Use
** for exponents and * for multiplication.Examples: "x**2 + y**2", "x**3 - 3*x + y**2 - 2*y"List of variable names used in the expression. Must contain 2 or 3 names.Example:
["x", "y"]Search domain for each variable, as a list of
[min, max] pairs — one per variable, in the same order as variables.Example: [[-5, 5], [-5, 5]]Every bound must satisfy
max > min. The number of bounds must equal the number of variables. Critical points found outside the domain are discarded; only the visualization grid is clipped to the domain.Which type of critical point to treat as the optimum:
"min" or "max". If no matching critical point is found inside the domain, the closest available critical point is returned instead and status is set to "no_critical_point".Response
"optimal" if a critical point whose nature matches goal was found inside the bounds; "no_critical_point" otherwise (the engine may still return the best available critical point with a different nature).Echo of the variable names from the request.
The expression as parsed and simplified by SymPy.
Coordinates of the best critical point found, ordered to match
variables. null if no critical points were located inside the domain.Function value at
optimal_point.All distinct critical points found within the domain, each with its classification.
Present only for 2-variable functions. Contains a 60×60 evaluation grid over the domain for rendering a 3D surface or contour plot in Plotly.
Present only for 3-variable functions. Contains a 25×25×25 scattered point cloud for rendering an isosurface or volume in Plotly.
Human-readable summary of the outcome, including the optimal point coordinates, its nature, and the function value.
Visualization Layout
| Variable count | surface | volume | Recommended Plotly trace |
|---|---|---|---|
| 2 | ✓ present | null | Surface or Contour |
| 3 | null | ✓ present | Volume or Isosurface |
surface is always null for 3-variable functions, and volume is always null for 2-variable functions. Check variables.length in the response before accessing either field.Example
Find the minimum off(x, y) = x² + y² over the domain [-5, 5] × [-5, 5]:
Critical-Point Classification Details
Critical points are found by running Newton’s method from a uniform grid of seed points inside the domain (6 seeds per axis for 2-variable functions, 4 per axis for 3-variable functions). Duplicate roots are removed by rounding coordinates to 5 decimal places. Classification uses the eigenvalues of the symbolic Hessian:| Eigenvalue pattern | nature |
|---|---|
| All λ > 0 | "min" |
| All λ < 0 | "max" |
| Mixed signs | "saddle" |
| Any |λ| < 1e-6 | "degenerate" |
The method uses a fixed seed grid, so critical points that lie very close to the boundaries of the domain, or functions with many local optima, may not all be discovered. Widen the bounds or increase the resolution if you suspect missed roots.