For some ${n \in \mathbb{N}}$ and ${f(x_1, x_2, x_3, x_5,...) = 1^{x_1}.2^{x_2}.3^{x_3}.5^{x_5}.7^{x_7}....}$
${x_i \in \mathbb{W}}$
Find ${x_1, x_2, x_3, x_5,...}$ such that ${f(x_1, x_2, x_3, x_5,...)}$ is maximum and ${1.x_1 + 2.x_2 + 3.x_3 + 5.x_5 + ... = n}$
Sorry if already asked, did not know how to search this...
Note that $3\cdot(x-3)>x$ when $x\geq5$. Therefore we should replace any factor $x\geq5$ by the pair $3$, $x-3$. Furthermore $4=2\cdot 2$, and a factor $1$ is of no help. It follows that we should choose all factors $\in\{2,3\}$. In addition note that $2+2+2=3+3$, but $2^3<3^2$. This means that all factors should be $3$, except at most two factors $2$.
From these facts it is not too difficult to arrive at the maximal product for given factor sum $n$.