Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Here is an interesting problem: You want to find for a fixed $j$, $1 \leq j \leq (n-s)$ the optima of the sum $\sum\limits_{k=1}^j \frac{1}{2+\gamma(s_k-2)}$ where $0<\gamma<1$, each $s_k$, $1 \leq k \leq j$, takes only positive integer (i.e. discrete) values in $1 \leq s_i \leq (n-s-(j-1))$ and $n,s$ are approprietly defined positive integers in order for the problem to make sense s.t. $n>s>0$. It also holds that $\sum\limits_{k=1}^j s_k = n-s$.

Is there a way to find the optima without using partial derivatives? I mean without taking each $s_k$ to belong to the close interval $[1, (n-s-(j-1))]$, and then restrict again to the initial domain approximating the optimal values found?

For example when $n=16$, $s=3$ and $j=4$ intuition says that the allocation of $n-s$ that makes the sum max is $s_1=s_2=s_3=1$ and $s_4=10$. While the sum is minimized when $s_1=s_2=s_3= 3$ and $s_4=4$.

In general an idea would be for someone to take cases whether $(n-s) \mod j = 0$ or not.

share|improve this question
why introduce unnecessary variables? why not call $t=n-s$ and forget about $n$ and $s$? –  leonbloy Apr 10 '12 at 19:30
yes you have a point here, $n$ and $s$ are fixed so be $n-s$. –  pebox11 Apr 10 '12 at 19:39

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.