Jump to content

Recommended Posts

Posted

Suppose a, b, and n are positive integers and a + b = n. For what values of a and b maximize ab?

 

The only way I know of maximizing ab is by drawing a table of values and comparing numbers. It seems though that if n = 2k, then the maximum is obtained when a = b = k. If n = 2k + 1, the maximum is obtain when a = k and b = k + 1. Is there an intuitive way of showing/deriving this though. I can't seem to think of anything.

Posted
Is there an intuitive way of showing/deriving this though. I can't seem to think of anything.
Yes, I believe there is, using Calculus.

 

We wish to maximize [math]x \cdot y[/math] subject to the constraint [math]x+y=n[/math]. Therefore, [math]y=n-x[/math], so our problem is equivalent to maximizing [math]f(x)=x(n-x)=nx-x^2[/math].

 

Taking the first derivative, (and noting that [math]f(x)[/math] is a downward pointing parabola, and thus, has only one local extrema, a global maximum), we get that [math]f'(x)=n-2x[/math], therefore the local maxima is at [math]x=n/2[/math].

 

Thus, if [math]x=2k[/math] ([math]k[/math] an integer), the maxima is at [math]x=k[/math], and substituting [math]x[/math] into the constraint equation implies that [math]y=k[/math] as well. However, if [math]n=2k+1[/math], then the maxima is achieved at [math]x = (2k+1)/2=k+1/2[/math], which is not an integer. Therefore, the closest integers are [math]x=k[/math] and [math]x=k+1[/math], which are both a distance of [math]1/2[/math] away from [math]x[/math], and thus, both optimal integer solutions. Again, applying the constraint equation shows that these [math]x[/math]-values correspond to [math]y=k+1[/math] and [math]y=k[/math] respectively.

 

If you have any questions about my explanation, I will gladly expound any requested points.

Posted

I've found that, especially with things like GCSE maths problems. It's like trying to break a nut with a lorry as opposed to your average nutcracker ;)

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.