Here's the problem: I start with $10$ dollars and toss a uniform coin $10$ times. Whenever it is a head I double my money and whenever it is a tail I half my money. What is the expected value of my money after the $10$ coin tosses?
I know the correct answer is $1.25^{10}=93$ dollars. However, what is wrong with the following solution?
Wrong solution:
The expected value of tossing a head is $5$. Therefore the expected times of doubling the money is $5$ times. Similarly the expected value of tossing a tail is $5$ so the expected times of halving the money is $5$ times. Therefore the expected value of the final money is $10\times2^{5}\times{1\over2}^5=10$ dollars.
Again, I know this solution is wrong experimentally and the $93$ solution is correct but what I want to know is where exactly goes wrong in this reasoning.
You are correct in stating that your final fortune is $$X:=10\cdot 2^D\cdot (1/2)^H$$ where $D$ is the number of times that you double your money and $H$ is the number of times that you halve your money. What you are arguing is that $$ E(X)=10\cdot 2^{E(D)}\cdot (1/2)^{E(H)} $$ But there is no law that permits you to apply expectation in this way.
As an aside, notice that $$\log X = \log(10) + D\log(2) + H\log(1/2)$$ so you can apply linearity of expectation to correctly conclude $$E(\log X)=\log(10).$$ But this is not the same as saying $E(X)=10$.