Game on (18 April 2021)

The obvious option is to clear all the cards in column 6 and then turn over a card in Column 2. We can improve this plan slightly by turning over column 2 first since the empty column isn’t running away regardless of the new card. Clearly the minimum guaranteed turnovers is 2.

A closer look reveals that we can obtain two turnovers in a completely different manner. We get the empty column, then dump the Eight of Spades in column 8 into column 6. This gives us two turnovers in columns 7 and 8.

Well done to Bart for finding both options.

One problem with the second plan is we will have an off-suit 8-7 in Column 6 so it will be much harder to recover the empty column. Also, the Three of Clubs is not as useful as it looks. There are plenty of Threes left in the deck and two of the Deuces are in a junk pile in Column 3 anyway. Yes, the obvious plan reveals an Ace, but we have plenty of Twos floating around. Still one can argue that in a poor position it makes sense to play for “best-case scenarios” and any Nine puts us right back in the game.

It’s hard to judge. Rot13(shpx vg). I’ll just roll the dice, or more precisely, use the Random Number Generator on my phone. RNG votes for the funky play. Funky play it is.

It’s time for the second knowledge bomb from this blog:

If you use the random number generator and lose you can at least blame the results on something other than what’s in the mirror

Knowledge Bomb from Edifying Thoughts of a Spider Solitaire Addict

We get the Ten of Spades. No turnover but at least we can use Column 4 and avoid having an off-suit 8-7 in Column 6. We get the Six of Spades, Three of Diamonds and Three of Hearts. That’s too many Threes so we don’t get our empty column back! But at least we have no more face-down cards in column 8 and from the previous knowledge bomb we know there is a fair chance of column 8 becoming a new free space in the future. At least we can get an extra turnover in column 7, but that gives us an offsuit 8-7 in column 6 – so now any Nine would be “right card wrong timing”. Them’s the breaks, if you pardon the terrible cliché.

Still, our position could have been a lot worse. How would you continue?

Don’t Miss the Forest for the Trees (alternative version)

Forrest Gump, Treebeard (from LOTR) and the Elephant Man walk into a bar. Treebeard starts a game of Spider Solitaire with the others watching. He soon reaches the following position:

“This is not great,” said Treebeard. “What would you do here?”

“I’m not sure,” replies Forrest. “But I think we should step back and take a look at the big picture.”

Treebeard enjoyed the routine of computing minimum guaranteed turnovers, calculating outs (the chances of getting a “good card”), looking for in-suit builds etc. Long term planning was beyond his comfort zone. But Treebeard had to admit his win rate was rather lousy. Perhaps there was more to Spider Solitaire than computing minimum guaranteed turnovers, calculating outs, looking for in-suit builds etc

“We seem to have an abundance of various ranks and severe shortages in others,” said Forrest. “We have a million Twos and Fives, negative million Threes and Nines. Not to mention we have very few in-suit builds. In fact I don’t see a run of three cards in-suit anywhere.”

“Don’t forget about possible cheevos,” says the Elephant Man.

“Wow!,” replies Treebeard. “You remember everything.”

“They don’t call me Elephant Man for nothing.”

“Yes,” replies Forrest. “We shouldn’t forget the cheevos – you never know when they come in handy. Unfortunately I think at this stage of the game we will have enough trouble winning, let alone achieving a cheevo. So forget about cheevos for now.”

At this point a Muppet walks into the bar and joins the group.

“Allow me to introduce myself,” says the Muppet. “I’m Count von Count from Sesame Street.”

“Hey I remember you!,” says Elephant Man. “You appeared on a previous blog post by Spider GM!”

Count von Count places a glass of water on the table. Unfortunately, he never dared to touch a drop of alcohol. Imagine what would happen if he submitted to temptation and his fan club found out!

“Um …” says Elephant Man, “I’m wondering if you could contribute some meaningful comments for this game.”

“I’m not very good at this game,” says Count von Count.

“Don’t worry,” says Treebeard. “None of us are any good either.”

“I guess I can count the cards if that helps,” offers Count von Count.

Count von Count quickly takes out a crayon and sketches the following table on a piece of paper:

AceTwoThreeFourFiveSixSevenEightNineTenJackQueenKing
4623644414545

“Interesting,” says Forrest. “There is only one Nine exposed. So, there is a reasonable chance more Nines could turn up very soon”

“With two free Tens available,” says Treebeard, “a Nine certainly wouldn’t hurt.”

“Or if you had the same luck as me exactly fifty-nine days ago you might draw four Nines and three Threes on the next deal,” says Elephant Man.

“I only see one free Ten,” says Count von Count as he finishes his water.

