Math question

(this is NOT homework… I’m 32 and just came up with an interesting question)
If I have a positive integer n, and look at all the ways it can be expressed as sums of positive integers (ie, 6 = 6, 5+1, 4+2, 3+3, 4+1+1, 3+2+1, 2+2+2, 2+2+1+1, 3+1+1+1, 2+1+1+1+1, 1+1+1+1+1+1), which one of those ways, if we replaced all the plus signs with multiplication signs, would result in the highest number? (For 6 it’s 3*3 = 9 > 2 * 2 *2 = 8).

What if we asked the equivalent question for real numbers?

My speculation is that:

It has something to do with e, as the best answer seems to be to divide into 3’s, and 3 isn’t a special number, whereas e is. Plus its the root of the natural logarithm, which might have something to do with this.

Well, let’s look at some other numbers.

12=4+4+4, 3+3+3+3, and also 2+2+2+2+2+2. 2^6=64, 3^4=81, and 4^3=64 also.

16=28, 44, 3+3+3+3+3+1, and 3+3+3+3+2+2 which when you do the work (2^8 and 4^4, etc), you get 256, 256, 243, and 324

So, basically, I can’t disprove you, but I have this feeling that it’s wrong.

Well, you can prove that for two numbers, the largest product would be obtained by multiplying half of the originl number by itself.

Let 2x be the original number. If you divide them into two numbers (x-n) and (x+n), you’ll get (x+n)(x-n)=x^2-n^2<X^2.

Oh, actually, you can do it for more divisions too. Taking the number 2x above and dividing it by 3, you’ll get (2/3)x. Now, you can prove that dividing it evenly into three parts produces the highest product, as above. Now, ((2/3)x)^3=(8x^3)/27, and this is greater than x^2 when x>27/8, that is, when 2x>27/4. You can do the same process for further divisions.

So basically, the larger the number, the more times you have to split it up to get higher product.

Wheee, that was fun!

And, generally, for real numbers, if you are dividing the number into n parts and multiplying, you should divide evenly. But that doesn’t tell us how to choose n, nor does it give us an answer for integers.
I’m starting to think that the answer for integers > 4 is some number of 3’s, then zero, one or two 2’s, with two 2’s being swappable for a 4.

Having a 5 (or anything greater) is always wrong, as 3 * 2 > 5.

Having three 2’s is always wrong, as 3 *3 > 2 * 2 * 2.

Having a 1 is always wrong.

So by process of elimination, we’re left with at most one 4 (or two 2’s), and nothing else but 3’s.

Interesting. First off, we can assume any expansion containing a 1 is less than ideal, because it would be better to combine into something else. With that in mind, let’s pick an arbitrary (but larger than 6) number, and list the possible expansions. How about 24?

Two-number:
22, 2
21, 3
20, 4
19, 5

12, 12

The largest of these is 12, 12. This is the typical Calculus/Pre-calculus problem about enclosing a maximum area with a specific amount of fencing.

Three-number:
20, 2, 2 = 80
19, 3, 2 = 114
18, 4, 2 = 144
18, 3, 3 = 162
17, 5, 2 = 170
17, 4, 3 = 204
16, 6, 2 = 192
16, 5, 3 = 240
16, 4, 4 = 256

The general pattern is that the small numbers are getting bigger and the big numbers are getting smaller. And the product is (in general) getting bigger. Therefore, I hypothesize that the ideal (three-number) solution is when all three numbers are equal, which is
8, 8, 8 = 512

In general, (I’m guessing) we want all the numbers to be the same or as close to the same as possible. IF this is true (a big if) then…

Say we started with the number x, and assume it’s divisible by just about anything, just for sake of argument. To make all the numbers equal, the possibilities are:

x/2, x/2 = x[sup]2[/sup]/4
x/3, x/3, x/3 = x[sup]3[/sup]/27
x/4, x/4, x/4, x/4 = x[sup]4[/sup]/256
x/n, x/n, x/n, x/n, x/n, x/n … (out to n numbers) = (x[sup]n[/sup])/(n[sup]n[/sup])

I guess the question is then: At what value of n is (x[sup]n[/sup])/(n[sup]n[/sup]) maximized?

This is of course assuming that letting all the numbers be the same is a good idea. Which I’m not sure if it is.

Yeah, my solution assumes positive real numbers. However, I would guess that the same would apply, more or less, for integers, just picking the closest values to the the “ideal” values.

And btw, my second post did say how to determine number of divisions, though again you’d have to find closest integer values.

