If nine coins are tossed, what is the probability that the number of heads is even?












4












$begingroup$


So there can either be 0 heads, 2 heads, 4 heads, 6 heads, or 8 heads.



We have $n = 9$ trials, find the probability of each $k$ for $k = 0, 2, 4, 6, 8$



$n = 9, k = 0$



$$binom{9}{0}bigg(frac{1}{2}bigg)^0bigg(frac{1}{2}bigg)^{9}$$



$n = 9, k = 2$



$$binom{9}{2}bigg(frac{1}{2}bigg)^2bigg(frac{1}{2}bigg)^{7}$$



$n = 9, k = 4$
$$binom{9}{4}bigg(frac{1}{2}bigg)^4bigg(frac{1}{2}bigg)^{5}$$



$n = 9, k = 6$



$$binom{9}{6}bigg(frac{1}{2}bigg)^6bigg(frac{1}{2}bigg)^{3}$$



$n = 9, k = 8$



$$binom{9}{8}bigg(frac{1}{2}bigg)^8bigg(frac{1}{2}bigg)^{1}$$



Add all of these up:



$$=.64$$ so there's a 64% chance of probability?










share|cite|improve this question











$endgroup$








  • 1




    $begingroup$
    Zero is an even number, too.
    $endgroup$
    – saulspatz
    9 hours ago










  • $begingroup$
    What about $k=0$?
    $endgroup$
    – Dbchatto67
    9 hours ago






  • 1




    $begingroup$
    Either Heads or Tails but not both must be even, so $.5$
    $endgroup$
    – lulu
    9 hours ago






  • 3




    $begingroup$
    Your arithmetic is wrong somewhere because it should sum to $0.50$. You can match the chance of $k$ heads with the chance of $9-k$. The powers of $frac 12$ always give $frac 1{2^9}$, so it is probably in your computation of the combination numbers. Your approach is fine, if much harder than the symmetry arguments.
    $endgroup$
    – Ross Millikan
    9 hours ago








  • 2




    $begingroup$
    Ross Millikan is correct; you need to double-check your arithmetic. The last two terms of each product multiply to 1/512. The first terms of each product are 1, 36, 126, 84 and 9. Those add to 256. So you should be getting 256/512 which is 1/2. Always check your arithmetic.
    $endgroup$
    – Eric Lippert
    7 hours ago
















4












$begingroup$


So there can either be 0 heads, 2 heads, 4 heads, 6 heads, or 8 heads.



We have $n = 9$ trials, find the probability of each $k$ for $k = 0, 2, 4, 6, 8$



$n = 9, k = 0$



$$binom{9}{0}bigg(frac{1}{2}bigg)^0bigg(frac{1}{2}bigg)^{9}$$



$n = 9, k = 2$



$$binom{9}{2}bigg(frac{1}{2}bigg)^2bigg(frac{1}{2}bigg)^{7}$$



$n = 9, k = 4$
$$binom{9}{4}bigg(frac{1}{2}bigg)^4bigg(frac{1}{2}bigg)^{5}$$



$n = 9, k = 6$



$$binom{9}{6}bigg(frac{1}{2}bigg)^6bigg(frac{1}{2}bigg)^{3}$$



$n = 9, k = 8$



$$binom{9}{8}bigg(frac{1}{2}bigg)^8bigg(frac{1}{2}bigg)^{1}$$



Add all of these up:



$$=.64$$ so there's a 64% chance of probability?










share|cite|improve this question











$endgroup$








  • 1




    $begingroup$
    Zero is an even number, too.
    $endgroup$
    – saulspatz
    9 hours ago










  • $begingroup$
    What about $k=0$?
    $endgroup$
    – Dbchatto67
    9 hours ago






  • 1




    $begingroup$
    Either Heads or Tails but not both must be even, so $.5$
    $endgroup$
    – lulu
    9 hours ago






  • 3




    $begingroup$
    Your arithmetic is wrong somewhere because it should sum to $0.50$. You can match the chance of $k$ heads with the chance of $9-k$. The powers of $frac 12$ always give $frac 1{2^9}$, so it is probably in your computation of the combination numbers. Your approach is fine, if much harder than the symmetry arguments.
    $endgroup$
    – Ross Millikan
    9 hours ago








  • 2




    $begingroup$
    Ross Millikan is correct; you need to double-check your arithmetic. The last two terms of each product multiply to 1/512. The first terms of each product are 1, 36, 126, 84 and 9. Those add to 256. So you should be getting 256/512 which is 1/2. Always check your arithmetic.
    $endgroup$
    – Eric Lippert
    7 hours ago














4












4








4


1



$begingroup$


So there can either be 0 heads, 2 heads, 4 heads, 6 heads, or 8 heads.



We have $n = 9$ trials, find the probability of each $k$ for $k = 0, 2, 4, 6, 8$



$n = 9, k = 0$



$$binom{9}{0}bigg(frac{1}{2}bigg)^0bigg(frac{1}{2}bigg)^{9}$$



$n = 9, k = 2$



$$binom{9}{2}bigg(frac{1}{2}bigg)^2bigg(frac{1}{2}bigg)^{7}$$



$n = 9, k = 4$
$$binom{9}{4}bigg(frac{1}{2}bigg)^4bigg(frac{1}{2}bigg)^{5}$$



$n = 9, k = 6$



$$binom{9}{6}bigg(frac{1}{2}bigg)^6bigg(frac{1}{2}bigg)^{3}$$



$n = 9, k = 8$



$$binom{9}{8}bigg(frac{1}{2}bigg)^8bigg(frac{1}{2}bigg)^{1}$$



Add all of these up:



$$=.64$$ so there's a 64% chance of probability?










share|cite|improve this question











$endgroup$




So there can either be 0 heads, 2 heads, 4 heads, 6 heads, or 8 heads.



We have $n = 9$ trials, find the probability of each $k$ for $k = 0, 2, 4, 6, 8$



$n = 9, k = 0$



$$binom{9}{0}bigg(frac{1}{2}bigg)^0bigg(frac{1}{2}bigg)^{9}$$



$n = 9, k = 2$



$$binom{9}{2}bigg(frac{1}{2}bigg)^2bigg(frac{1}{2}bigg)^{7}$$



$n = 9, k = 4$
$$binom{9}{4}bigg(frac{1}{2}bigg)^4bigg(frac{1}{2}bigg)^{5}$$



