Calling all math/statistic buff's....

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
I have a theory for a project but I wish to exercise some third party opinions as to whether its even possible.

I am required to come up with a statistical/probability type of presentation where-in I take a existing problem and use statistical math methods to find a solution.

My proposed problem that I want to try to figure out is the probability of how long it would take to reach a medium ground with the Iphone 4-digit screen lock feature. I understand that in the newest Iphones they implement a 4-digit code to unlock and if you get the code wrong you have a time set until you can try again, as you continue to get the code wrong the timer increases the amount of time between attempts.

My thought process might be flawed but I wish to try to use statistical analysis and processing to see how long you would have to randomly rotate through possible 4-digit numeral codes until you come across the correct match, all while taking into consideration each wrong guess has a counter set before next attempt.

I wonder if its ultimately possible that one could eventually figure out how long it would take to reach the correct code and wait the amount of time required to input said code.....? anyone care to provide input, i realize it might be irrational and some astronomical amount of time might be required due to the number of failed attempts but.... is there a stastical/rational way to possibly resent the possibility?
 

calvinbiss

Golden Member
Apr 5, 2001
1,745
0
0
I don't see why you couldn't calculate the time required based on the probability of finding the right 4 digit code.

I would actually be interested to know.
 

zebano

Diamond Member
Jun 15, 2005
4,042
0
0
I wonder if its ultimately possible that one could eventually figure out how long it would take to reach the correct code and wait the amount of time required to input said code.....? anyone care to provide input, i realize it might be irrational and some astronomical amount of time might be required due to the number of failed attempts but.... is there a stastical/rational way to possibly resent the possibility?

I think I don't quite understand the problem properly because waiting doesn't do anything useful if you're not attempting to solve. It about number of attempts (a probability issue) rather than a delay to actually unlock the device.

I don't see why you couldn't calculate the time required based on the probability of finding the right 4 digit code.

I would actually be interested to know.


I would expect there to be massive deviations in something with an incremental timer so while one could do this, I'm not sure how useful it would be.
 

MotF Bane

No Lifer
Dec 22, 2006
60,801
10
0
You need to figure out how the timer works. Essentially, if it's one second at the beginning, and adds one second per each wrong answer, it's a pretty easy function (y=mx+b). Then calculate the total number of possible codes (10^4, presumably). Technically, I think you can use a sequence for it, but it'll be easier to just calculate the maximum time value (y=1(10^4)+1), add one, divide by two (average), then multiply by 10^4. That'll be your maximum time total. The average time would involve y=.5(10^4)+1, add one, divide by two, multiply by (10^4)/2.

Caveat: This is how I would approach your problem. I have a limited statistics background. No guarantee that anything is right.
 

TuxDave

Lifer
Oct 8, 2002
10,571
3
71
I am required to come up with a statistical/probability type of presentation where-in I take a existing problem and use statistical math methods to find a solution.

Soooo..... not to derail your idea but do you mean find a real life phenomenon and calculate its behavior. Or do you mean identify a real life problem, and find a solution for it using statistical math.

For example: "A person has a 90% chance of typing in his iPhone passcode correctly on any given try and takes about a second to try. What delay algorithm would you put in such that a person typing in passcodes randomly would take 1 million times longer than a person who knows the passcode." (using expected time)

Or something like that.
 

halik

Lifer
Oct 10, 2000
25,696
1
81
Err this isn't realy statistical, other than the probability of you geting i right is 1/10^4
 

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
Soooo..... not to derail your idea but do you mean find a real life phenomenon and calculate its behavior. Or do you mean identify a real life problem, and find a solution for it using statistical math.

For example: "A person has a 90% chance of typing in his iPhone passcode correctly on any given try and takes about a second to try. What delay algorithm would you put in such that a person typing in passcodes randomly would take 1 million times longer than a person who knows the passcode." (using expected time)

Or something like that.

The assignment is to define a real life problem that someone might encounter in a work environment and solve it using statistical math.

The teacher is very easy on the assignment, he has basically stated if you can figure out how to come up with any kind of problem you want and solve it with statistics and prepare a powerpoint with the class about what you did and how you used statistics then its a fine idea. I am just asking if it would be possible to figure it out and i don't want to really put myself in a situation where its something I can't solve, lol.
 

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
You need to figure out how the timer works. Essentially, if it's one second at the beginning, and adds one second per each wrong answer, it's a pretty easy function (y=mx+b). Then calculate the total number of possible codes (10^4, presumably). Technically, I think you can use a sequence for it, but it'll be easier to just calculate the maximum time value (y=1(10^4)+1), add one, divide by two (average), then multiply by 10^4. That'll be your maximum time total. The average time would involve y=.5(10^4)+1, add one, divide by two, multiply by (10^4)/2.