Ahh, good point. The place where the changeover occurs between dividing into n and dividing into n+1 parts is the point where x^n/n^n == x^n+1/n+1^n+1.

So the changeover points are 4, 27/4, 256/27, 3125/256, etc.

(3^3 = 27, 4^4 = 256, 5^5 = 3125, and so forth)

which equal
4
6.75
9.48
12.20
14.92

an ever-increasing sequence of numbers whose difference sure looks like it’s approaching e to me.

So e equals lim (n->inf) (n+1^n+1)/n^n - n^n/n-1 ^ n-1?

Yep. Damned if I know how to prove it, though.

I assume it is since (X+n)(X-n)=X^2-n^2

Nope! The limit equals 1.

You sure about that? Maple says it’s e (and not just approximately either) with no hesitation.

I think this is entirely likely to be true. Basically, what you’ve shown is that you can make the product of any two “unequal parts” larger by making them equal.

Taking the derivative of this with respect to n gives

(x/n)[sup]n[/sup] (ln (x/n) - 1)

which vanishes when x/n = e. It seems likely, then, that the best partition strategy would be one where you got n as close to x/e as possible (as the OP suggested.)

Took a shower to clear my mind.

First of all, it had nothing to do with e, but rather primes.

Lemma 1
Given a composite number m>4, m can be decomposed into a sum=m with a product greater than m.

Assume m=/= p^2 (p prime). m=ab with a>b. a must be greater than sqrt(m) and b must be >= 2 since m is composite. the sum a+a+a+a+…+a= a x b = m. This give a product of a^b which due to the bounds on a and b noted above must be larger than sqrt(m)^2 hence is greater than m.

Assume m=p^2 (p prime). Thus m = p+p+…+p=p x p. This product results in p^p. Since m>4, p>2 thus p^p>p^2
:cool:
So now we know that we need to decompose the number into a sum of primes (or 4’s). Our earlier examples indicate that these should be 2’s and or 3’s (and maybe 4’s since 2+2 = 2x2)

Lemma 2
Given n>4, (n-2)x2 > n
Since n>4, (n-2)>(n/2). Thus 2(n-2)>2(n/2) and therefore 2x(n-2)>n
:cool:

But a similar proof would work for 3 with the added note that 5=2+3 and 2x3=6
So we have established that we need to reduce it to a sum of 1’s, 2’s, 3’s, and 4’s.
we know that reducing 4’s to 2’s does not change the problem, so lets look at 3+3=2+2+2. This reduction gives us the products 9>8 so it is apparent that we want to keep pairs of 3’s. Similar reasoning gives us 3=2+1 and the product 3>2 as a rationale for keeping singleton 3’s. Obviously, we can easily show we do not want to reduce 2’s into 1’s.

Theorem
Given a natural number n, the partition that yields the maximum product is that partition which contains all 3’s with a posible exeption of one 2 if n = 2(mod 3) or two 2’s (or equivalently one 4) if n = 1(mod 3).

I did it by hand on the back of an envelope. I could have made an error when simplifying the expression. I’ll accept Maple’s calculations over mine.
But as noted in my last post, e has nothing to do with the problem but rather combinations of 2’s and 3’ (mostly 3’s).

I already proved the 2’s and 3’s business back in post 5. e figures into the version that includes real numbers, not integers. If you’re going to divide 15.72341 into a finite number of positive real numbers which sum back to it, how do you do so to maximize their product?

Simple. Find the derivative of (n/x)^x which is [(n/x)^x] [ln(n/x)-1]
Find the zero which only occurs when ln(n/x) = 1, thus (n/x)must equal e.
Therefore x=n/e
Piece of cake

Wikipedia says that you can get the expression from the limit definition of e. I’m at a loss to figure out how it can be done, though.

The relevant “limit definition of e” is the definition e = lim[sub]n->infty[/sub] a[sub]n[/sub], where a[sub]n[/sub]=(1+1/n)[sup]n[/sup]. MaxTheVool’s expression can be written as
(n+1)[sup]n+1[/sup]/n[sup]n[/sup] - n[sup]n[/sup]/(n-1)[sup]n-1[/sup] = (n+1)a[sub]n[/sub]-na[sub]n-1[/sub]=a[sub]n[/sub]+n(a[sub]n[/sub]-a[sub]n-1[/sub]).
It’s kind of tedious, but it Can Be Shown that a[sub]n[/sub]-a[sub]n-1[/sub] approaches 0 at least quadratically in 1/n; so the quantity n(a[sub]n[/sub]-a[sub]n-1[/sub]) approaches zero, leaving just a[sub]n[/sub] which (by definition) approaches e.