$n = 9, k = 6$



$$binom{9}{6}bigg(frac{1}{2}bigg)^6bigg(frac{1}{2}bigg)^{3}$$



$n = 9, k = 8$



$$binom{9}{8}bigg(frac{1}{2}bigg)^8bigg(frac{1}{2}bigg)^{1}$$



Add all of these up:



$$=.64$$ so there's a 64% chance of probability?







probability discrete-mathematics






share|cite|improve this question















share|cite|improve this question













share|cite|improve this question




share|cite|improve this question








edited 9 hours ago







Stuy

















asked 10 hours ago









StuyStuy

1909




1909








  • 1




    $begingroup$
    Zero is an even number, too.
    $endgroup$
    – saulspatz
    9 hours ago










  • $begingroup$
    What about $k=0$?
    $endgroup$
    – Dbchatto67
    9 hours ago






  • 1




    $begingroup$
    Either Heads or Tails but not both must be even, so $.5$
    $endgroup$
    – lulu
    9 hours ago






  • 3




    $begingroup$
    Your arithmetic is wrong somewhere because it should sum to $0.50$. You can match the chance of $k$ heads with the chance of $9-k$. The powers of $frac 12$ always give $frac 1{2^9}$, so it is probably in your computation of the combination numbers. Your approach is fine, if much harder than the symmetry arguments.
    $endgroup$
    – Ross Millikan
    9 hours ago








  • 2




    $begingroup$
    Ross Millikan is correct; you need to double-check your arithmetic. The last two terms of each product multiply to 1/512. The first terms of each product are 1, 36, 126, 84 and 9. Those add to 256. So you should be getting 256/512 which is 1/2. Always check your arithmetic.
    $endgroup$
    – Eric Lippert
    7 hours ago














  • 1




    $begingroup$
    Zero is an even number, too.
    $endgroup$
    – saulspatz
    9 hours ago










  • $begingroup$
    What about $k=0$?
    $endgroup$
    – Dbchatto67
    9 hours ago






  • 1




    $begingroup$
    Either Heads or Tails but not both must be even, so $.5$
    $endgroup$
    – lulu
    9 hours ago






  • 3




    $begingroup$
    Your arithmetic is wrong somewhere because it should sum to $0.50$. You can match the chance of $k$ heads with the chance of $9-k$. The powers of $frac 12$ always give $frac 1{2^9}$, so it is probably in your computation of the combination numbers. Your approach is fine, if much harder than the symmetry arguments.
    $endgroup$
    – Ross Millikan
    9 hours ago








  • 2




    $begingroup$
    Ross Millikan is correct; you need to double-check your arithmetic. The last two terms of each product multiply to 1/512. The first terms of each product are 1, 36, 126, 84 and 9. Those add to 256. So you should be getting 256/512 which is 1/2. Always check your arithmetic.
    $endgroup$
    – Eric Lippert
    7 hours ago








1




1




$begingroup$
Zero is an even number, too.
$endgroup$
– saulspatz
9 hours ago




$begingroup$
Zero is an even number, too.
$endgroup$
– saulspatz
9 hours ago












$begingroup$
What about $k=0$?
$endgroup$
– Dbchatto67
9 hours ago




$begingroup$
What about $k=0$?
$endgroup$
– Dbchatto67
9 hours ago




1




1




$begingroup$
Either Heads or Tails but not both must be even, so $.5$
$endgroup$
– lulu
9 hours ago




$begingroup$
Either Heads or Tails but not both must be even, so $.5$
$endgroup$
– lulu
9 hours ago




3




3




$begingroup$
Your arithmetic is wrong somewhere because it should sum to $0.50$. You can match the chance of $k$ heads with the chance of $9-k$. The powers of $frac 12$ always give $frac 1{2^9}$, so it is probably in your computation of the combination numbers. Your approach is fine, if much harder than the symmetry arguments.
$endgroup$
– Ross Millikan
9 hours ago






$begingroup$
Your arithmetic is wrong somewhere because it should sum to $0.50$. You can match the chance of $k$ heads with the chance of $9-k$. The powers of $frac 12$ always give $frac 1{2^9}$, so it is probably in your computation of the combination numbers. Your approach is fine, if much harder than the symmetry arguments.
$endgroup$
– Ross Millikan
9 hours ago






2




2




$begingroup$
Ross Millikan is correct; you need to double-check your arithmetic. The last two terms of each product multiply to 1/512. The first terms of each product are 1, 36, 126, 84 and 9. Those add to 256. So you should be getting 256/512 which is 1/2. Always check your arithmetic.
$endgroup$
– Eric Lippert
7 hours ago




$begingroup$
Ross Millikan is correct; you need to double-check your arithmetic. The last two terms of each product multiply to 1/512. The first terms of each product are 1, 36, 126, 84 and 9. Those add to 256. So you should be getting 256/512 which is 1/2. Always check your arithmetic.
$endgroup$
– Eric Lippert
7 hours ago










7 Answers
7






active

oldest

votes


















16












$begingroup$

The probability is $frac{1}{2}$ because the last flip determines it.






share|cite|improve this answer









$endgroup$









  • 4




    $begingroup$
    Though this answer is correct for this specific question, it is interesting to consider why it works. Consider: an unfair coin comes up heads 75% of the time, tails 25% of the time. We flip it nine times. Again, the last flip determines whether the total is odd or even. In this case, is it even 75% of the time, because the last flip is heads 75% of the time, or is it even 50% of the time, as it was before? Or is it even some other percentage of the time? Before you do the math, what's your gut feeling? And can you explain why your argument is only valid for a fair coin?
    $endgroup$
    – Eric Lippert
    2 hours ago










  • $begingroup$
    Interesting question Eric. Formally I would use recursion, let us define $O_n$ as the probability that we get an odd number of heads when flipping $n$ coins, and let $p$ be the probability the coin comes up as heads. Then the previous reasoning turns into the recurrence relation $O_n=(1-p)O_{n-1} + p(1-O_{n-1})=(1-2p)O_{n-1}+p$.
    $endgroup$
    – Jorge Fernández Hidalgo
    2 hours ago












  • $begingroup$
    Although I think things become clearer when we work with $ O_n=H_n+0.5$ as we obtain $H_n+0.5 = (1-p)(H_{n-1}+0.5) + p(0.5-H_{n-1})$ which tells us $H_n = H_{n-1}(1-2p)$. So as one can see $O_n$ approachs $frac{1}{2}$ and whether is does so in a monotone or alternating manner depends on whethere $pgeq 1/2$. Recall $O_1$ is simply $p$, so $H_1 = p-0.5$. In the case in which $p<0.5$ we have that $H_n$ is always negative and in the other case we have that $H_n$ alternates signs.
    $endgroup$
    – Jorge Fernández Hidalgo
    2 hours ago












  • $begingroup$
    That's a good analysis. My reason for bringing it up is: plainly the OP is relatively new to probability, so I think it is important to call out the assumptions when giving "shortcut" reasoning like this answer. The underlying assumption is that with eight coins, an even number of heads or tails is also 1/2. I think it is worthwhile calling that out. I wouldn't want the OP to deduce that for more general problems, they only need to consider the probability of the final flip.
    $endgroup$
    – Eric Lippert
    1 hour ago






  • 1




    $begingroup$
    Yes you are right, I was a bit careless when I wrote it, thank you for pointing out that detail!
    $endgroup$
    – Jorge Fernández Hidalgo
    1 hour ago





