“But we can put the Four on Five, Seven on Eight and free the Ten of Clubs, so we have two virtual free Tens,” says Treebeard.

“That’s why I’m not very good at this game,” laughs Count von Count.

“I should also mention the abundance of Twos may not be too much of a problem,” adds Forrest. “We have a junk pile in column 3. That takes care of two Deuces. So that’s a small piece of good news in a game that’s not going so well.”

“Thanks for your analysis,” says Treebeard. “I think I am finally getting to understand the secrets to improving at Spider Solitaire!”

“Now, where was I?” Treebeard asks himself. “Oh, that’s right. I was trying to work out what my next move should be.”

THE END

Don’t Miss the Forest for the Trees

Having dealt three rows of cards from the stock, I think now is a good time to take stock (badumtish!) before thinking about our next moves. We don’t wanna miss the forest for the trees, if you pardon the terrible cliché.

The game state is deplorable. We have a million cards face-down and very few in-suit builds. Bart correctly points out we don’t even have a run of three cards in-suit anywhere. But at least we have an empty column and a turnover in column 2.

In the opening stages it is easy to approximate the chances of increasing our minimum guaranteed turnovers by assuming each rank from Ace to King occurs with an equal probability of 1/13. But with many cards exposed, this assumption is no longer reliable. We can still apply the usual routines of “computing outs” but we need to be careful.

AceTwoThreeFourFiveSixSevenEightNineTenJackQueenKing
4623644414545

We have a severe excess of various cards (Twos, Fives, Eights) and droughts (Threes and Nines in particular). The good news is once we turn over more cards, these inequalities should even out. But we need to turn over cards first!

We have some “good news” in column Three. Two useless deuces and aces are already used up, so this effectively makes a good junk pile. Basically our shortage of Threes is not as bad as it looks. Most of the buried cards are relatively useless – apart from that Three of Clubs in column Eight. Still, given our poor position, one “inefficiency” could be enough to consign us to a loss. If the Three of Clubs were at the front of column Eight instead of being buried our position would be much better.

Bart talks about “Market Value”. There are two Sevens available for the 6-5 of Clubs so Sevens are expendable. In contrast, there is only the Six of Hearts available for the 5-4 of Diamonds, so Sixes are not expendable. At least we get our hole back. We also have two Jacks that “want” the Queen in column Ten, so Queens are definitely not expendable.

If you have an incredibly good memory, you may recall that we started the game with the intention of listing a number of possible cheevos as a possible bonus. Unfortunately, we will have more than enough difficulty with winning the game, let alone pulling off a cheevo. It seems our most likely cheevo is getting someone other than Bart or George to contribute a meaningful comment, and I wouldn’t wanna bet my Ph. D. thesis on that happening any time soon!

BTW, last time, I yanked the J-T from column 1 in hopes of being able to shift the 7-6-5. My gamble was partially correct – we got our empty column back but the Two of Hearts scotched any dreams of column 1.

In the next week I will answer the question of finding the best play.

Awesomeness has been achieved!

I have finally achieved awesomeness! My Spider Solitaire Sudoku puzzle has been featured on Cracking the Cryptic.

For those who are interested in the puzzle only, here is the grid: if you’ve played any Spider Solitaire the rules should be guessable – and if you get a unique solution then you know you’ve guessed correctly 😊 But if you’re interested in the back-story then please read on.

If you follow this blog regularly, you are probably aware of a paper I published some time in 2019. I showed that a particular Spider Solitaire server was biased: if you win too many games then future games will have the cards stacked against you – and one could “prove” this using Statistics.

I use quote marks because the nature of Statistical testing always implies some degree of uncertainty. For instance if you are 95% confident of a hypothesis, then there is a 5% chance you made an error. But it is commonly accepted practice. If your experiment is sound and you get a sufficiently small p-value then go ahead and publish it anyway. You may be wrong, but – to put it in Poker terms – your results pretty much force you to call all the way to the river. If you are beat then you are beat.

Of course, getting the results you want is only the first step. We all know the academic publishing model is broken. The peer review model is hopelessly flawed. At best, peer review is based on good intentions and met the demands of research scientists 30 years ago – but certainly not today. It already takes long enough to get accepted into a mediocre journal, or even the dreaded arXiv. If you’re that desperate you might be willing to spell arXiv backwards. And don’t get me started on predatory journals. I won’t describe the ills of academic publishing in all its gory detail. Someone else can probably explain it much better than I can. In my case I ended up publishing into a high school journal. Parabola from UNSW to be exact.

