We’re playing a game. I flip a coin. If it lands on Tails, I flip it again. If it lands on Heads, the game ends.

You win if the game ends on an even turn, and lose otherwise.

Define the following events:

A: You win the game

B: The game goes on for at least 4 turns

C: The game goes on for at least 5 turns

What are P(A), P(B), and P(C)? Are A and B independent? How about A and C?

  • enkers@sh.itjust.works
    link
    fedilink
    arrow-up
    4
    ·
    edit-2
    9 months ago

    Are all games played to completion? Assuming yes,

    answer
    P(A) = Sum[1/4^n,{n,1,∞}] = 0.333...
    P(B) = 1/8
    P(C) = 1/16
    

    One of A,B or A,C is dependent, as it’d flip the polarity of the remaining games, the other is independent, as it wouldn’t. I’m not too worried about which is which, as it’s just an off-by-one error. xD

    Assuming no, You’d have to know the distribution of when games were abandoned, I’d think.

    • zkfcfbzr@lemmy.worldOP
      link
      fedilink
      English
      arrow-up
      5
      ·
      edit-2
      9 months ago

      Games are always played to completion, though if you wanna make it (barely) more challenging you can add in a 5% chance for both players to get bored and give up on each round (before flipping), leading to a loss. Though it seems unlikely - after flipping a quarter 20 times and getting Tails every time, I’d be inclined to keep flipping if anything.

      response

      These are correct. It is possible to reason out which of B and C is independent of A without going into the numbers.

      • enkers@sh.itjust.works
        link
        fedilink
        arrow-up
        3
        ·
        9 months ago

        after flipping a quarter 20 times and getting Tails every time, I’d be inclined to keep flipping if anything.

        It’s a sunk cost fallacy, it’s never too late to get bored and give up. ;)

    • zkfcfbzr@lemmy.worldOP
      link
      fedilink
      English
      arrow-up
      3
      ·
      edit-2
      9 months ago
      response

      This is close, but you’ve got an off-by-one error where you calculate the probability of making it to the nth round as 1/2^n. Consider that that would imply you have a probability of 1/2 for the game to make it to round 1, or 1/4 to make it to round 2, etc - it should be 1/2^(n-1). Correcting this would give you the correct answers for P(B) and P(C).

      As for the dependence question, I’m not sure I followed your arguments there - but saying both are dependent is not correct.

        • zkfcfbzr@lemmy.worldOP
          link
          fedilink
          English
          arrow-up
          4
          ·
          edit-2
          9 months ago

          In probability, two events are said to be independent if one event happening has no effect on the probability of another event happening. So coin flips, as an example, are independent - because when you flip a coin and get Tails, that doesn’t affect the probability of the next coin flip also coming up Tails.

          So in this context, asking if A and B are independent is asking: Does knowing the game lasts at least four turns change the probability of winning? And similarly for A and C. Does knowing the game lasts at least 5 turns change the probability that the game will end in a victory?

          Rest of response

          To be clear about your other answers, saying P(B) = 1/16 and P(C) = 1/32 are not correct - I was saying if you adjusted your formula, from 1/2^n to 1/2^(n-1), then your answers would be correct. So the probability of the game lasting at least four turns is 1/2^(4-1) = 1/2^3 = 1/8, and the probability of it lasting at least 5 turns is 1/2^(5-1) = 1/2^4 = 1/16.

          But I think you were more asking about why this didn’t affect your win rate - that’s because there’s a subtle difference between “making it to the nth round” and “having the game end on the nth round” - and that difference is that once you make it to a round, you then have a 1/2 probability to end the game - which makes the probability of ending on the nth round the 1/2^n you used.

  • el_psd@sh.itjust.works
    link
    fedilink
    arrow-up
    3
    ·
    9 months ago

    I read the other answers in the thread, and I definitely would have gotten this wrong without that. This answer stands a chance at least

    Independence

    A and C are independent, A and B are not. Since you have a chance to win on turn 4 that you do not have on turn 1, P(A|B) = 1/2 + 1/16 + 1/64… = 7/12 != P(A). Conversely, P(A|C) = 1/4 + 1/16 + 1/64… = 1/3 = P(A)

    • zkfcfbzr@lemmy.worldOP
      link
      fedilink
      English
      arrow-up
      3
      ·
      9 months ago
      response

      This is the correct answer, although P(A|B) should actually be 2/3 rather than 7/12 - I think you meant 1/2 + 1/8 + 1/32 + …?

      The reasoning is good, either way. Since past flips won’t affect future flips, if the player has made it to turn 5, an odd turn, then their future prospects are no different than they were on turn 1, another odd turn - so A and C are independent. Similarly, A and B are dependent because your chances of winning and losing effectively flip: If you’ve made it to an even turn, then you now win if it takes an odd number of flips from there to get Heads.

      So it should be an almost paradoxical-seeming situation: You win 1/3 games overall, you win 2/3 games that make it to turn 2, you win 1/3 games that make it to turn 3, you win 2/3 games that make it to turn 4, 1/3 that make it to turn 5, etc.

      • el_psd@sh.itjust.works
        link
        fedilink
        arrow-up
        3
        ·
        9 months ago
        response

        Thanks for the catch! Once I noticed that the probability of winning on the initial flip was the difference between the two, I stopped thinking about the other terms…

  • mathemachristian[he]@lemm.ee
    link
    fedilink
    arrow-up
    2
    ·
    edit-2
    7 months ago
    solution

    Say Omega = N\{0}, sigma algebra is power set of N and the probability mass function is p(n)=2^-n .

    Then A is all the even numbers, B all numbers at least 4, C all numbers at least 5.

    P(A)=sum2-n n is even = sum2-2n n is at least 1 = sum4-n n is at least 1 = 1/(1-1/4)-1=1/3

    P(B) = P(N\{1,2,3}) = 1 - 1/2 - 1/4 - 1/8 = 1/8

    P© = 1/16 similarly

    P(A and B) = P(A\{2}) = 1/3 - 1/4 = 1/12 =/= P(A)P(B) therefore not independent

    P(A and C) = P(A\{2,4}) = P(A)P© with a similar calculation and therefore independent