For every positive integer n, determine the greatest possible value of the quotient

$$\frac{1-x^n-(1-x)^n}{x(1-x)^n+(1-x)x^n}$$ where $0\lt x\lt1$

Ive never dealt with a question like this so im not sure how to approach it, hints aswell as answers would be appreciated

taken from SAMO 2016 senior round 3 http://www.samf.ac.za/content/files/QuestionPapers/s3q2016.pdf

  • $\begingroup$ i feel it would take the greatest value at $x=1/2$ the expression will be $2^n-2$ which can go to inifnity $\endgroup$
    – IrbidMath
    Aug 10, 2019 at 18:13
  • 2
    $\begingroup$ I have a filling this has to do something with a conditional probability if we flip a coin $n+1$ times. $\endgroup$
    – nonuser
    Aug 10, 2019 at 19:28
  • $\begingroup$ @Aqua so the numerator would be the possibility neither to have $n$ heads nor tails, i.e., there’s at least one head and one tail. $\endgroup$ Aug 10, 2019 at 20:16
  • $\begingroup$ Yes, but in say first n trails. @MichaelHoppe $\endgroup$
    – nonuser
    Aug 10, 2019 at 20:20
  • 1
    $\begingroup$ @Ameryr: Your feeling is right. And your formulation of the answer is actually equal to mine but yours is more comfortable and perhaps more useful for a proof. $\endgroup$
    – Piquito
    Aug 10, 2019 at 20:45

1 Answer 1


HINT.-Make a coordinate change by putting $\dfrac12 + x$ instead of $x$ you get $$f(x)=\frac{2^n-(1+2x)^n-(1-2x)^n}{(0.25-x^2)[(1+2x)^{n-1}+(1-2x)^{n-1}]}$$ It follows that the resulting function is such that $f(x)=f(-x)$ in other words the vertical $x=\dfrac12$ is an axis of symmetry for each of the original functions.

Taking now the derivative of $g(x)=\dfrac{1-x^n-(1-x)^n}{x(1-x)^n+(1-x)x^n}$ we can forget the positive denominator and get a numerator $A-B$ where $$A=(nx(1-x)^{n-1}+nx^n+x^n+nx^{n-1}(1-x)^{n+1}+(1-x)^{2n}\\B=nx^{n+1}(1-x)^{n-1}+nx^{n-1}+x^{2n}+(1-x)^n$$ Calculation gives for $A-B$ positive value for $\dfrac12-\epsilon$ and negative value for $\dfrac12+\epsilon$. This shows that the functions take a maximum at $x=\dfrac12$.

Consequently the required maximum is $$g\left(\dfrac12\right)=2^n-2$$

  • 1
    $\begingroup$ My guess, due to symmetry, is that maximum is achieved at $x = 1/2$ for all $n$, which indeed will simplify to what you wrote (also, equal to $2^n-2$). My idea was to substitute $y = 1-x$, consider the appropriate function of two variables, and maximize with Lagrange over the contour $x + y = 1$. It follows for sure that partial derivatives wrt to $x$ and $y$ should be equal. It might imply $x = y = 1/2$, but the expression is complicated and I don't really have time right now to check it. $\endgroup$
    – Ennar
    Aug 10, 2019 at 21:10
  • $\begingroup$ It's always nice to find different answers to the same problem. Regards. $\endgroup$
    – Piquito
    Aug 11, 2019 at 23:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.