# Tag Info

0

When solving your SVM problem, you'll be optimizing a Lagrangian subject to KKT conditions. Specifically, something like: $$L(x)=f(x)-\sum_k \lambda_k c_k(x),$$ where your constraint satisfies $c_k(x)\geq 0$ and $\lambda_k\geq 0$. The optimum is achieved when the gradient of the above lagrangian is equal to 0 and $\lambda_i\geq 0$ and $\lambda_i c_i(x)=0$ ...

1

I can provide a solution without using Lagrange multipliers. $2x^2+y^2-y=2x^2+(y-\frac{1}{2})^2-\frac{1}{4}$ The coldest point is $\left(0,\frac{1}{2}\right)$, where the temperature is $-\frac{1}{4}$ The hottest point must be somewhere along the circle $x^2+y^2=1$, since the further away the a point is from $\left(0,\frac{1}{2}\right)$, the hotter it is. ...

0

Let $(x_1,y_1)$ and $(x_2,y_2)$ be two points in $\mathbb{R}^2$. The squared distance between these two points is $$f (x_1, x_2, y_1, y_2) := (x_1 - x_2)^2 + (y_1 - y_2)^2$$ If we want $(x_1,y_1)$ to be on the parabola and $(x_2,y_2)$ to be on the line, then we have two equality constraints, namely, $y_1 = x_1^2$ and $y_2 = x_2 - 2$. We build the ...

0

What you have as "obvious" is not quite correct here. You have $d(x,y)= \sqrt{(x- x_0)^2+ (y- y_0)^2}$, the distance from an unknown point, $(x, y)$ to a fixed point $(x_0, y_0)$. What you want to minimize is the distance between two unknown points, say, $d(x_1, y_1, x_2, y_2)= D= \sqrt{(x_2- x_1)^2+ (y_2- y_1)^2}$. Since those are required to be on two ...

3

