Tau Empire Codex 2013 | Army Builder Program
Dark Angels Codex 2013
Chaos Daemons Codex 2013
Chaos Space Marines Codex 2012

Warhammer 40k Forum Tau Online

 

Warhammer 40K Forum

Mathematic Game Theory or "Norwegian Solitaire"
Reply
Old 27 Apr 2009, 18:42   #1 (permalink)
Shas'Ui
 
Join Date: Nov 2007
Location: Sweden
Posts: 671
Default Mathematic Game Theory or "Norwegian Solitaire"

Quote:
Originally Posted by Tau-killer
Maths?

Maths makes TK happy!

Can TK be of service?
Well, why not? I find this a fun problem, and I think guys on this forum will do it as well.

You take a completely normal card deck. Shuffle it. Now take the deck in your hand and turn the very first card. If it's a two, you take the card and the next one in the deck/pile and put at the bottom. (Note, you only turn the first card. The other card is remained unturned.)

If it was a three, you take the card and the next two cards and so on.

Knight(Or what it's called in English) is 11, The Lady is 12 and the King is 13. Ace is 1.


Now, continue to do this until you come the point where a card you have already turned is at the top. When you get to that point, you lost the game. The point of the game is trying to turn every single card.





Now to the mathematical problem. Would one be able to turn all of the cards if you could place all the cards in the deck, in the strict order you wanted to?

And more important, what is the highest amount of turned cards that you can come up with and what is the order you placed the cards that "round"?




My math problem from my teacher is to bet his score of 48. Help, please?




(I'm tired, so please bear with me if this thread is wrongly put or grammatical wrong.
SkullzD is offline   Reply With Quote
Old 27 Apr 2009, 19:29   #2 (permalink)
Shas'El
 
Join Date: Dec 2004
Location: In my secret lair plotting forum domination....hehe
Posts: 3,804
Send a message via MSN to Tau-killer
Default Re: Mathematic Game Theory or "Norwegian Solitaire"

Intriguing....this is going to be interesting! Thanks. ;D
__________________
I never bluff, TK.
Tau-killer is offline   Reply With Quote
Old 01 May 2009, 17:30   #3 (permalink)
Shas'Ui
 
Join Date: Nov 2007
Location: Sweden
Posts: 671
Default Re: Mathematic Game Theory or "Norwegian Solitaire"

What I got so far is that the ending cards should be something like this;


A, Q, A, Q, A, Q, Q, K, K, K, K.

To better show this;


K, X, X, X, X, X, X, X, X, X, Q, A, K, X, X, X, X, X, X, X, X, X, Q, A, K, X, X, X, X, X, X, X, X, X, Q, A, K, X, X, X, X, X, X, X, X, X, X, Q


Because eventually cards will lump up. The only cards good enough to jump over these lumps is the King(=13) The maximum of turned cards in a row should be 12. The king can jump over that.



Thoughts?
SkullzD is offline   Reply With Quote
Old 11 Sep 2009, 10:26   #4 (permalink)
Shas'El
 
Join Date: Aug 2005
Location: Finland
Posts: 2,510
Default Re: Mathematic Game Theory or "Norwegian Solitaire"

Sorry for necromancing an old topic, but I read this when it was new, and got interested. Recently I was bored in the programming class and remembered this, so I made a quick C-program to check the result.

Long story short, one solution (I believe there are many), is here:
(", #, % and $ are to show different suites, they don't really matter but I included them for completetion)

1", 2", 6#, 3",10",12#, 4", 6$, 8#, 3%, 5", 8$, 6%,11$,12", 6", 7#,10#, 2$, 3$, 5%, 7", 8%, 9#, 7$, 9%,13", 2$, 8", 4$, 7%,10$,11#, 5$, 1$,13%, 9",13$, 9$, 1#, 2#,10%, 4#, 1#,13#,11", 3#,12$, 4%, 5#,11%,12%

This goes through every card once. I didn't try to see if it is possible to jump from the last card onto the first, making an endless loop.

Just incase anyone still cared.
LordDemon is offline   Reply With Quote
Old 11 Sep 2009, 14:39   #5 (permalink)
Shas'O
 
Join Date: Aug 2006
Location: Is the Politiburo smoking weed?
Posts: 5,144
Default Re: Mathematic Game Theory or "Norwegian Solitaire"

Well I just tried the game. Suffice to say 7 'goes' and no order seemed to appear in the turned cards. There is something I can say about how long until you will lose.

If we assume a random shuffled deck of 52 cards, then after the first card is turned you now only have 51 cards that you can turn and not lose. Therefore the probabilities go;

51/52 , 50/52 , ... , 1/52

Therefore;

P(you lose on your next turn) = (52-n[sub]1[/sub])/52 * (52-n[sub]2[/sub]) / 52

Expanding out the series that gives a formula (assuming that we haven't lost yet);

P(x) = n!/(x!(n-x)!) * (52-n/52)[sup]x[/sup] * (n/52)[sup]n-x[/sup]

Where x = 51 correct turns over (per turn)[sup]1[/sup]
n = number of turns
! is the factorail symbol n! = n*(n-1)*(n-2)*...*(n-n) , 0! = 1

Hence on your first turn;

P(1) = 1 / 1*1 * 51/52 * (1/52)[sup]0[/sup]

Of course however the deck rotates so there is really a null probability that you could fail on your first go. If we assume that half of 13 is 6, 52/6 = 8.6 Then we can say that until your 9th go this formula doesn't (on average) give you the correct probabilities. It however predicts that the chance of you failing after your 24th go is approaching 1 (5.20E-011
chance of success), assuming that you haven't actually lost yet.

This isn't an 'accurate' piece of math, it's just an approximation of on average which turn would you lose on.

Hell I wouldn't trust it. I got a 14 on a second trial run before I lost.

[sup]1[/sup]Basically if you had had that many goes what would be the chance for getting to that point without having already lost i.e. in n goes you have had n-1 success (you have to lose on the very last go anyhow (assuming 52 possible goes))

[hr]

Not doing math here, surely it is actually impossible to actually complete the game. I'm not sure if this is what Lord Demon maybe referring to. Because you would need to have to turn 51 cards, and have the order such that the last few moves all work exactly if we assume the biggest steps (of 13) 52/13 is 4, but then if we look at the divisors 4, 4.3, 4.72 etc. that means that to jump the last cards. Pah math! No thanks.

/gives up

Gen
Genmotty is offline   Reply With Quote
Old 11 Sep 2009, 20:34   #6 (permalink)
Shas'El
 
Join Date: Aug 2005
Location: Finland
Posts: 2,510
Default Re: Mathematic Game Theory or "Norwegian Solitaire"

To clarify the answer to questions:

Quote:
Originally Posted by Mr.MEHE(SkullzD)
Now to the mathematical problem. Would one be able to turn all of the cards if you could place all the cards in the deck, in the strict order you wanted to?
Yes.

Quote:
Originally Posted by Mr.MEHE(SkullzD)
And more important, what is the highest amount of turned cards that you can come up with and what is the order you placed the cards that "round"?
you can turn all 52 cards, and it may even be possible to jump back to card nro 1 from the lastcard, allowing you to return them all after that. I haven't tested this though.

One sequence of cards is in my original post, with Jack, queen and king replaced with 11,12 and 13 respectfully (and Ace with 1 obviously). I believe there are many others, this is more of a hunch then real data, but I might still make my program to shuffle cards properly at the beginning, oherwise it always get's the same result.

Quote:
Originally Posted by Mr.MEHE(SkullzD)
My math problem from my teacher is to bet his score of 48. Help, please?
If he still is your teacher, you can pass the game. Unless he has done so by now.


[hr]

Genmotty, you can't lose untill you get through the deck once, so first 3 cards are safe. Fourth is firstavailable bust, and only if all the 4 first cards are kings.

Not that it really matters though.
LordDemon is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Which deploys last? "Word in Your Ear", "Grand Illusion", or "Macharian Cross" davidgr33n The Inquisition 4 27 Dec 2007 05:52
Which deploys last? "Word in Your Ear", "Grand Illusion", or "Macharian Cross" davidgr33n Imperial Guard 5 24 Dec 2007 20:38
"scratch" built Leman Russ in the style of German "Mouse" tank (pictures) saffo Conversion 22 19 May 2006 16:22
"Phoenix-King of the Hill"- a short multiplayer game. Yriel of Iyanden Craftworld Eldar 15 20 Mar 2006 14:42
"Glory In Death" 40k computer game - Ngage Website ShasEl_Tael Other Games 7 28 Sep 2005 11:42