Ti-83 Programming Question

Got questions? Got answers? Go here for both.

Moderator: MaxCoderz Staff

Post Reply
JbAngleSlam
New Member
Posts: 2
Joined: Tue 28 Nov, 2006 12:59 am

Ti-83 Programming Question

Post by JbAngleSlam »

I am having major issues with a simulation program for my TI-83. here is the question:

a pair of dice is rolled repeatedly. simulate the probability that a sum of 7 is rolled before a sum of 8.

i know the answer is 6/11 but i cant get the program right on my calc.

any help would be great

thanks
CompWiz
Calc King
Posts: 1950
Joined: Thu 13 Oct, 2005 1:54 pm
Location: UB

Post by CompWiz »

In Memory of the Maxcoderz Trophy Image
JbAngleSlam
New Member
Posts: 2
Joined: Tue 28 Nov, 2006 12:59 am

Post by JbAngleSlam »

Im not really sure what you mean by source code. I have to come up with a programming code for my graph calc that will simulate this probability.

I cant figure it out.
User avatar
anykey
Extreme Poster
Posts: 420
Joined: Mon 31 Jan, 2005 3:36 am
Location: In the matrix
Contact:

Post by anykey »

Looks like we need to clear up some terminology first...
Source code = programming code
I think, therefore iMac
Image
User avatar
thegamefreak0134
Extreme Poster
Posts: 455
Joined: Mon 23 Jan, 2006 10:09 pm
Location: In front of a Computer, coding
Contact:

Post by thegamefreak0134 »

If you need the logic for such a thing, it's really very simple. You create a list from 1 to 11, and then every roll of the dice adds 1 to L1(number - 1), because the dice rolls start at 2.

To dislplay the rolls right, you will need somewhere in the range of a few thousand rolls of the dice, so keep that in mind. Then you should make a graph onscreen of the ratios between numbers. This can be done by setting xmin and xmax to your spacing preference, then setting ymin to 0 and ymax to the highest value in the list. (use the max() function) then just draw lines to represent the current graph, and after a while the trend should start to appear as a "hill" with the peak of the hill being right on 7.

This kind of probability simulation is already implemented in an APP on most TI-83 Plus family calcs, called ProbSim I believe.

Good lick with your program!

-gamefreak
I'm not mad, just a little crazy.

DarkNova - a little side project I run.
King Harold
Calc King
Posts: 1513
Joined: Sat 05 Aug, 2006 7:22 am

Post by King Harold »

there is a formula for it aswell, but i'd have to look in my math book of 2 years ago (I will if you don't find a solution though)
User avatar
silver calc
New Member
Posts: 73
Joined: Tue 28 Mar, 2006 10:50 pm
Location: Wouldn't you like to know?

Post by silver calc »

Just because ideally the probability is 6/11 doesn't mean that experimentally you will get that. How many trials did you use?
Please "encourage" me to work more on Image any way you deem necessary
Post Reply