4
$\begingroup$

I was trying a past paper from http://www.abacus.utwente.nl/tentamens/M%20-%20Stochastic%20Processes/1a%20-%20Stochastic%20Processes%20Februari%202007.pdf

Hint: Use the fact that $p \log (1 + x) + q \log (1 − x)$ is maximized when $x = p − q$.

Secondly it was written: Let $f : (-1,1) \rightarrow \mathbb{R} : x \mapsto p\log (1+x) + q \log (1-x).$ Then using the hint above, $f$ is maximised at $p-q$ and $f(p-q) = \log 2 + p\log p + q\log q.$


My first question is, how (possibly using analysis/calculus?) would you deduce/get that $p \log (1 + x) + q \log (1 − x)$ is maximized when $x = p − q?$

The other thing, I have trouble understanding what exactly does $f : (-1,1)$ mean? And how would I intepret/read the following line? Its a bit new to me as I have not seen functions written like the following before. $f : (-1,1) \rightarrow \mathbb{R} : x \mapsto p\log (1+x) + q \log (1-x).$

Lastly, it says that $f$ is maximised at $p-q$ and $f(p-q) = \log 2 + p\log p + q\log q.$ How do you get that $f(p-q) = \log 2 + p\log p + q\log q?$ I tried substituting it into $f(x)=p\log (1+x) + q \log (1-x)$, getting $f(p-q) = p\log(1+p-q) + q\log(1-p+q). $ How would I go about from there?

  • 0
    It is rather bad form to remove questions from your post when people have already addressed them in their answer; it makes it look like they don't know what they are talking about to new readers. It's worse if you then try to edit people's answers to remove content because of the content you decided to remove from your own post. And to try to do so 12 days after the fact on top of that...2012-04-02
  • 0
    Thanks, I already flagged this post stating the (valid) reason, why this question should be deleted. Appreciate if you could take a look.2012-04-02
  • 1
    I can't think of a reason why a question posted 12 days ago, with an accepted answer, should be deleted; unless, of course, you are somehow trying to cover your tracks for some reason... in which case it should *definitely* not be deleted.2012-04-02
  • 0
    @Arturo, I have rolled it back to a more suitable version.2012-04-02
  • 0
    @ArturoMagidin, I flagged this post to a moderator stating my reason to remove this question, and I am not covering my tracks, in my (original) post I am just asking for explanations to a few things, not trying to get anyone to solve the question for me, hence there is no need to 'cover my tracks'. I gave the reason to the moderator when i flagged it.2012-04-02
  • 0
    I'm not a moderator, so I can neither view, nor act on, flags. Again, I can think of no reason why it would now be appropriate to delete a question, twelve days after it was posted and an answer for it accepted. I still cannot understand your actions in deleting information, in trying to edit other people's answers to your question, or in now asking that the question be deleted.2012-04-02
  • 0
    Dear Heijden, we do not delete questions which have been answered (and which have already had one of their answers accepted!) except in extraordinary situations. In this particular case, two people have been kind enough to spend their time writing down very nice answers, and deleting the question would also delete *their* work.2012-04-03

2 Answers 2

4

For your first question, you can see that $p \log (1 + x) + q \log (1 − x)$ is maximized when $x=p-q$ by taking the derivative at setting it equal to $0$. We have $$0=\frac{d}{dx}(p \log (1 + x) + q \log (1 − x))=-\frac{p}{1+x}+\frac{q}{1-x}=\frac{-p(1-x)+q(1+x)}{(x+1)(x-1)}$$ and so $(q-p)+(p+q)x=0$ hence $x=\frac{p-q}{p+q}$, and since $q=1-p$ this simplifies to $x=p-q$. This tells us that $p \log (1 + x) + q \log (1 − x)$ has an extremum at $x=p-q$, and this extremum must be the maximum as making $x$ near $1$ or $-1$ makes $\log(1-x)$ or $\log(1+x)$ very negative, respectively.

For your second question, "$f: (-1,1)$" doesn't mean anything. However, the full statement "$f:(-1,1)\to \mathbb R$" means "$f$ is a function from $(-1,1)$ to $\mathbb R$ (the real numbers)". In your case, the statement $$f : (-1,1) \rightarrow \mathbb{R} : x \mapsto p\log (1+x) + q \log (1-x)$$ means "$f$ is a function from $(-1,1)$ to $\mathbb R$ such that $f(x)=p\log (1+x) + q \log (1-x)$ for any $x\in (-1,1)$ (any $x$ between $-1$ and $1$)".

Edit: To get that $f(p-q)=\log 2+p\log p+q\log q$, use the fact that $p=1-q$ and $q=1-p$ so $$\begin{eqnarray} f(p-q)&=&p\log(1+p-q) + q\log(1-p+q)\\ &=&p\log(1+p-(1-p)) + q\log(1-(1-q)+q)\\ &=&p\log(2p) + q\log(2q)\\ &=&p(\log 2+\log p) + q(\log 2+\log q)\\ &=&(p+q)\log 2+p\log p + q\log q\\ &=&\log 2+p\log p+q\log q. \end{eqnarray}$$

  • 2
    Why the downvote?2012-04-02
2

$f: (-1,1) \to \mathbb R$ just means that $f$ is a function defined on the interval $(-1,1)$ with values in the real line.

To find critical points of $f(x) = p \log(1+x) + q \log(1-x)$, solve $f'(x)=0$ for $x$. You should find exactly one critical point, at $x=p-q$ (if you remember that $p+q=1$). Note that this is a local maximum (e.g. by using the second derivative test, or noting that $\log(1+x)$ and $\log(1-x)$ are concave functions). If a differentiable function has only one critical point in an interval and it is a local maximum, then it is a global maximum on that interval.