sum of two positive numbers that their sum is 1

Tom2013

New member
Joined
Jul 17, 2013
Messages
7
I am having problems with the following problem:How could two nonnegative numbers be chosen so that their sum was 1 and the sum of their squares was as large as possible and as small as possible?
How do I find the largest number and the smallest one?
Thank you
 
x+y=1 => y=1-x (x,y>=0)
x2+y2=x2+(1-x)2=x2+1-2x+x2=2x2-2x+1, f(x)=2x2​-2x+1
f'(x)=4x-2
f'(x)=0 => x=1/2
0<=x<1/2: f'(x)<0
x>1/2: f'(x)>0
max=f(0)=1 and min=f(1/2)=1/2.

So, two nonnegative numbers that their sum is 1 and the sum of their squares is as large as possible(=max), are x=0, y=1
and
two nonnegative numbers that their sum is 1 and the sum of their squares is as small as possible(=min), are x=1/2, y=1/2
 
x+y=1 => y=1-x (x,y>=0)
x2+y2=x2+(1-x)2=x2+1-2x+x2=2x2-2x+1, f(x)=2x2​-2x+1
f'(x)=4x-2
f'(x)=0 => x=1/2
0<=x<1/2: f'(x)<0
x>1/2: f'(x)>0
max=f(0)=1 and min=f(1/2)=1/2.

So, two nonnegative numbers that their sum is 1 and the sum of their squares is as large as possible(=max), are x=0, y=1

Or x= 1, y= 0! :p

two nonnegative numbers that their sum is 1 and the sum of their squares is as small as possible(=min), are x=1/2, y=1/2
 
This problem can be done without Calculus. Once you have y= 1- x and substitute that into \(\displaystyle y= x^2+ y^2\) to get \(\displaystyle y= 2x^2- 2x+ 1\). y is a quadratic opening upward so its lowest point is at its vertex. And you can get that by "completing the square". \(\displaystyle 2x^2- 2x+ 1= 2(x^2- x)+ 1\). Half of the coefficient of x is 1/2 and the square of that is 1/4. That is, adding 1/4 to \(\displaystyle x^2- x\) gives \(\displaystyle x^2- x+ 1/4= (x- 1/2)^2\). So adding and subtracting 1/4 inside the parentheses gives \(\displaystyle y= 2(x^2- x+ 1/4- 1/4)+ 1= 2(x- 1/2)^2- 2(1/2)+ 1= 2(x- 1/2)^2+ 1/2\). \(\displaystyle (x- 1/2)^2\) will be 0 when x= 1/2 so that \(\displaystyle 2(x- 1/2)^2+ 1/2\) will be 1/2 when x= 1/2. For any other value of x, \(\displaystyle (x- 1/2)^2\) will be positive so \(\displaystyle 2(x+ 1/2)^2+ 1/2\) will be greater than 1/2. The minimum value for that function is 1/2 which occurs when x= 1/2.
 
Top