Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem in modelling a Rice Rolling as Stochastic Process using vectors and matrices in MatLab

Status
Not open for further replies.

Umair Ahmed

Student
Jun 12, 2021
1
I am trying to model Dice Rolling (fair die) as a Stochastic process.
I used a row vector p of size 6 with each entry equals to 1/6 in order to represent probabilties of outcomes (1 to 6):
p = ones(1,6)/6
This gives me the following output :
p =
0.1667 0.1667 0.1667 0.1667 0.1667 0.1667

Now, I want to define another random variable T5 such that it shows me the first time I got a 5 when rolling the dice . I tried to plot the outcomes in another matrix [1,2,3,4,5,6] and also tried to do it using a rand function. But I am not getting the desires expression for it.
What would be the MatLab expression for :
P[T5=t] = P { Xt is the first random variable with outcome 5} .
 
Replies continue below

Recommended for you

I know a little about Rice rolling but nothing about Dice rolling. So which is it rice or dice?

It is a capital mistake to theorise before one has data. Insensibly one begins to twist facts to suit theories, instead of theories to suit facts. (Sherlock Holmes - A Scandal in Bohemia.)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor