TheMadCapBeta
I'm given an n-dimensional function such that
f(x1,x2,...,xn) = a1*x1 + a2*x2 +...+ an*xn
where a1, a2, ...,an are all positive numbers. This is with the restraint that
x1^2 + x2^2 + ... + xn^2 = 1
Using Lagrange multipliers (I'll use 'L' for Lambda):
a1 = L(2*x1)
a2 = L(2*x2)
...
an = L(2*xn)
Solving for L,
L = a1/(2*x1) = a2/(2*x2) = ... = an(2*xn) [1]
So, generally, xn = an/(2*L). Plugging into the constraint function, I get:
(a1/2*L)^2 + (a2/2*L)^2 + ... + (an/2*L)^2 = 1
(1/4*l^2)*(a1^2 + a2^2 + ... + an^2) = 1
L = sqrt(a1^2 + a2^2 + ... + an^2)/2
So, for each x, generally,
xn = an/sqrt(a1^2 + a2^2 + ... an^2) [2]
Which implies that a1 = a2 = ... = an from [1]
a1/(2*L) = a2/(2*L) = ... = an/(2*L)
So [2] is basically my critical point.
Plugging back into f(...) I get
f(x1,x2,...,xn) = a1*(a1/sqrt(a1^2 + a2^2 + ... + an^2)) ...etc
<=> ... (a1^2 + a2^2 + ... + an^2)/sqrt(a1^2 + a2^2 + ... + an^2)
Furthermore...
<=> ... sqrt(a1^2 + a2^2 + ... + an^2)
Since a1 = a2 = ... = an, then we can say (using an arbitrary (a))
<=> ... sqrt(n*a^2) <=> a*(sqrt(n)).
So, to my question (heh), for the minimum value it's obvious that it would be when n = 0. But I'm a little confused as to what the maximum would be.
Say a constant k = a, then would it be k*(sqrt(n))?? Just a simple question I guess, as it comes down to it. Thanks.
Actually, wouldn't the min be when n = 1, since there mustb e at least one variable. So the min would be k.
f(x1,x2,...,xn) = a1*x1 + a2*x2 +...+ an*xn
where a1, a2, ...,an are all positive numbers. This is with the restraint that
x1^2 + x2^2 + ... + xn^2 = 1
Using Lagrange multipliers (I'll use 'L' for Lambda):
a1 = L(2*x1)
a2 = L(2*x2)
...
an = L(2*xn)
Solving for L,
L = a1/(2*x1) = a2/(2*x2) = ... = an(2*xn) [1]
So, generally, xn = an/(2*L). Plugging into the constraint function, I get:
(a1/2*L)^2 + (a2/2*L)^2 + ... + (an/2*L)^2 = 1
(1/4*l^2)*(a1^2 + a2^2 + ... + an^2) = 1
L = sqrt(a1^2 + a2^2 + ... + an^2)/2
So, for each x, generally,
xn = an/sqrt(a1^2 + a2^2 + ... an^2) [2]
Which implies that a1 = a2 = ... = an from [1]
a1/(2*L) = a2/(2*L) = ... = an/(2*L)
So [2] is basically my critical point.
Plugging back into f(...) I get
f(x1,x2,...,xn) = a1*(a1/sqrt(a1^2 + a2^2 + ... + an^2)) ...etc
<=> ... (a1^2 + a2^2 + ... + an^2)/sqrt(a1^2 + a2^2 + ... + an^2)
Furthermore...
<=> ... sqrt(a1^2 + a2^2 + ... + an^2)
Since a1 = a2 = ... = an, then we can say (using an arbitrary (a))
<=> ... sqrt(n*a^2) <=> a*(sqrt(n)).
So, to my question (heh), for the minimum value it's obvious that it would be when n = 0. But I'm a little confused as to what the maximum would be.
Say a constant k = a, then would it be k*(sqrt(n))?? Just a simple question I guess, as it comes down to it. Thanks.
Actually, wouldn't the min be when n = 1, since there mustb e at least one variable. So the min would be k.
Last edited by a moderator: