Given a function $z$, with constraints $|x|\le 1$, $|y|\leq2$, find its minimum and maximum $$ z = x + |x-y|$$ ... $$\frac{\partial f(x, y)}{\partial x} = \frac{x-y}{|x-y|} + 1$$ $$\frac{\partial f(x, y)}{\partial y} = \frac{y-x}{|x-y|}$$ Thus, it yields a system of equations, and by solving it we're to find function's extrema points: \begin{cases} \frac{x-y}{|x-y|} + 1 = 0 \\ \frac{y-x}{|x-y|} = 0 \end{cases} I was unable to derive any solutions by brute force, and it is not quite clear to me if it is possible to do that with analytic methods. How to proceed?
2026-03-28 06:40:19.1774680019
Maximum / minimum values of $z = x + |x - y|$ with constraints
42 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
2
Using calculus here is unnecessary and, given the use of absolute values, arguably inappropriate.
What you'd like to do for the maximum is simultaneously make $x$ as large as possible and $x$ and $y$ as different as possible. The constraints $|x|\le1, |y|\le2$ allow you to this by choosing $x=1$ and $y=-2$, for a maximum value $z=1+|1-(-2)|=4$.
For the minimum, you want to simultaneously make $x$ as small as possible and $x$ and $y$ as close as possible. This happens with $x=y=-1$, for a minimum value of $z=-1+|-1-(-1)|=-1$.