But at the end of the day, publishing is essentially “a way to prove or showcase your research skills”. Once you complete your thesis (or minor thesis, 3-month vacation employment, etc) and may or may not be a major component of your career depending on your employment. (It is true that my Spider Solitaire paper is not relevant to my job, but that has nothing to do with the Fundamental Theorem of Calculus.)

Still, the Parabola publication still wasn’t entirely satisfactory. My paper wasn’t truly a publication. It was a story. I wanted to tell a story about how a certain Spider Solitaire was broken. There is nothing intrinsically wrong with Parabola (with the possible exception of some really lame comics and puns), but try telling that to the average Joe Bloggs with an average job, has little aptitude for mathematical puzzles and swears by Nova FM. In fact, telling this story was the original motivation for me starting this blog in the first place.

Scientists don’t have a way of getting their work recognised. They have no way of “controlling the narrative” if you will. I can publish a paper in some journal. Or I can post something on a blog and have all the scientific evidence to back it up. But how many people are going to read it, let alone believe it?

Enter Cracking the Cryptic.

You may have already guessed I am a fan of CtC (not necessarily because of this blog!). I was vaguely aware of it last year. It seemed to be massive in the UK.  I tried one of the harder puzzles. Solving it was beneath my dignity – after all I scored a silver medal in the 1995 International Mathematical Olympiad. Okay I get it. There’s a pandemic going on. People are struggling in the UK. Some viewers have even commented on YouTube how watching episodes of two people solving Sudoku puzzles helped their mental health issues. I’m living in Australia not the UK. Australia really is the lucky country, so who am I to judge?

I then stumbled on this puzzle by Lucy Audrin.

This is a “Sandwich Sudoku with a twist”. Before solving the puzzle Mark briefly mentions Lucy’s website and eventually finishes the puzzle in just over 15 minutes.

You read that right. Lucy wanted to draw attention to her website. All she had to do is submit a half-decent puzzle to CtC and Mark will take care of the rest. To be fair her puzzle is more than half-decent and a good illustration of how one can keep the puzzles fresh by tweaking various rulesets (such as thermometer, anti-Knight, XV, arrows etc). If Simon and Mark only did classic Sudoku every day of the week, CtC would have finished long ago. I should also mention that Lucy can write much better stories than I can!

Great – if Lucy can draw attention to her website then perhaps I can do the exact same thing with Spider Solitaire.

This was much harder than anticipated.

It would surprise nobody if I claimed I could construct a correct Sudoku puzzle with a unique solution and Spider Solitaire theme. There was one obvious hurdle: if I submit my puzzle and it gets rejected – then good luck trying to resubmit the same puzzle a second time. I decided to play it safe by first submitting “test puzzles”.

It was a long process. Essentially I needed to “play the networking game” and gradually build up reputation. I spent a significant amount of time testing puzzles by other setters, joining the Discord server and chatting, signing up for Patreon, creating my own puzzles, etc. I submitted the above Spider Solitaire paper to the Discord a few months ago, but eventually realised that was not the same as submitting directly to CtC (submitting to Discord only means CtC have permission to do it, if it gets nominated). Yes, networking really did make things a lot easier in the long run. If you play nice and do all the right things then eventually people will help you when you need them to. If Sudoku is your thing then I heartily recommend you join the discord server. Great people, great puzzles, great jokes and cultural references. Occasionally somebody may attempt to pull off a rick-roll. What’s not to like? 😊

I emailed CtC my puzzle earlier this week and finally my luck was in.

So there you have it. If you follow my blog regularly, then I hope you enjoyed the journey as much as I did. Until next time, happy Spider Solitairing 😊

Game on (3 April, 2021) – Alternative Version

Joe Bloggs mulled over the possibilities. After a poor start, things were starting to look up. He had obtained an empty column for the first time. Unfortunately, it wasn’t quite possible to expose a card in column One. He had to turnover a card in column Two, Seven or Eight, and in each and every case he would use up the empty column.

Joe Bloggs had a few hobbies: Spider Solitaire, Sudoku and binge-watching his favourite YouTube channel. He could wield a mean thermometer, kropki, anti-knight, little killer and he could even recite a little-known theorem concerning sets of squares containing identical digits – but he never had an aptitude for Spider. Despite his years of experience at the latter he had somehow failed to improve his game.

Joe Bloggs glanced at the sky. He saw some small strange object, or did he? Perhaps it was just an apparition and his eyes we replaying tricks on him.

Column 2 was an option. The in-suit build was tempting but Joe recoiled at the thought of revealing another Ace. This was not Texas Holdem. Aces and Kings were not your friends. Kings could only shift to an empty space and nothing could move onto an Ace. Column 8 was also not great. Certainly no need to expose a third Eight at this stage.