8












$begingroup$

If there are an even number of heads then there must be an odd number of tails. But heads and tails are symmetrical, so the probability must be $1/2$.






share|cite|improve this answer









$endgroup$





















    5












    $begingroup$

    All the possible sequences of tosses (which are all equally likely) may be divided into the two categories "even number of heads" and "odd number of heads". You can then pair up each sequence in one category with the "flipped" version (flip every coin in the sequence around) in the other category. This shows that there are equally many sequences in each of the two categories. So the probability of landing in a specific one of them must be $frac12$.






    share|cite|improve this answer









    $endgroup$





















      3












      $begingroup$

      There are two cases here:




      • There's an even number of heads: 0, 2, 4, 6 or 8 heads

      • There's an odd number of heads: 1, 3, 5, 7 or 9 heads


      But notice that having an odd number of heads means having an even number of tails (e.g. 5 heads means 4 tails), so the second case is the same as:




      • There's an even number of tails: 0, 2, 4, 6 or 8 tails


      Since heads and tails are equally probable, we can, by symmetry, see that these two cases have the same probability. Therefore each must have probability $1/2$.






      share|cite|improve this answer









      $endgroup$













      • $begingroup$
        Ethan Bolker already gave this explanation 2 hours ago.
        $endgroup$
        – Paul Sinclair
        7 hours ago










      • $begingroup$
        @PaulSinclair Yes, he did. But I found this explanation clearer than Ethan's, which skips a number of steps.
        $endgroup$
        – CJ Dennis
        14 mins ago



















      2












      $begingroup$

      The easiest way to see this : Consider the number of heads we have in the first $8$ coins.




      • If this number is even, we need a tail, we have probability $frac{1}{2}$

      • If this number is odd, we need a head, we have probability $frac{1}{2}$


      Hence no matter what the $8$ coins delivered, we have probability $frac{1}{2}$ , which is the answer.






      share|cite|improve this answer









      $endgroup$









      • 1




        $begingroup$
        This is , by the way, true for EVERY number of coins (even for one coin).
        $endgroup$
        – Peter
        9 hours ago






      • 3




        $begingroup$
        Pedantic point: If zero coins are tossed, the probability of an even number of heads is 100%.
        $endgroup$
        – Brian
        7 hours ago










      • $begingroup$
        This answer presupposes that having an even number of heads and an odd number of heads in eight flips is equally likely, but we haven't proved that lemma.
        $endgroup$
        – Eric Lippert
        2 hours ago



















      2












      $begingroup$

      Your approach is good also, you probably made a mistake in calculations. The number of favorable outcomes is
      $$binom{9}{0}+binom{9}{2}+binom{9}{4}+binom{9}{6}+binom{9}{8}=1+36+126+84+9=256$$
      The number of all possible outcomes is $512$ thus the probability to get even number of heads is $0.5$.






      share|cite|improve this answer









      $endgroup$





















        1












        $begingroup$

        The probability generating function of a Binomiall random variable $Xsim text{Bin}(n, 1/2)$ with probability of success $1/2$ is given by
        $$
        g_{X}(t)=Et^X=sum_{k=0}^nP(X=k)t^k=sum_{k=0}^nbinom{n}{k}frac{t^k}{2^n}=frac{1}{2^n}(1+t)^n
        $$

        In particular the probability that $X$ is even is given by
        $$
        sum_{0leq kleq n, k,{text{even}}}P(X=k)=frac{g(1)+g(-1)}{2}=frac{1+0}{2}=frac{1}{2}.
        $$






        share|cite|improve this answer









        $endgroup$













          Your Answer





          StackExchange.ifUsing("editor", function () {
          return StackExchange.using("mathjaxEditing", function () {
          StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
          StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
          });
          });
          }, "mathjax-editing");

          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "69"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          noCode: true, onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3134991%2fif-nine-coins-are-tossed-what-is-the-probability-that-the-number-of-heads-is-ev%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          7 Answers
          7






          active

          oldest

          votes








          7 Answers
          7






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          16












          $begingroup$

          The probability is $frac{1}{2}$ because the last flip determines it.






          share|cite|improve this answer









          $endgroup$









          • 4




            $begingroup$
            Though this answer is correct for this specific question, it is interesting to consider why it works. Consider: an unfair coin comes up heads 75% of the time, tails 25% of the time. We flip it nine times. Again, the last flip determines whether the total is odd or even. In this case, is it even 75% of the time, because the last flip is heads 75% of the time, or is it even 50% of the time, as it was before? Or is it even some other percentage of the time? Before you do the math, what's your gut feeling? And can you explain why your argument is only valid for a fair coin?
            $endgroup$
            – Eric Lippert
            2 hours ago










          • $begingroup$
            Interesting question Eric. Formally I would use recursion, let us define $O_n$ as the probability that we get an odd number of heads when flipping $n$ coins, and let $p$ be the probability the coin comes up as heads. Then the previous reasoning turns into the recurrence relation $O_n=(1-p)O_{n-1} + p(1-O_{n-1})=(1-2p)O_{n-1}+p$.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            Although I think things become clearer when we work with $ O_n=H_n+0.5$ as we obtain $H_n+0.5 = (1-p)(H_{n-1}+0.5) + p(0.5-H_{n-1})$ which tells us $H_n = H_{n-1}(1-2p)$. So as one can see $O_n$ approachs $frac{1}{2}$ and whether is does so in a monotone or alternating manner depends on whethere $pgeq 1/2$. Recall $O_1$ is simply $p$, so $H_1 = p-0.5$. In the case in which $p<0.5$ we have that $H_n$ is always negative and in the other case we have that $H_n$ alternates signs.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            That's a good analysis. My reason for bringing it up is: plainly the OP is relatively new to probability, so I think it is important to call out the assumptions when giving "shortcut" reasoning like this answer. The underlying assumption is that with eight coins, an even number of heads or tails is also 1/2. I think it is worthwhile calling that out. I wouldn't want the OP to deduce that for more general problems, they only need to consider the probability of the final flip.
            $endgroup$
            – Eric Lippert
            1 hour ago






          • 1




            $begingroup$
            Yes you are right, I was a bit careless when I wrote it, thank you for pointing out that detail!
            $endgroup$
            – Jorge Fernández Hidalgo
            1 hour ago


















          16












          $begingroup$

          The probability is $frac{1}{2}$ because the last flip determines it.






          share|cite|improve this answer









          $endgroup$









          • 4




            $begingroup$
            Though this answer is correct for this specific question, it is interesting to consider why it works. Consider: an unfair coin comes up heads 75% of the time, tails 25% of the time. We flip it nine times. Again, the last flip determines whether the total is odd or even. In this case, is it even 75% of the time, because the last flip is heads 75% of the time, or is it even 50% of the time, as it was before? Or is it even some other percentage of the time? Before you do the math, what's your gut feeling? And can you explain why your argument is only valid for a fair coin?
            $endgroup$
            – Eric Lippert
            2 hours ago










          • $begingroup$
            Interesting question Eric. Formally I would use recursion, let us define $O_n$ as the probability that we get an odd number of heads when flipping $n$ coins, and let $p$ be the probability the coin comes up as heads. Then the previous reasoning turns into the recurrence relation $O_n=(1-p)O_{n-1} + p(1-O_{n-1})=(1-2p)O_{n-1}+p$.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            Although I think things become clearer when we work with $ O_n=H_n+0.5$ as we obtain $H_n+0.5 = (1-p)(H_{n-1}+0.5) + p(0.5-H_{n-1})$ which tells us $H_n = H_{n-1}(1-2p)$. So as one can see $O_n$ approachs $frac{1}{2}$ and whether is does so in a monotone or alternating manner depends on whethere $pgeq 1/2$. Recall $O_1$ is simply $p$, so $H_1 = p-0.5$. In the case in which $p<0.5$ we have that $H_n$ is always negative and in the other case we have that $H_n$ alternates signs.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            That's a good analysis. My reason for bringing it up is: plainly the OP is relatively new to probability, so I think it is important to call out the assumptions when giving "shortcut" reasoning like this answer. The underlying assumption is that with eight coins, an even number of heads or tails is also 1/2. I think it is worthwhile calling that out. I wouldn't want the OP to deduce that for more general problems, they only need to consider the probability of the final flip.
            $endgroup$
            – Eric Lippert
            1 hour ago






          • 1




            $begingroup$
            Yes you are right, I was a bit careless when I wrote it, thank you for pointing out that detail!
            $endgroup$
            – Jorge Fernández Hidalgo
            1 hour ago
















          16












          16








          16





          $begingroup$

          The probability is $frac{1}{2}$ because the last flip determines it.






          share|cite|improve this answer









          $endgroup$



          The probability is $frac{1}{2}$ because the last flip determines it.







          share|cite|improve this answer












          share|cite|improve this answer



          share|cite|improve this answer










          answered 9 hours ago









          Jorge Fernández HidalgoJorge Fernández Hidalgo

          75.9k1192195




          75.9k1192195








          • 4




            $begingroup$
            Though this answer is correct for this specific question, it is interesting to consider why it works. Consider: an unfair coin comes up heads 75% of the time, tails 25% of the time. We flip it nine times. Again, the last flip determines whether the total is odd or even. In this case, is it even 75% of the time, because the last flip is heads 75% of the time, or is it even 50% of the time, as it was before? Or is it even some other percentage of the time? Before you do the math, what's your gut feeling? And can you explain why your argument is only valid for a fair coin?
            $endgroup$
            – Eric Lippert
            2 hours ago










          • $begingroup$
            Interesting question Eric. Formally I would use recursion, let us define $O_n$ as the probability that we get an odd number of heads when flipping $n$ coins, and let $p$ be the probability the coin comes up as heads. Then the previous reasoning turns into the recurrence relation $O_n=(1-p)O_{n-1} + p(1-O_{n-1})=(1-2p)O_{n-1}+p$.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            Although I think things become clearer when we work with $ O_n=H_n+0.5$ as we obtain $H_n+0.5 = (1-p)(H_{n-1}+0.5) + p(0.5-H_{n-1})$ which tells us $H_n = H_{n-1}(1-2p)$. So as one can see $O_n$ approachs $frac{1}{2}$ and whether is does so in a monotone or alternating manner depends on whethere $pgeq 1/2$. Recall $O_1$ is simply $p$, so $H_1 = p-0.5$. In the case in which $p<0.5$ we have that $H_n$ is always negative and in the other case we have that $H_n$ alternates signs.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            That's a good analysis. My reason for bringing it up is: plainly the OP is relatively new to probability, so I think it is important to call out the assumptions when giving "shortcut" reasoning like this answer. The underlying assumption is that with eight coins, an even number of heads or tails is also 1/2. I think it is worthwhile calling that out. I wouldn't want the OP to deduce that for more general problems, they only need to consider the probability of the final flip.
            $endgroup$
            – Eric Lippert
            1 hour ago






          • 1




            $begingroup$
            Yes you are right, I was a bit careless when I wrote it, thank you for pointing out that detail!
            $endgroup$
            – Jorge Fernández Hidalgo
            1 hour ago
















          • 4




            $begingroup$
            Though this answer is correct for this specific question, it is interesting to consider why it works. Consider: an unfair coin comes up heads 75% of the time, tails 25% of the time. We flip it nine times. Again, the last flip determines whether the total is odd or even. In this case, is it even 75% of the time, because the last flip is heads 75% of the time, or is it even 50% of the time, as it was before? Or is it even some other percentage of the time? Before you do the math, what's your gut feeling? And can you explain why your argument is only valid for a fair coin?
            $endgroup$
            – Eric Lippert
            2 hours ago










          • $begingroup$
            Interesting question Eric. Formally I would use recursion, let us define $O_n$ as the probability that we get an odd number of heads when flipping $n$ coins, and let $p$ be the probability the coin comes up as heads. Then the previous reasoning turns into the recurrence relation $O_n=(1-p)O_{n-1} + p(1-O_{n-1})=(1-2p)O_{n-1}+p$.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            Although I think things become clearer when we work with $ O_n=H_n+0.5$ as we obtain $H_n+0.5 = (1-p)(H_{n-1}+0.5) + p(0.5-H_{n-1})$ which tells us $H_n = H_{n-1}(1-2p)$. So as one can see $O_n$ approachs $frac{1}{2}$ and whether is does so in a monotone or alternating manner depends on whethere $pgeq 1/2$. Recall $O_1$ is simply $p$, so $H_1 = p-0.5$. In the case in which $p<0.5$ we have that $H_n$ is always negative and in the other case we have that $H_n$ alternates signs.
            $endgroup$
            – Jorge Fernández Hidalgo
            2 hours ago












          • $begingroup$
            That's a good analysis. My reason for bringing it up is: plainly the OP is relatively new to probability, so I think it is important to call out the assumptions when giving "shortcut" reasoning like this answer. The underlying assumption is that with eight coins, an even number of heads or tails is also 1/2. I think it is worthwhile calling that out. I wouldn't want the OP to deduce that for more general problems, they only need to consider the probability of the final flip.
            $endgroup$
            – Eric Lippert
            1 hour ago






          • 1




            $begingroup$
            Yes you are right, I was a bit careless when I wrote it, thank you for pointing out that detail!
            $endgroup$
            – Jorge Fernández Hidalgo
            1 hour ago










          4




          4




          $begingroup$
          Though this answer is correct for this specific question, it is interesting to consider why it works. Consider: an unfair coin comes up heads 75% of the time, tails 25% of the time. We flip it nine times. Again, the last flip determines whether the total is odd or even. In this case, is it even 75% of the time, because the last flip is heads 75% of the time, or is it even 50% of the time, as it was before? Or is it even some other percentage of the time? Before you do the math, what's your gut feeling? And can you explain why your argument is only valid for a fair coin?
          $endgroup$
          – Eric Lippert
          2 hours ago




          $begingroup$
          Though this answer is correct for this specific question, it is interesting to consider why it works. Consider: an unfair coin comes up heads 75% of the time, tails 25% of the time. We flip it nine times. Again, the last flip determines whether the total is odd or even. In this case, is it even 75% of the time, because the last flip is heads 75% of the time, or is it even 50% of the time, as it was before? Or is it even some other percentage of the time? Before you do the math, what's your gut feeling? And can you explain why your argument is only valid for a fair coin?
          $endgroup$
          – Eric Lippert
          2 hours ago












          $begingroup$
          Interesting question Eric. Formally I would use recursion, let us define $O_n$ as the probability that we get an odd number of heads when flipping $n$ coins, and let $p$ be the probability the coin comes up as heads. Then the previous reasoning turns into the recurrence relation $O_n=(1-p)O_{n-1} + p(1-O_{n-1})=(1-2p)O_{n-1}+p$.
          $endgroup$
          – Jorge Fernández Hidalgo
          2 hours ago






          $begingroup$
          Interesting question Eric. Formally I would use recursion, let us define $O_n$ as the probability that we get an odd number of heads when flipping $n$ coins, and let $p$ be the probability the coin comes up as heads. Then the previous reasoning turns into the recurrence relation $O_n=(1-p)O_{n-1} + p(1-O_{n-1})=(1-2p)O_{n-1}+p$.
          $endgroup$
          – Jorge Fernández Hidalgo
          2 hours ago














          $begingroup$
          Although I think things become clearer when we work with $ O_n=H_n+0.5$ as we obtain $H_n+0.5 = (1-p)(H_{n-1}+0.5) + p(0.5-H_{n-1})$ which tells us $H_n = H_{n-1}(1-2p)$. So as one can see $O_n$ approachs $frac{1}{2}$ and whether is does so in a monotone or alternating manner depends on whethere $pgeq 1/2$. Recall $O_1$ is simply $p$, so $H_1 = p-0.5$. In the case in which $p<0.5$ we have that $H_n$ is always negative and in the other case we have that $H_n$ alternates signs.
          $endgroup$
          – Jorge Fernández Hidalgo
          2 hours ago






          $begingroup$
          Although I think things become clearer when we work with $ O_n=H_n+0.5$ as we obtain $H_n+0.5 = (1-p)(H_{n-1}+0.5) + p(0.5-H_{n-1})$ which tells us $H_n = H_{n-1}(1-2p)$. So as one can see $O_n$ approachs $frac{1}{2}$ and whether is does so in a monotone or alternating manner depends on whethere $pgeq 1/2$. Recall $O_1$ is simply $p$, so $H_1 = p-0.5$. In the case in which $p<0.5$ we have that $H_n$ is always negative and in the other case we have that $H_n$ alternates signs.
          $endgroup$
          – Jorge Fernández Hidalgo
          2 hours ago














          $begingroup$
          That's a good analysis. My reason for bringing it up is: plainly the OP is relatively new to probability, so I think it is important to call out the assumptions when giving "shortcut" reasoning like this answer. The underlying assumption is that with eight coins, an even number of heads or tails is also 1/2. I think it is worthwhile calling that out. I wouldn't want the OP to deduce that for more general problems, they only need to consider the probability of the final flip.
          $endgroup$
          – Eric Lippert
          1 hour ago




          $begingroup$
          That's a good analysis. My reason for bringing it up is: plainly the OP is relatively new to probability, so I think it is important to call out the assumptions when giving "shortcut" reasoning like this answer. The underlying assumption is that with eight coins, an even number of heads or tails is also 1/2. I think it is worthwhile calling that out. I wouldn't want the OP to deduce that for more general problems, they only need to consider the probability of the final flip.
          $endgroup$
          – Eric Lippert
          1 hour ago




          1




          1




          $begingroup$
          Yes you are right, I was a bit careless when I wrote it, thank you for pointing out that detail!
          $endgroup$
          – Jorge Fernández Hidalgo
          1 hour ago






          $begingroup$
          Yes you are right, I was a bit careless when I wrote it, thank you for pointing out that detail!
          $endgroup$
          – Jorge Fernández Hidalgo
          1 hour ago













          8












          $begingroup$

          If there are an even number of heads then there must be an odd number of tails. But heads and tails are symmetrical, so the probability must be $1/2$.






          share|cite|improve this answer









          $endgroup$


















            8












            $begingroup$

            If there are an even number of heads then there must be an odd number of tails. But heads and tails are symmetrical, so the probability must be $1/2$.






            share|cite|improve this answer









            $endgroup$
















              8












              8








              8





              $begingroup$

              If there are an even number of heads then there must be an odd number of tails. But heads and tails are symmetrical, so the probability must be $1/2$.






              share|cite|improve this answer









              $endgroup$



              If there are an even number of heads then there must be an odd number of tails. But heads and tails are symmetrical, so the probability must be $1/2$.







              share|cite|improve this answer












              share|cite|improve this answer



              share|cite|improve this answer










              answered 9 hours ago









              Ethan BolkerEthan Bolker

              44.1k552117




              44.1k552117























                  5












                  $begingroup$

                  All the possible sequences of tosses (which are all equally likely) may be divided into the two categories "even number of heads" and "odd number of heads". You can then pair up each sequence in one category with the "flipped" version (flip every coin in the sequence around) in the other category. This shows that there are equally many sequences in each of the two categories. So the probability of landing in a specific one of them must be $frac12$.






                  share|cite|improve this answer









                  $endgroup$


















                    5












                    $begingroup$

                    All the possible sequences of tosses (which are all equally likely) may be divided into the two categories "even number of heads" and "odd number of heads". You can then pair up each sequence in one category with the "flipped" version (flip every coin in the sequence around) in the other category. This shows that there are equally many sequences in each of the two categories. So the probability of landing in a specific one of them must be $frac12$.






                    share|cite|improve this answer









                    $endgroup$
















                      5












                      5








                      5





                      $begingroup$

                      All the possible sequences of tosses (which are all equally likely) may be divided into the two categories "even number of heads" and "odd number of heads". You can then pair up each sequence in one category with the "flipped" version (flip every coin in the sequence around) in the other category. This shows that there are equally many sequences in each of the two categories. So the probability of landing in a specific one of them must be $frac12$.






                      share|cite|improve this answer









                      $endgroup$



                      All the possible sequences of tosses (which are all equally likely) may be divided into the two categories "even number of heads" and "odd number of heads". You can then pair up each sequence in one category with the "flipped" version (flip every coin in the sequence around) in the other category. This shows that there are equally many sequences in each of the two categories. So the probability of landing in a specific one of them must be $frac12$.







                      share|cite|improve this answer












                      share|cite|improve this answer



                      share|cite|improve this answer










                      answered 9 hours ago









                      ArthurArthur

                      116k7116199




                      116k7116199























                          3












                          $begingroup$

                          There are two cases here:




                          • There's an even number of heads: 0, 2, 4, 6 or 8 heads

                          • There's an odd number of heads: 1, 3, 5, 7 or 9 heads


                          But notice that having an odd number of heads means having an even number of tails (e.g. 5 heads means 4 tails), so the second case is the same as:




                          • There's an even number of tails: 0, 2, 4, 6 or 8 tails


                          Since heads and tails are equally probable, we can, by symmetry, see that these two cases have the same probability. Therefore each must have probability $1/2$.






                          share|cite|improve this answer









                          $endgroup$













                          • $begingroup$
                            Ethan Bolker already gave this explanation 2 hours ago.
                            $endgroup$
                            – Paul Sinclair
                            7 hours ago










                          • $begingroup$
                            @PaulSinclair Yes, he did. But I found this explanation clearer than Ethan's, which skips a number of steps.
                            $endgroup$
                            – CJ Dennis
                            14 mins ago
















                          3












                          $begingroup$

                          There are two cases here:




                          • There's an even number of heads: 0, 2, 4, 6 or 8 heads

                          • There's an odd number of heads: 1, 3, 5, 7 or 9 heads


                          But notice that having an odd number of heads means having an even number of tails (e.g. 5 heads means 4 tails), so the second case is the same as:




                          • There's an even number of tails: 0, 2, 4, 6 or 8 tails


                          Since heads and tails are equally probable, we can, by symmetry, see that these two cases have the same probability. Therefore each must have probability $1/2$.






                          share|cite|improve this answer









                          $endgroup$













                          • $begingroup$
                            Ethan Bolker already gave this explanation 2 hours ago.
                            $endgroup$
                            – Paul Sinclair
                            7 hours ago










                          • $begingroup$
                            @PaulSinclair Yes, he did. But I found this explanation clearer than Ethan's, which skips a number of steps.
                            $endgroup$
                            – CJ Dennis
                            14 mins ago














                          3












                          3








                          3





                          $begingroup$

                          There are two cases here:




                          • There's an even number of heads: 0, 2, 4, 6 or 8 heads

                          • There's an odd number of heads: 1, 3, 5, 7 or 9 heads


                          But notice that having an odd number of heads means having an even number of tails (e.g. 5 heads means 4 tails), so the second case is the same as:




                          • There's an even number of tails: 0, 2, 4, 6 or 8 tails


                          Since heads and tails are equally probable, we can, by symmetry, see that these two cases have the same probability. Therefore each must have probability $1/2$.






                          share|cite|improve this answer









                          $endgroup$



                          There are two cases here:




                          • There's an even number of heads: 0, 2, 4, 6 or 8 heads

                          • There's an odd number of heads: 1, 3, 5, 7 or 9 heads


                          But notice that having an odd number of heads means having an even number of tails (e.g. 5 heads means 4 tails), so the second case is the same as:




                          • There's an even number of tails: 0, 2, 4, 6 or 8 tails


                          Since heads and tails are equally probable, we can, by symmetry, see that these two cases have the same probability. Therefore each must have probability $1/2$.







                          share|cite|improve this answer












                          share|cite|improve this answer



                          share|cite|improve this answer










                          answered 7 hours ago









                          FrxstremFrxstrem

                          4131813




                          4131813












                          • $begingroup$
                            Ethan Bolker already gave this explanation 2 hours ago.
                            $endgroup$
                            – Paul Sinclair
                            7 hours ago










                          • $begingroup$
                            @PaulSinclair Yes, he did. But I found this explanation clearer than Ethan's, which skips a number of steps.
                            $endgroup$
                            – CJ Dennis
                            14 mins ago


















                          • $begingroup$
                            Ethan Bolker already gave this explanation 2 hours ago.
                            $endgroup$
                            – Paul Sinclair
                            7 hours ago










                          • $begingroup$
                            @PaulSinclair Yes, he did. But I found this explanation clearer than Ethan's, which skips a number of steps.
                            $endgroup$
                            – CJ Dennis
                            14 mins ago
















                          $begingroup$
                          Ethan Bolker already gave this explanation 2 hours ago.
                          $endgroup$
                          – Paul Sinclair
                          7 hours ago




                          $begingroup$
                          Ethan Bolker already gave this explanation 2 hours ago.
                          $endgroup$
                          – Paul Sinclair
                          7 hours ago












                          $begingroup$
                          @PaulSinclair Yes, he did. But I found this explanation clearer than Ethan's, which skips a number of steps.
                          $endgroup$
                          – CJ Dennis
                          14 mins ago




                          $begingroup$
                          @PaulSinclair Yes, he did. But I found this explanation clearer than Ethan's, which skips a number of steps.
                          $endgroup$
                          – CJ Dennis
                          14 mins ago











                          2












                          $begingroup$

                          The easiest way to see this : Consider the number of heads we have in the first $8$ coins.




                          • If this number is even, we need a tail, we have probability $frac{1}{2}$

                          • If this number is odd, we need a head, we have probability $frac{1}{2}$


                          Hence no matter what the $8$ coins delivered, we have probability $frac{1}{2}$ , which is the answer.






                          share|cite|improve this answer









                          $endgroup$









                          • 1




                            $begingroup$
                            This is , by the way, true for EVERY number of coins (even for one coin).
                            $endgroup$
                            – Peter
                            9 hours ago






                          • 3




                            $begingroup$
                            Pedantic point: If zero coins are tossed, the probability of an even number of heads is 100%.
                            $endgroup$
                            – Brian
                            7 hours ago










                          • $begingroup$
                            This answer presupposes that having an even number of heads and an odd number of heads in eight flips is equally likely, but we haven't proved that lemma.
                            $endgroup$
                            – Eric Lippert
                            2 hours ago
















                          2












                          $begingroup$

                          The easiest way to see this : Consider the number of heads we have in the first $8$ coins.




                          • If this number is even, we need a tail, we have probability $frac{1}{2}$

                          • If this number is odd, we need a head, we have probability $frac{1}{2}$


                          Hence no matter what the $8$ coins delivered, we have probability $frac{1}{2}$ , which is the answer.






                          share|cite|improve this answer









                          $endgroup$









                          • 1




                            $begingroup$
                            This is , by the way, true for EVERY number of coins (even for one coin).
                            $endgroup$
                            – Peter
                            9 hours ago






                          • 3




                            $begingroup$
                            Pedantic point: If zero coins are tossed, the probability of an even number of heads is 100%.
                            $endgroup$
                            – Brian
                            7 hours ago










                          • $begingroup$
                            This answer presupposes that having an even number of heads and an odd number of heads in eight flips is equally likely, but we haven't proved that lemma.
                            $endgroup$
                            – Eric Lippert
                            2 hours ago














                          2












                          2








                          2





                          $begingroup$

                          The easiest way to see this : Consider the number of heads we have in the first $8$ coins.




                          • If this number is even, we need a tail, we have probability $frac{1}{2}$

                          • If this number is odd, we need a head, we have probability $frac{1}{2}$


                          Hence no matter what the $8$ coins delivered, we have probability $frac{1}{2}$ , which is the answer.






                          share|cite|improve this answer









                          $endgroup$



                          The easiest way to see this : Consider the number of heads we have in the first $8$ coins.




                          • If this number is even, we need a tail, we have probability $frac{1}{2}$

                          • If this number is odd, we need a head, we have probability $frac{1}{2}$


                          Hence no matter what the $8$ coins delivered, we have probability $frac{1}{2}$ , which is the answer.







                          share|cite|improve this answer












                          share|cite|improve this answer



                          share|cite|improve this answer










                          answered 9 hours ago









                          PeterPeter

                          48.2k1139133




                          48.2k1139133








                          • 1




                            $begingroup$
                            This is , by the way, true for EVERY number of coins (even for one coin).
                            $endgroup$
                            – Peter
                            9 hours ago






                          • 3




                            $begingroup$
                            Pedantic point: If zero coins are tossed, the probability of an even number of heads is 100%.
                            $endgroup$
                            – Brian
                            7 hours ago










                          • $begingroup$
                            This answer presupposes that having an even number of heads and an odd number of heads in eight flips is equally likely, but we haven't proved that lemma.
                            $endgroup$
                            – Eric Lippert
                            2 hours ago














                          • 1




                            $begingroup$
                            This is , by the way, true for EVERY number of coins (even for one coin).
                            $endgroup$
                            – Peter
                            9 hours ago






                          • 3




                            $begingroup$
                            Pedantic point: If zero coins are tossed, the probability of an even number of heads is 100%.
                            $endgroup$
                            – Brian
                            7 hours ago










                          • $begingroup$
                            This answer presupposes that having an even number of heads and an odd number of heads in eight flips is equally likely, but we haven't proved that lemma.
                            $endgroup$
                            – Eric Lippert
                            2 hours ago








                          1




                          1




                          $begingroup$
                          This is , by the way, true for EVERY number of coins (even for one coin).
                          $endgroup$
                          – Peter
                          9 hours ago




                          $begingroup$
                          This is , by the way, true for EVERY number of coins (even for one coin).
                          $endgroup$
                          – Peter
                          9 hours ago




                          3




                          3




                          $begingroup$
                          Pedantic point: If zero coins are tossed, the probability of an even number of heads is 100%.
                          $endgroup$
                          – Brian
                          7 hours ago




                          $begingroup$
                          Pedantic point: If zero coins are tossed, the probability of an even number of heads is 100%.
                          $endgroup$
                          – Brian
                          7 hours ago












                          $begingroup$
                          This answer presupposes that having an even number of heads and an odd number of heads in eight flips is equally likely, but we haven't proved that lemma.
                          $endgroup$
                          – Eric Lippert
                          2 hours ago




                          $begingroup$
                          This answer presupposes that having an even number of heads and an odd number of heads in eight flips is equally likely, but we haven't proved that lemma.
                          $endgroup$
                          – Eric Lippert
                          2 hours ago











                          2












                          $begingroup$

                          Your approach is good also, you probably made a mistake in calculations. The number of favorable outcomes is
                          $$binom{9}{0}+binom{9}{2}+binom{9}{4}+binom{9}{6}+binom{9}{8}=1+36+126+84+9=256$$
                          The number of all possible outcomes is $512$ thus the probability to get even number of heads is $0.5$.






                          share|cite|improve this answer









                          $endgroup$


















                            2












                            $begingroup$

                            Your approach is good also, you probably made a mistake in calculations. The number of favorable outcomes is
                            $$binom{9}{0}+binom{9}{2}+binom{9}{4}+binom{9}{6}+binom{9}{8}=1+36+126+84+9=256$$
                            The number of all possible outcomes is $512$ thus the probability to get even number of heads is $0.5$.






                            share|cite|improve this answer









                            $endgroup$
















                              2












                              2








                              2





                              $begingroup$

                              Your approach is good also, you probably made a mistake in calculations. The number of favorable outcomes is
                              $$binom{9}{0}+binom{9}{2}+binom{9}{4}+binom{9}{6}+binom{9}{8}=1+36+126+84+9=256$$
                              The number of all possible outcomes is $512$ thus the probability to get even number of heads is $0.5$.






                              share|cite|improve this answer









                              $endgroup$



                              Your approach is good also, you probably made a mistake in calculations. The number of favorable outcomes is
                              $$binom{9}{0}+binom{9}{2}+binom{9}{4}+binom{9}{6}+binom{9}{8}=1+36+126+84+9=256$$
                              The number of all possible outcomes is $512$ thus the probability to get even number of heads is $0.5$.







                              share|cite|improve this answer












                              share|cite|improve this answer



                              share|cite|improve this answer










                              answered 9 hours ago









                              VasyaVasya

                              3,4271516




                              3,4271516























                                  1












                                  $begingroup$

                                  The probability generating function of a Binomiall random variable $Xsim text{Bin}(n, 1/2)$ with probability of success $1/2$ is given by
                                  $$
                                  g_{X}(t)=Et^X=sum_{k=0}^nP(X=k)t^k=sum_{k=0}^nbinom{n}{k}frac{t^k}{2^n}=frac{1}{2^n}(1+t)^n
                                  $$

                                  In particular the probability that $X$ is even is given by
                                  $$
                                  sum_{0leq kleq n, k,{text{even}}}P(X=k)=frac{g(1)+g(-1)}{2}=frac{1+0}{2}=frac{1}{2}.
                                  $$






                                  share|cite|improve this answer









                                  $endgroup$


















                                    1












                                    $begingroup$

                                    The probability generating function of a Binomiall random variable $Xsim text{Bin}(n, 1/2)$ with probability of success $1/2$ is given by
                                    $$
                                    g_{X}(t)=Et^X=sum_{k=0}^nP(X=k)t^k=sum_{k=0}^nbinom{n}{k}frac{t^k}{2^n}=frac{1}{2^n}(1+t)^n
                                    $$

                                    In particular the probability that $X$ is even is given by
                                    $$
                                    sum_{0leq kleq n, k,{text{even}}}P(X=k)=frac{g(1)+g(-1)}{2}=frac{1+0}{2}=frac{1}{2}.
                                    $$






                                    share|cite|improve this answer









                                    $endgroup$
















                                      1












                                      1








                                      1





                                      $begingroup$

                                      The probability generating function of a Binomiall random variable $Xsim text{Bin}(n, 1/2)$ with probability of success $1/2$ is given by
                                      $$
                                      g_{X}(t)=Et^X=sum_{k=0}^nP(X=k)t^k=sum_{k=0}^nbinom{n}{k}frac{t^k}{2^n}=frac{1}{2^n}(1+t)^n
                                      $$

                                      In particular the probability that $X$ is even is given by
                                      $$
                                      sum_{0leq kleq n, k,{text{even}}}P(X=k)=frac{g(1)+g(-1)}{2}=frac{1+0}{2}=frac{1}{2}.
                                      $$






                                      share|cite|improve this answer









                                      $endgroup$



                                      The probability generating function of a Binomiall random variable $Xsim text{Bin}(n, 1/2)$ with probability of success $1/2$ is given by
                                      $$
                                      g_{X}(t)=Et^X=sum_{k=0}^nP(X=k)t^k=sum_{k=0}^nbinom{n}{k}frac{t^k}{2^n}=frac{1}{2^n}(1+t)^n
                                      $$

                                      In particular the probability that $X$ is even is given by
                                      $$
                                      sum_{0leq kleq n, k,{text{even}}}P(X=k)=frac{g(1)+g(-1)}{2}=frac{1+0}{2}=frac{1}{2}.
                                      $$







                                      share|cite|improve this answer












                                      share|cite|improve this answer



                                      share|cite|improve this answer










                                      answered 3 hours ago









                                      Foobaz JohnFoobaz John

                                      22.4k41452




                                      22.4k41452






























                                          draft saved

                                          draft discarded




















































                                          Thanks for contributing an answer to Mathematics Stack Exchange!


                                          • Please be sure to answer the question. Provide details and share your research!

                                          But avoid



                                          • Asking for help, clarification, or responding to other answers.

                                          • Making statements based on opinion; back them up with references or personal experience.


                                          Use MathJax to format equations. MathJax reference.


                                          To learn more, see our tips on writing great answers.




                                          draft saved


                                          draft discarded














                                          StackExchange.ready(
                                          function () {
                                          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3134991%2fif-nine-coins-are-tossed-what-is-the-probability-that-the-number-of-heads-is-ev%23new-answer', 'question_page');
                                          }
                                          );

                                          Post as a guest















                                          Required, but never shown





















































                                          Required, but never shown














                                          Required, but never shown












                                          Required, but never shown







                                          Required, but never shown

































                                          Required, but never shown














                                          Required, but never shown












                                          Required, but never shown







                                          Required, but never shown







                                          Popular posts from this blog

                                          香粉寮

                                          GameSpot