Page 1 of 1

Maths help

PostPosted: Jul 11th, '14, 09:01
by Relish


I know there are lots of maths whizz’s on here so wondered if someone could help with this.

If someone looked at your phone screen and could see smudges on 4 numbers used as the PIN, then how many different combinations would there be?
If you duplicated 1 number, so only 3 smudges could be seen, how many combinations could there be (without them knowing which number was duplicated)?

Thanks for any help,

Rich


Re: Maths help

PostPosted: Jul 11th, '14, 09:36
by moonbeam
I'm not 100% sure, but I think I've got it right:

When there's 4 smudges, the number of ways of arranging 4 numbers is 4 x 3 x 2 x 1 = 24 possible combinations.

For 3 smudges, consider the possibilities:
If we assume the smudged numbers are 1, 2 and 3; then there are 3 possible sets of 4 numbers, viz: 1,1,2,3 .... 1,2,2,3 ..... 1,2,3,3. There are 24 ways of arranging each set, so in total there are 3 x 24 = 72 possible combinations. Edit: This is incorrect - see my next post below


Re: Maths help

PostPosted: Jul 11th, '14, 10:20
by Relish
thats great, thanks.

(its for some patter for a PIN divination routine ive been thinking about)


Re: Maths help

PostPosted: Jul 11th, '14, 11:04
by moonbeam
Actually I made an error:

When there are 3 smudges, there are no longer 24 combinations for each set of 4; cos say for example 1,2,1,3 is the same as 1,2,1,3 (the 1's are reversed but the pin remains the same), therefore the list needs to be halved:
There are therefore 3 x 12 = 36 possible combinations ... I think I'm correct this time :P


Re: Maths help

PostPosted: Jul 11th, '14, 23:53
by Part-Timer
moonbeam wrote:When there are 3 smudges, there are no longer 24 combinations for each set of 4; cos say for example 1,2,1,3 is the same as 1,2,1,3 (the 1's are reversed but the pin remains the same), therefore the list needs to be halved:
There are therefore 3 x 12 = 36 possible combinations ... I think I'm correct this time :P


That sounds right to me. It's a bit like the old Mastermind game. It was (I recall) a bit harder to guess the code if all the pegs were different colours. As soon as you had a duplicate colour, there were fewer possible combinations.


Re: Maths help

PostPosted: Jul 14th, '14, 16:55
by BrianO
I could be wrong here... but I think its 18.

would it be 3 x 3 x 2 x 1 = 18

(I haven't done this kind of maths in a long time!!!)


Re: Maths help

PostPosted: Jul 14th, '14, 22:05
by moonbeam
BrianO wrote:I could be wrong here... but I think its 18.

would it be 3 x 3 x 2 x 1 = 18

(I haven't done this kind of maths in a long time!!!)


If the numbers x, y and z are smudged, the possible pin options are:
x, x, y, z ----------------------------------- y, y, z, x -------------------------- z, z, x, y
x, x, z, y ----------------------------------- y, y, x, z -------------------------- z, z, y, x
x, y, x, z ----------------------------------- y, z, y, x -------------------------- z, x, z, y
x, y, z, x ----------------------------------- y, z, x, y -------------------------- z, x, y, z
x, z, x, y ----------------------------------- y, x, y, z -------------------------- z, y, z, x
x, z, y, x ----------------------------------- y, x, z, y -------------------------- z, y, x, z
y, x, x, z ----------------------------------- z, y, y, x -------------------------- x, z, z, y
y, x, z, x ----------------------------------- z, y, x, y -------------------------- x, z, y, z
y, z, x, x ----------------------------------- z, x, y, y -------------------------- x, y, z, z
z, x, x, y ----------------------------------- x, y, y, z -------------------------- y, z, z, x
z, x, y, x ----------------------------------- x, y, z, y -------------------------- y, z, x, z
z, y, x, x ----------------------------------- x, z, y, y -------------------------- y, x, z, z

36 in total .... I don't think there are any errors - each of the above possible possiblities contains x, y and z with one of them duplicated once.


Re: Maths help

PostPosted: Jul 15th, '14, 08:52
by Mr_Grue
Well that's f_____ up right there.


Re: Maths help

PostPosted: Jul 15th, '14, 13:05
by BrianO
I'm now glad I added the 'I could be wrong here'

I think its time for me to revise my maths... I used to be good at the stuff. :)