Caveat: This is how I would approach your problem. I have a limited statistics background. No guarantee that anything is right.

I agree with you, I do need to figure out more about how the timer works... I have heard from friends about it but I myself do now own a Iphone and on their manual it simply states how to enable the passcode feature, it does not say how it works... as far as # of minutes added per attempt etc..
 

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
I think I don't quite understand the problem properly because waiting doesn't do anything useful if you're not attempting to solve. It about number of attempts (a probability issue) rather than a delay to actually unlock the device.




I would expect there to be massive deviations in something with an incremental timer so while one could do this, I'm not sure how useful it would be.


Zebano, the idea does not have to be useful, i just think it would be interesting and of course I do need to do my project on something......

as far as the waiting, I agree it doesn't do anything useful but... at the point of when you do discover the correct code if it took you 100,000 attempts to get there then the amount of time you have to wait is whatever the attempt timer would be set to, before trying... which its almost like... you can't even try to know its correct.... my challenge would be figuring out the possibility of when the timer/passcode would level out and allow you to ultimately put in the correct answer... what the probability of that happening is..
 

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
You need to figure out how the timer works. Essentially, if it's one second at the beginning, and adds one second per each wrong answer, it's a pretty easy function (y=mx+b). Then calculate the total number of possible codes (10^4, presumably). Technically, I think you can use a sequence for it, but it'll be easier to just calculate the maximum time value (y=1(10^4)+1), add one, divide by two (average), then multiply by 10^4. That'll be your maximum time total. The average time would involve y=.5(10^4)+1, add one, divide by two, multiply by (10^4)/2.

Caveat: This is how I would approach your problem. I have a limited statistics background. No guarantee that anything is right.

Thanks! I will use your input to attempt to figure how I might go about doing it. I am no math major so even with your limited statistics background i still appreciate your time, I understand that you can't guarantee 100% reliability.
 

actuarial

Platinum Member
Jan 22, 2009
2,814
0
71
Err this isn't realy statistical, other than the probability of you geting i right is 1/10^4

That's only the probably on the first try. Assuming you do no reuse failed attempts, that probability slowly increases.

The penalty for failing also increases.

It's a legitimate use of probability, and if my memory serves me correctly probably the best way to do it would be to use a markov chain.
 

the DRIZZLE

Platinum Member
Sep 6, 2007
2,956
1
81
You can't calculate the time needed to unlock it. You can only calculate the probability of unlocking it in a given amount of time or vis versa. edit: You can calculate the time needed to be 100% sure you will unlock it but that is not really that useful.
 
Last edited:

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
You can't calculate the time needed to unlock it. You can only calculate the probability of unlocking it in a given amount of time or vis versa.

Statistically speaking then what you're saying is I would have to make a baseline of demonstrating probability if given 1 week, 1 month, 1 year. etc... of time to break the code?


since the timer is going to increase per failed attempt I could see how trying to prove the actual amount of time would become pretty complex...

For the purpose of the demonstration I plan to simply just turn on simple passcode functions. Simple 4-digit code with the normal time interval lockout rules enabled on failed attempts...
 

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
If your end result for time is the expected number of attempts multiplied by some constant time per attempt, then the time part is pretty much useless (too trivial). I think that's what zebano meant by useless. If time spent per attempt was a random variable, then it'd be interesting.

I am researching it how the system works and time spent prior to being able to unlock after a failed attempt keeps increasing per failed attempt, you have to wait longer and longer the more failed attempts you make prior to guessing again.
 

TecHNooB

Diamond Member
Sep 10, 2005
7,458
1
76
I am researching it how the system works and time spent prior to being able to unlock after a failed attempt keeps increasing per failed attempt, you have to wait longer and longer the more failed attempts you make prior to guessing again.

yea, i read the op D: pondering now..
 

the DRIZZLE

Platinum Member
Sep 6, 2007
2,956
1
81
I would just assume it uses a very simple formula. Say it makes you wait A*n seconds after each attempt where n is the attempt number and A is a constant. The sum of the time would be S=A*n*(n+1)/2.

If you are taking a stat class you should know how to estimate the probability of guessing it any given number of attempts. If you haven't done that in your class yet then just ignore this. You can easily convert the number of attempts to time by using the formula above.

edit: you can set this up in excel in about 5 minutes. You also have to decide you want to reuse guesses.
 
Last edited:

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
I would just assume it uses a very simple formula. Say it makes you wait A*n seconds after each attempt where n is the attempt number and A is a constant. The sum of the time would be S=A*n*(n+1)/2.

If you are taking a stat class you should know how to estimate the probability of guessing it any given number of attempts. If you haven't done that in your class yet then just ignore this. You can easily convert the number of attempts to time by using the formula above.

