Skip to main content
3 of 3
Correct last case
Dirk
  • 12.7k
  • 6
  • 54
  • 97

Here is an approach via Langange multipliers: The Lagrangian of the constrained problem is

$$L(x,\lambda) = x_1\cdots x_n + x_2\cdots x_n + x_n - \lambda(\sum_{i=1}^n x_i - n-C).$$

The solution is a critical point of this. Taking the derivatives of $L$ with respect to all the $x_i$ you get \begin{align} x_2\cdots x_n -\lambda & = 0\\ x_1x_3\cdots x_n + x_3\cdots x_n - \lambda & = 0\\ \vdots\qquad & \quad \vdots\\ x_1\cdots x_{n-2}x_n + \cdots + x_n - \lambda & = 0. \end{align} The first equation gives $$\lambda = x_2\cdots x_n$$ and we multiply the further $i$th equation with $x_i$ to get \begin{align} x_1\cdots x_n -\lambda x_1 & = 0\\ x_1\cdots x_n + x_2\cdots x_n - \lambda x_2 & = 0\\ \vdots\qquad & \quad \vdots\\ x_1\cdots x_n + x_2\cdots x_n + x_i\cdots x_n - \lambda x_i & = 0\\ \vdots\qquad & \quad \vdots\\ x_1\cdots x_n + x_2\cdots x_n +\cdots + x_{n-1}x_n + x_n - \lambda x_n & = 0. \end{align} Plugging the $i$th equation into the $(i+1)$st (for $i\leq n-1$) and using $\lambda = x_2\cdots x_n$ we get $$ \lambda(x_i - x_{i+1}) + \frac{\lambda}{x_2\cdots x_i} = 0 $$ and $$ \lambda(x_{n-1}-x_n) + \frac{\lambda}{x_2\cdots x_{n-1}}= 0. $$ From this I get the recursion \begin{align} x_2 & = x_1 + 1\\ x_3 & = x_2 + \tfrac{1}{x_2}\\ x_4 & = x_3 + \tfrac{1}{x_2 x_3}\\ \vdots & \\ x_{i+1} & = x_i + \tfrac{1}{x_2\cdots x_i}\\ \vdots & \\ x_n & = x_{n-1} + \tfrac{1}{x_2\cdots x_{n-1}}. \end{align} (This contradicts your claim that $(x_1,\dots, x_n) = (m,m+1,\dots,m)$…)

It remains to determined $x_1$ which can in principle be done by the constraint $\sum_i x_i = n+C$, but I haven't tried…

Dirk
  • 12.7k
  • 6
  • 54
  • 97