News for hackers. Stuff that matters.
Re:Self-solving Rubik's Cube by mnr on Monday September 24, 2018 @08:06AM (#18056957)
You could have shuffled it into a position where it takes less moves to solve than you made while shuffling.
Re:Self-solving Rubik's Cube by jfoutz on Monday September 24, 2018 @08:18AM (#18057035)
specifically, rotate one face one quarter turn 3 times. a replay will undo all 3, but the optimal move is to continue the rotation one more quarter turn. (as the degenerate case for a solution being better than unwinding the move stack.)
Re:Self-solving Rubik's Cube by r_c_a_d on Monday September 24, 2018 @08:30AM (#18057103)
He said the shortest implementation, not the shortest execution. I think he meant that the easiest solver to "code" is to just remember the scramble and reverse it.

You can see from the videos that it is not doing that though. The solution is not the trivial reverse of the scramble.

Re:Self-solving Rubik's Cube by mnr on Monday September 24, 2018 @08:43AM (#18057180)
Ah, I misread. Makes enough sense!
Re:Self-solving Rubik's Cube by aidos on Monday September 24, 2018 @08:21AM (#18057051)
More interestingly, the cube is always 20 moves away from a solution, not matter how much you've mixed it up.
Re:Self-solving Rubik's Cube by rimliu on Monday September 24, 2018 @10:02AM (#18057724)
Nitpick: cube is at most 20 moves away from the solution. There may be cases when less moves a needed :)

https://en.wikipedia.org/wiki/God%27s_algorithm

Re:Self-solving Rubik's Cube by Someone on Monday September 24, 2018 @04:37PM (#18061184)
Nitpick: aidos is right. The cube is always 20 moves away from a solution (but that solution typically isn’t the fastest possible (the 20 is in face turns, not quarter turns, so you can always add extra turns to the optimal solution to make the solution take 20 turns))
Re:Self-solving Rubik's Cube by iliis on Monday September 24, 2018 @05:43PM (#18061724)
That might very well be, but is it obviously so? What if there was a position that takes 19 moves to solve in the fastest way possible but the next-best solution takes 21 moves? Is there always a solution that takes an even number of steps?
Re:Self-solving Rubik's Cube by Someone on Monday September 24, 2018 @06:44PM (#18062127)
Yes, there is. If the last turn is a quarter turn, replace it by a half turn and a quarter turn in the other direction. If it is a half turn, replace it by two quarter turns.
Re:Self-solving Rubik's Cube by iliis on Monday September 24, 2018 @06:57PM (#18062202)
Well, okay. Technically you're right ;) But what if you count any movements that are followed by another movement of the same face as a single step?
Re:Self-solving Rubik's Cube by Someone on Monday September 24, 2018 @08:09PM (#18062576)
The set of possible configurations would split in an even and an odd set, so there would be configurations that can’t be solved in God’s number of moves.

(AFAIK, we don’t know God’s number if we count moves that way. I would guess it’s larger than 20)

Re:Self-solving Rubik's Cube by aidos on Monday September 24, 2018 @11:09AM (#18058309)
That's definitely a legitimate nitpick!