Discussion about math, puzzles, games and fun. Useful symbols: ÷ × ½ √ ∞ ≠ ≤ ≥ ≈ ⇒ ± ∈ Δ θ ∴ ∑ ∫ π -¹ ² ³ °

You are not logged in.

- Topics: Active | Unanswered

Pages: **1**

A game takes place in discrete "rounds".

In the beginning, a player is given 3 lives. At each round, he may either loose, with a 10% chance, and loose a life. Or, he may win, in which case, he gains a life. However, the last rule never lets him gain more than 3 lives.

The game ends when a player reaches 0 lives.

Calculate the expected number of rounds the player plays using an absorbing markov model

'And fun? If maths is fun, then getting a tooth extraction is fun. A viral infection is fun. Rabies shots are fun.'

'God exists because Mathematics is consistent, and the devil exists because we cannot prove it'

I'm not crazy, my mother had me tested.

Offline

**Relentless****Member**- Registered: 2015-12-15
- Posts: 624

I am very ignorant of higher maths and will be unable to shed much light on this problem, but just to get the ball rolling I think it's clear that it must be more than 12 (since there is greater than a 50% chance of winning the first 6 and that guarantees a minimum 12).

*Last edited by Relentless (2015-12-20 03:00:24)*

Offline

Hmm..

I think the answer is close to 1000

'And fun? If maths is fun, then getting a tooth extraction is fun. A viral infection is fun. Rabies shots are fun.'

'God exists because Mathematics is consistent, and the devil exists because we cannot prove it'

I'm not crazy, my mother had me tested.

Offline

**Relentless****Member**- Registered: 2015-12-15
- Posts: 624

I suppose I'm right then. lol

Offline

You are.

The correct answer is 1020.

```
chain = DiscreteMarkovProcess[
4, {{1, 0, 0, 0}, {0.1, 0, 0.9, 0}, {0, 0.1, 0, 0.9}, {0, 0, 0.1,
0.9}}];
Mean[FirstPassageTimeDistribution[chain, {1}]]
```

'And fun? If maths is fun, then getting a tooth extraction is fun. A viral infection is fun. Rabies shots are fun.'

'God exists because Mathematics is consistent, and the devil exists because we cannot prove it'

I'm not crazy, my mother had me tested.

Offline

**bobbym****Administrator**- From: Bumpkinland
- Registered: 2009-04-12
- Posts: 107,736

So what did you need help with?

I will ask you some questions from the point of view given by EM:

1) How certain are you that you have the correct answer?

2) If I said that answer was incorrect, or that M was not getting the right answer, what would you reply?

**In mathematics, you don't understand things. You just get used to them.****If it ain't broke, fix it until it is.**** Always satisfy the Prime Directive of getting the right answer above all else.**

Offline

The answer agrees with a sim and an analytical approach

'God exists because Mathematics is consistent, and the devil exists because we cannot prove it'

I'm not crazy, my mother had me tested.

Offline

**bobbym****Administrator**- From: Bumpkinland
- Registered: 2009-04-12
- Posts: 107,736

That is correct and so is the answer.

The expected time to absorption is given by t where the starting states are rows (shown in the first column).

B is the probability of ending in some absorbing state (first row) starting in some transient state (first column).

**In mathematics, you don't understand things. You just get used to them.****If it ain't broke, fix it until it is.**** Always satisfy the Prime Directive of getting the right answer above all else.**

Offline

**Matir****Member**- Registered: 2016-10-08
- Posts: 22

Do we really need Markov chains for this problem? Plain algebra should be enough.

Offline

**bobbym****Administrator**- From: Bumpkinland
- Registered: 2009-04-12
- Posts: 107,736

In this thread there is no chatter, I am from Missouri, so you are going to have to show it else the comment is removed. But remember this thread is for computer math so you must use computer math.

http://www.mathisfunforum.com/viewtopic.php?id=15250

Agnishom's solution in post #5 is the only solution because it uses Mathematica.

**In mathematics, you don't understand things. You just get used to them.****If it ain't broke, fix it until it is.**** Always satisfy the Prime Directive of getting the right answer above all else.**

Offline

**Matir****Member**- Registered: 2016-10-08
- Posts: 22

This is the set of equations you'll need,

is the number of rounds you should survive with lives.Plugging into Wolfram|Alpha / pen+paper gives:

http://www.wolframalpha.com/input/?i=R3 … 2B9R2%2F10

I guess you should accept that my head is a (not too good!) computer...

Offline

**bobbym****Administrator**- From: Bumpkinland
- Registered: 2009-04-12
- Posts: 107,736

The Markov chain does all that automatically. But you do have another solution so congratulations! Very good.

Can you please introduce yourself in Introductions.

**In mathematics, you don't understand things. You just get used to them.****If it ain't broke, fix it until it is.**** Always satisfy the Prime Directive of getting the right answer above all else.**

Offline

Pages: **1**