Suddenly, Joe realised his eyes weren’t playing tricks on him at all. The object was getting larger … and closer. He quickly whipped out a pair of binoculars and was able to make out the shape of nine giant red letters. He had barely enough time to work out the anagram of DEEGKLNOW before being forced to close his eyes, drop his binoculars and cover his ears.

Most bombs give off an unpleasant smell but this one had a strange but pleasant peachy-smelling perfume, inducing a drunken stupor. Without knowing why, Joe ambled slowly towards the debris and quickly caught sight of a silver shiny scroll. He bent down and picked it up. He slowly unravelled the scroll and found the following inscription:

Was that God’s way of admonishing him for being such a poor student of the game? Or was God deliberately insulting his intelligence? Maybe a lame attempt at a prank? Not likely – he couldn’t imagine God missing the 1st of April by two days.  Whatever it was, God surely could have used a bit more tact. After coming back to his senses, Joe realised the layout of cards had somehow remained undisturbed – although the playing hall had been totalled. Luckily he was playing with physical cards instead of a computer.

Joe studied the cards again, and decided the correct play was to yank the J-T from Column one onto a Queen. Even though he could not shift that stupid off-suit 7-6-5, he knew that the chances of doing so later were considerable. Column 6 would never contain face-down cards no matter how well or badly he played, and even he knew from experience that having no face-down cards to worry about would make it so much easier to win back the empty column. Finally, Joe thought to himself, he was beginning to understand the deeper secrets of the game.

Unfortunately Joe Bloggs exposes a Two of Diamonds and is forced to deal another row. “Rot13(bu sbe shpx’f fnxr)” shouts Joe as he angrily slams a fresh row of 10 cards onto the tableau.

THE END

Game on (3 April, 2021)

Here is the position from last time:

It turns out we cannot turn over a card without losing the empty column. We can “yank” the J-T in column One onto the Queen (or better still, shift the J-T-9 of Hearts in column Ten onto the Queen of Hearts first, but we cannot shift the off-suit 7-6-5 onto an Eight. As a general rule, one hole is not enough to shift a sequence of three cards if they are all off-suit. Well done to Bart for spotting this.

Note that we exposed the “wrong” Five last week. If it were the Five of Hearts instead of Clubs then we can turnover column 1 without losing the empty column (yank the J-T, swap the Five of Diamonds with the Five of Hearts and then we are good to go).

Bart gives four possible plans:

  • Turn over a card in column h, putting an Eight into the empty column.
  • Move the queen of Hearts directly onto the empty column
  • Move the 5-4 of Diamonds onto the empty column, then dump the Queen of Hearts onto the King
  • Dump the 6-5 of Clubs onto the empty column then build in-suit with 2-A of Diamonds.

There are many variations possible but any reasonable sequence of moves boils down to one of the above four plans. Another key decision is: do we yank the J-T from column One?

Bart prefers the third option, with the Boolean yank_JT flag set to TRUE. His exact move sequence is:

fb,af,jg,aj,fa, de,df,gd

I have a few things to say about this:

  • The move jg is illegal! We should perform jg before af. As so often happens in delicate situations: move order matters!
  • The first move should be fe not fb. This retains an extra in-suit build for no cost.
  • It will be necessary to break an in-suit build in Hearts if we are to turnover column Seven. The last move gd is therefore also illegal.

Still I think Bart has done extremely well to spot both the correct plan and value of yank_JT: even though we can’t turnover column 1 yet, we might be in a good position to do so after the next deal.

It is true that dumping the Queen directly into the empty column has an advantage over dumping the 5-4: we regain the empty column if the next card is a King or a Six. The downside is if nothing good happens then the Queen will be blocking Column 6 with only three Kings unseen. This could be unpleasant, especially with at least three face-down cards in every other column.

You may be wondering why I chose to tidy up column One now when I had an earlier opportunity to do so. The reason boils down to the following knowledge bomb from Edifying Thoughts of a Spider Solitaire Addict:

An empty column will never contain face-down cards for the remainder of the game.

Why is this important? Since column 6 will never contain face-down cards for the remainder of the game our chances of recovering an empty column are decent. It is so much easier to win back an empty column if there are no face-down cards to worry about. And once we get the empty column back, we have a reasonable chance to shift the off-suit 7-6-5 onto an Eight.

In summary, my move sequence would be “fe,de,jg,af,aj,fa,gj,de,gd”

We expose a Two of Diamonds and are forced to deal another row.

As usual, we have an interesting decision to make immediately dealing a new row of cards. How would you continue here? Are there any tesuji possibilities, borrowing a term from the game of Go (a.k.a. Baduk)? Or should we simply ask ourselves What Would Captain Obvious Do?

Game on (27 March 2021)

This is the position from last time

The obvious play is fj,fj but Bart recommends to tidy up with eb,eh,eg,je presumably followed by fe,fe turning over a card. In fact there are several reasonable options to choose from, despite the fact we have only one guaranteed turnover. Let us look at the position a bit more closely:

After fj,fj we get an extra turnover if we expose any of the following cards: A4577TJK. Note that I count the Seven twice since that gives two turnovers.

With Bart’s suggestion we get a turnover if we expose any of the following: A47TJK. Note that a Seven is only worth one turn-over since the 6-5 in Column Two is offsuit. This would be a significant price to pay in a game that’s not going so well. Another long-term problem is we are shifting cards off column 5 but there is little chance of clearing the King of Hearts anyway – unless we get something like 8H-7H-6H-5H-4H-3H-2H-AH on the next deal. Good luck with that!

Looking for other options reveals the possibility of working on column One with ab,jg,aj,fj,fj. This allows a turnover if the next card is any of A4577TK and also guarantees the best possible  layout in column 1 even if we get a bad card in column 6. A disadvantage is we commit ourselves to shifting the Jack of Diamonds onto a Queen when we might prefer the Jack of Clubs.

Our main priority is turning over cards and empty columns.  If we get an empty column then in-suit builds will take care of themselves. With several reasonable options to choose from there is no standout play. I chose the simple fj,fj (note that jg,fg,fg is an extra in-suit build but would not result in a turnover if we get a King).

We turn over a Five of Clubs – good thing we kept that Six of Clubs free, and as Texas Holdem players are wont to say – it was suited!

We turn over the Four of Spades, and that’s our first empty column!

Unfortunately we’re not yet in a position to party hard, pretend the game is Backgammon instead of Spider Solitaire, whip out a doubling cube and look for someone willing to bet against us winning with at least one cheevo to boot. We’ve still got some work to do.

I know it sounds trite but with great power comes great responsibility. Our empty column means there are a great many possibilities to consider, and therefore more chances of choosing a sub-optimal line of play.

How would you continue?

Game on (20 March 2021)

This is the position from last week.

Bart suggests we move the Ace of Hearts to column 4, split an in-suit build by shifting the Ten of Hearts onto the Jack of Clubs, then take the turnover in column 6. Our notation would be gd,gh,fh,fh.

The reason for splitting the J-T of Hearts is to focus all our efforts into getting a free space in column 6. However I don’t like the idea of dumping so much junk into column 8. I would rather have the junk in column 10 since that already has two Kings.

Bart’s play would only gain if the next card in column 6 was a Jack. Then even if we did obtain an empty column there is a good chance we are forced to give it back anyway. That’s a lot of ifs and buts for the cost of one in-suit build and junk in the wrong column.

Still there is not much difference between the plays and our position is rather poor in any case.

Bart also briefly mentions other plays which are clearly inferior, e.g. Jack of Clubs onto Queen of Spades, forfeiting a turnover for no reason.

With nobody else suggesting a spectacular brilliancy that everybody has missed, I’m going for the simple gd,gj, turning over a card in column 7 and intending to turnover column 6 if nothing better turns up.

We get the Queen of Hearts.

This raises an interesting point. We have three “excess Kings” (i.e. unaccompanied by a Queen) in column 4,9,10. This suggests Queens may be difficult to extract in future rounds. Clearly the Queen was not the best card (no extra turnover!), but it does give us some options.

We could continue with the original plan of turning over column 6. Are there any other options to consider? Remember that the most obvious move is not always the best! How would you play here?

Game on (13 March 2021)

This is the position from last time:

An obvious option is to build in-suit with 2-A of clubs in column 3, but that is only one turnover as well as exposing another ace. A closer look reveals we can obtain two turnovers in columns 6 and 2 which is clearly far superior.

It is possible to combine both plans with cg,fg,fi but I would rather avoid that. If we played fc,fi and turned over a Deuce we would still get the turnover in column 3 anyway. So fc,fi it is.

We get Eight of Clubs and Five of Spades as our turnovers. Obviously we turnover another card instead of building in-suit and exposing a King. Unfortunately we get another Ace. We then do some tidying up before dealing a new row.

Not the greatest start to a game of Spider Solitaire, but the only bright spot is Colorful Sisters is now following my blog (unfortunately a cheevo only occurs if they contribute something meaningful in the comments section). Going back to more important matters – how would you continue here?