I can provide a solution without using a Lagrange Multiplier. Let us call the closest point on the parabola to the line $\left(x_0,x_0^2\right)$. Then $2x_0=1$, since the tangent line to the parabola at that point must be parallel to the line $y-x+2=0$. (If it is unclear why, imagine rotating and translating the graph so that the line $x-y+2=0$ becomes the ...

1

You wish to maximize $A = f(x,y) = {1 \over 2} (2 x) (2 y) = 2 x y$ subject to the constraint $g(x,y) = x^2 + 4 y^2 - 1 = 0$. Form the Lagrangian: ${\cal L}(x,y,\lambda) = f(x, y) - \lambda g(x,y) = 2 x y - \lambda (x^2 + 4 y^2 - 1)$. Take the three derivatives and set them to zero: ${\partial {\cal L}(x,y,\lambda) \over \partial x} = 2 y - 2 \lambda x ... 2 The extremal temperatures are taken either in the interior$D$or on the boundary$\partial D$of the unit disk. Writing $$T(x,y)=2x^2+\left(y-{1\over2}\right)^2-{1\over4}$$ we see that the graph of$T$is a paraboloid with its apex at$P_1=\bigl(0,{1\over2}\bigr)\in D$, and there are no other stationary points of$T$in$D$. Take note of ... 1 Write $$T (x,y) = 2 x^2 + y^2 - y = 2 x^2 + \left(y - \frac{1}{2}\right)^2 - \frac{1}{4} \geq -\frac{1}{4}$$ Thus, the coldest point is$(0,\frac{1}{2})$, where the temperature is$-\frac{1}{4}$. The hottest point must be on the circle$x^2 + y^2 = 1$, which is the domain of interest's boundary. Introduce the Lagrangian $$\mathcal{L} (x,y,\lambda) = T ... 0 Your cost function can be simply$$f(x, y) = x^{1/4} y^{3/4}$$since the profit,$$p(x, y) = 20 - 8 f(x, y)$$(that is 10% of sales less than the advert cost of 20). Formulate the problem as$$\arg \underset{x, y}{\max} \, x^{1/4} y^{3/4}$$Subject to: x + y = 20. Therefore,$$L(x, y, \lambda) = x^{1/4} y^{3/4} - \lambda (x + y - 20)$$Please ... 1 In this case, simple geometric considerations tell you that you have a minimum: the objective function is the square of the distance from the origin and the constraint is the equation of a plane. More generally, one can examine the bordered Hessian to determine the nature of the stationary points found via Lagrange multipliers. In this case, Hf = 2I_3 ... 1 Well you can always compare it to other values. For example, take x=1, y=1, z=10, x+y+z=12, and f(x)=1+1+100=102>48 So 48 has to be a minimum. 1 The Lagrangian is$$L(x,\lambda) = \tfrac{1}{2} x^T Q x + \lambda^T ( A x - b)$$The optimality conditions are$$\begin{bmatrix} Q & A^T \\ A & 0 \end{bmatrix} \begin{bmatrix} x \\ \lambda \end{bmatrix} = \begin{bmatrix} 0 \\ b \end{bmatrix}$$This is a symmetric indefinite linear system and can be solved for the combined value of (x,\lambda). But ... 1 You asked where exactly you have made a mistake: Multiplying equations 1,2,3 by x,y,z we obtain that 2x^2=4y^2=6z^2. This is correct. (And, since you know what the solution should be, you can check for yourself, that the solution fulfills this equation.) From here I found the corresponding multiples that x^2 and y^2 are in terms of z and ... 0 You shouldn't be solving this with a Lagrange multiplier. You only have two variables and one linear condition. Substitute w_2=1-w_1 and optimise with respect to w_1 without constraints. If you really want to do it with a Lagrange multiplier, write w^\top e=1, where e is the vector with entries 1; then differentiating$$ w^\top ... 0 You could note that$(0,0,0)$is a global minimum of$f$and is strictly feasible. Hence the multipliers will be zero at the minimum. 1 It is correct. Just a quick reminder: Note that, in general, for inequality constraint$g(x) \leq 0$, we would consider$g(x)\mu = 0. Hence, we should have $$\lambda(x-y+2z-12)=0\\ \mu(x+2y+3z-8)=0 .\\$$ But that is the same as what you have written down. 2 From \begin{align*} x &= \lambda(x-3)\\ y &= \lambda(y-2) \\ z &= \lambda(z-1) \end{align*} we see thatz \neq 1$and$\lambda = z/(z-1)$whence$y(z-1) = z(y-2)$which gives$y = 2z$. Likewise$x(z-1) = z(x-3)$or$x = 3z$. Plugging these into the constraint equation $$(x-3)^2 + (y-2)^2 + (z-1)^2 = 1$$ gives$14(z-1)^2 = 1$or$z = 1 \pm ...

1

This is a bad exercise, since the answer is much easier to get by noting that we're looking for the points closest to and farthest from the origin on the sphere of radius $1$ around the point $u=(3,2,1)$, which are $u\pm\frac u{|u|}$. If you really want to do it the hard way, you can solve, say, your third equation for $\lambda$, substitute that into the ...

1

We are asked to maximize $U(x_1,x_2)$ subject to $2x_1+5x_2=40$. We can rearrange the constraint to get $x_1=\frac 12(40-5x_2)$. We might as well maximize $U^3(x_1,x_2)=x_1x_2=\frac 12(40-5x_2)x_2$. Now take the derivative, set to zero, and you will have the value for $x_2$.

4

The consumer is solving $$\max x_1^{1/3}x_2^{1/2}$$ subject to $$2 x_1 + 5 x_2 \leq 40.$$ It should be clear that the constraint must bind ($2x_1 +5x_2=40$), since the objective is increasing in both $x_1$ and $x_2$. Using the method of lagrange multipliers, any optimal consumption plan must satisfy the following FOCs: $$1/3 x_1^{-2/3} x_2^{1/2}=2 ... 0 Let s=20 denote the given sum. As almagest noted, k(k+2)\lt(k+1)^2 shows that the factors can differ by at most 1. Thus there must be j factors of \left\lceil\frac sn\right\rceil and n-j factors of \left\lfloor\frac sn\right\rfloor, with j determined by$$j\left\lceil\frac sn\right\rceil+(n-j)\left\lfloor\frac sn\right\rfloor=s$$and thus ... 0 HINT: 2+2+2=3+3 2\times2\times2<3\times3 So in order to maximize the product, use as many 3s as possible. 2 At a stationary value of the objective f(x,y,z), subject to constraint g(x,y,z)=0, the level surface of the objective is kissing the constraint surface. This means the normals to the two surfaces are parallel which is expressed by there existing a real scalar \lambda such that \nabla f=\lambda \nabla g. The gradient \nabla h(\bf{x}) is a vector ... 0 Replace x=3-y to the equation$$z=x^2+(3-x)^2=2x^2-6x+9$$Take the first derivative to find the critical point(s)$$\frac{dz}{dx}=4x-6=0 \rightarrow x_c=\frac32$$Find the second derivative at x_c$$\frac{d^2z}{dx^2}=4$$Because second derivative is positive the critical point is a minimum. 1 By CS inequality:$$ x+y=(x,y)\cdot (1,1)\le \sqrt{x^2+y^2}\sqrt{2} $$Since x+y=3:$$ 3\le \sqrt{2}\sqrt{x^2+y^2} $$Now, squaring both sided yields$$ 9\le 2(x^2+y^2) $$In other words$$ x^2+y^2\ge \frac{9}{2} $$This lower bound is attained when x=y=3/2. 2 There are two ways of interpreting this question. The first is "what is the maximum possible product for a (finite) sequence of natural numbers whose sum is 20". The second is "Fix the natural number n. What is the maximum possible product for a sequence of n natural numbers whose sum is n". I assumed the first interpretation was correct. In which ... 0 First of all, what does D look like? It is a circle with radius 2 where a circle with radius 1 is cut out. In this particular problem, you can first find the maximum of f(x,y) on the circle with radius 1, which is D = \{ (x,y) \mid x^2+y^2 \le 1\}, so you have one inequality, thus you should be able to do so. Then, you can find the maximum of ... 1 The map$$ \left(x,y\right)\mapsto \left(\frac{x+y}{\sqrt{2}},\frac{x-y}{\sqrt{2}}\right) $$is an isometry of \mathbb{R}^2, hence your problem is equivalent to finding the extreme values of \frac{u^2-v^2}{2} over 1\leq u^2+v^2\leq 4. They clearly are \color{red}{\pm 2}, and they clearly occur at points of the outer boundary, also because f(x,y)=xy ... 1 I have not been able to find the original question and I give you here my approach hoping it will help you. We want to maiximize xyz subject to the constraint x^2+2 y^2+3 z^2=a with (x\geq 0) , (y\geq 0) , (z \geq 0). So, let us consider$$F=x y z +\lambda \left(x^2+2 y^2+3 z^2-a\right)$$Computing derivatives$$F'_x=y z+2 \lambda x=0\tag 1$$... 3 The relationship between the two formulations is that the partial derivatives of the second formulation give the vector components of the first, and the constraint g(\textbf x)=0. To use the approach given by the second formulation, one finds the partial derivatives of L with respect to x_1, x_2, \dots and \lambda:$$\frac{\partial L}{\partial ...

1

An appropriate Lagrangian is $$L(x,y,z,\lambda,\mu)=x^2+y^2+z^2+\lambda(x^2+y^2+2z^2-5)+\mu(x+2y+z-5).$$ The nontrivial partial derivatives are: $$L_x = 2x+2\lambda x+\mu \\ L_y=2y+2\lambda y+2\mu \\ L_z=2z+4z\lambda+\mu.$$ If $\lambda,\mu$ were given, these conditions would allow you to find $x,y,z$: indeed ...

2

Your setup is correct, in as much as you do indeed want to solve the system of three equations $$\nabla f = \lambda \nabla g$$ $$g = 0.$$ However you have to be extremely careful when doing so, as generally you will have many local extrema and saddle points in addition to the global extrema you search for. It is very easy to accidentally drop possible ...

1

The inequality also follows directly from the fact that the arithmetic mean is greater than the harmonic mean $\frac{x_1+\ldots+x_n}{n}\geq \frac{n}{\frac{1}{x_1}+\ldots+\frac{1}{x_n}}$.

4

METHODOLOGY $1$: As suggested in the comment from @EwanDelanoy, we can use the Cauchy-Schwartz Inequality when $x_i>0$ for all $i=1,\cdots,n$ by writing \begin{align} n^2&=\left(\sum_{i=1}^n (1)\right)^2\\\\ &=\left(\sum_{i=1}^n \sqrt{x_i}\,\frac{1}{\sqrt{x_i}}\right)^2\\\\ &\le \left(\sum_{i=1}^n x_i\right)\left(\sum_{i=1}^n ... 1 The Lagrangian equations are\begin{cases}\begin{align}2x&=-\lambda y\\2y&=-\lambda x\\2z&=2\lambda z\\z^2&=xy+1\end{align}\end{cases}$$A systematic approach is by noting that the first three form a parameteric linear system with determinant ... 3 If z=0 you have:$$ \begin{aligned} 2x&=-\lambda y\\ 2y&=-\lambda x\\ xy&=-1 \end{aligned} $$and the first two of these imply that \lambda^2=4 and that x=y or x=-y and the first of these is incompatible with x and y being real and satisfying the third equation. So you are left with x=-y and xy=-1... If z \ne 0 we have ... 0 Assume you want to optimize the system f(x_1,x_2) subject to g(x_1,x_2)=c. To assure that the constraing holds$$dg=\frac{\partial g}{\partial x_1}dx_1+\frac{\partial g}{\partial x_2}dx_2=0\Rightarrow dx_2=-\frac{\frac{\partial g}{\partial x_1}}{\frac{\partial g}{\partial x_2}}dx_1$$By definition f is optimized when$$df=\frac{\partial ...

2

The thing is like in the following picture. of wikipedia. For $f=d$ you increment $d$ until you touch $g=c$. In the moment of contact you take a minimum. If you go on, just before $f=d$ leaves the contact, you take the maximum. Thinking it well it is like parking! Really, the idea is so productive that is the base of the Morse's theory.

1

The level curves of $f$ represent single values of $f$ that increase in a direction parallel to the gradient. This means that, given a level curve that does not represent a local maximum, there is another level curve nearby whose value for $f$ is greater than the first curve. Imagine $g$ as a curve that cuts through a level curve of $f$ at a point $p$. ...

1

Parametrize the curve $g(x) = 0$ with $c(t)$ s.t $c(0) = p$ where $p$ is the local extrema of $f, c'(0) \not = 0$. Then you know that $f(c(t))$ has local min/max when $t = 0$ i.e; $$\frac{d}{dt} f(c(t)) |_{t=0} = \nabla f(p) \cdot c'(0) = 0$$ We also know that $\nabla g(p) \cdot c'(0) = 0$ and so there exists a non-zero scalar $\lambda$ s.t; \nabla f(p) ...

Top 50 recent answers are included