edit: you can set this up in excel in about 5 minutes. You also have to decide you want to reuse guesses.

Thanks for the info, I will check it out, today basically all i am required to do is present the idea and set the stage, all the figuring out of the data comes in a few days... then i present my findings and answer.
 

Clinkster

Senior member
Aug 5, 2009
937
0
76
I would just assume it uses a very simple formula. Say it makes you wait A*n seconds after each attempt where n is the attempt number and A is a constant. The sum of the time would be S=A*n*(n+1)/2.

If you are taking a stat class you should know how to estimate the probability of guessing it any given number of attempts. If you haven't done that in your class yet then just ignore this. You can easily convert the number of attempts to time by using the formula above.

edit: you can set this up in excel in about 5 minutes. You also have to decide you want to reuse guesses.

I definitely like this idea of using software to produce a large amount of trial. Be sure to throw a histogram of those trials whilst reporting the comparison between the sample mean next to the true (calculated) mean.
 

DrPizza

Administrator Elite Member Goat Whisperer
Mar 5, 2001
49,601
167
111
www.slatebrookfarm.com
It doesn't sound complicated at all to calculate. Else, I don't quite understand what you mean.
For example, let's say that it delays you by 10 seconds per try, and that you're trying random combinations that take 2 seconds to enter; and you don't reuse combinations.

1/10000 of the time, it will take you 2 seconds to guess the code.
1/10000 of the time, it will take 2 tries, which is 14 seconds
1/10000 of the time, it will take 3 tries, which is 3*2 + 20 = 26 seconds
1/10000 of the time, it will take 4 tries, which is 4*2 + 30 =38 seconds
1/10000 of the time, it will take 5 tries, which is 5*2 seconds for entering the code, and there are a total of 4 delays (between the 1st and 2nd, 2nd & 3rd, 3rd & 4th, 4th & 5th) = 5*2 + 40 = 48 seconds.

The amount of time it takes you forms an arithmetic sequence, a(n)=12n-10
1/1000 times, it will take 10,000 attempts before you crack the code. 119,990 seconds. So, what's the average value of 2,14,26,38,...,119,990? Again, another trivial problem (unless I'm blundering here, or not quite understanding you.)

Now, maybe the lock-out period increases every 4th attempt. In that case, the sequence would be 2,2,2,2,14,14,14,14,26,26,26,26,... Which is 4 times the original sequence, but for only 2500 terms instead of 10,000 terms.
 
Last edited:

LiuKangBakinPie

Diamond Member
Jan 31, 2011
3,903
0
0
tilt the iPhone the screen will not rotate.. The Restrictions screen appears. Tap Enable Restrictions. Your iPhone will asks for a. So always rotate the iPhone into landscape mode to enter text.. To unlock the phone, you either press the Home button or the Sleep/Wake button
 

JTsyo

Lifer
Nov 18, 2007
12,035
1,134
126
I would think the proper way to do the passwords would be with a Monte Carlo run. Then you could see how long it would take on each run to get to that password if you started from 0000 and worked up to the password.
 

Meractik

Golden Member
Jul 8, 2003
1,752
0
0
It doesn't sound complicated at all to calculate. Else, I don't quite understand what you mean.
For example, let's say that it delays you by 10 seconds per try, and that you're trying random combinations that take 2 seconds to enter; and you don't reuse combinations.

1/10000 of the time, it will take you 2 seconds to guess the code.
1/10000 of the time, it will take 2 tries, which is 14 seconds
1/10000 of the time, it will take 3 tries, which is 3*2 + 20 = 26 seconds
1/10000 of the time, it will take 4 tries, which is 4*2 + 30 =38 seconds
1/10000 of the time, it will take 5 tries, which is 5*2 seconds for entering the code, and there are a total of 4 delays (between the 1st and 2nd, 2nd & 3rd, 3rd & 4th, 4th & 5th) = 5*2 + 40 = 48 seconds.

The amount of time it takes you forms an arithmetic sequence, a(n)=12n-10
1/1000 times, it will take 10,000 attempts before you crack the code. 119,990 seconds. So, what's the average value of 2,14,26,38,...,119,990? Again, another trivial problem (unless I'm blundering here, or not quite understanding you.)

Now, maybe the lock-out period increases every 4th attempt. In that case, the sequence would be 2,2,2,2,14,14,14,14,26,26,26,26,... Which is 4 times the original sequence, but for only 2500 terms instead of 10,000 terms.


Its not ment to be super hard, the teacher said we can choose whatever we want to do the project on. As long as we are able to explain and show the process by which we come to our conclusion using mathematical and statistical analysis.