# Rubik's Cube with no two squares of the same color on any horizontal, vertical or diagonal line

Consider the 12 lines depicted below which all run through the centers of the 9 color squares of a single face of Rubik's Cube.

1. Can you find a scramble such that on each line all squares have different colors? And this of course simultaneously on all six faces.
2. Find a scramble which needs only 14 moves. If you assume six colors on each face this scramble is unique up to rotation and reflection of the cube and there is no shorter scramble.

Hint 1: There are only three possible ways how colors can be distributed on one face (up to rotation and reflection of the face and up to permutation of the colors). You can find them with pencil and paper.

Hint 2: The second question is impossible to answer without a computer program. But with the pattern editor of the freely downloadable Cube Explorer program an answer to the question is not difficult to obtain.

• The cube with all edges flipped and all corners twisted in the same direction is not a valid scramble, but it does meet the criterion that none of the lines have two of the same sticker. Commented May 22 at 0:52
• @AxiomaticSystem Wouldn't every edge facelet match colour with one of the adjacent corners? Maybe swapping each pair of opposite edges would make it work. Commented May 22 at 4:13

Update: I think I actually found a 22-step solution for real this time. Disclaimer: I still don't know how to play Rubik's cube. But I realized a valid scramble can be composed of simpler valid scrambles, so I tried to construct simpler permutations that are valid (tested with online solver and reversed the solution to get the scramble sequence, I still can't solve anything) and composed them together that might get what is needed.

Its scramble sequence is R2 B2 L2 U R2 F2 D R2 U2 F' L U' B D' L R D R F' U R' U

It's basically a composition of 3 ideas (partly thanks to the comments of @AxiomaticSystem)

switch all diametrically opposite corners (keeping side colors on the opposite faces):
solve: U R L D2 R L' U2 F2 D2 F2 B2 L2 B2 D2 F2 U
cause: U' F2 D2 B2 L2 B2 F2 D2 F2 U2 L R' D2 L' R' U'
------
flip colors on all edges' sides
solve: R L U2 F U' D F2 R2 B2 L U2 F' B' U R2 D F2 U R2 U
cause: U' R2 U' F2 D' R2 U' B F U2 L' B2 R2 F2 D' U F' U2 L' R'
------
twist 4 upper corners clockwise, 4 lower corners counterclockwise (can't twist them in all the same direction)
solve: R2 B U2 F2 U R2 L2 F2 D2 F B2 U2 F2 U2 D F2 D2 L2
cause: L2 D2 F2 D' U2 F2 U2 B2 F' D2 F2 L2 R2 U' F2 U2 B' R2


And after composing these three scrambles, I found only a few squares on the sides are the same color so I just need to twist up once, then solve it and invert the sequence to get this scramble. I still don't know how to find a 14-step solution though, good luck to you all!

(the following is obsolete but kept here in case it's useful to anyone)

Update: this solution is wrong, online solver said it's "solved", didn't report an impossible scramble, but the final result is not solved, but has switched colors on the four corners on the white and yellow faces like this picture. I don't know how to fix it yet, maybe someone more familiar with Rubik's cubes can find a solution.

Disclaimer: I don't know how to play Rubik's cube. I just found a way to assign colors on faces and tested in an online solver, and it kept saying I need to twist a corner or something, so I twisted 2 corners (with trial and error) and found this solvable with 22 steps:

Details: I figured you need at least 5 colors on a face, for example like this:

A B C
C D E
E A B


And I thought I'd try to distribute each color on 5 faces, 1 with it on the center and 2 each on 4 other faces, heck, let's try it on 4 adjacent faces of the face with that color in the center. (At least I know you can't change the color of a face's center by twisting :) For consistency's sake, I first tried making the color on an edge the same as the center of the face adjacent to that edge, and the corresponding colored corner on the counterclockwise side of the opposite edge (as in the above grid). And the online solver said it's unsolvable, and a corner needs to be twisted. I tried twisting a corner counterclockwise(the only way to avoid repeated colors), and it still said I need to twist a corner. I tried a few other things and it said I need to add all corners once or all edges once or something, so I figured that must be worse, why not go back and twist another corner instead? I figured out twisting two adjacent corners won't work because that repeats colors, so I next twisted two corners that are diagonally opposite on the cube, and it worked. Edit: I made a mistake and thought twisting corners diagonally opposite on a face also seems to work, but it doesn't because it repeats a color.

• Sorry, but the image does not show a valid cube stickering. Take for example the corner in position URF in your picture. It shows clockwise white, green and red. But the unique corner with the colors white green and red shows these colors anti-clockwise. If you disassemble your depicted cube and build it together again you will not get a cube with a single color on every face. Neither do the 22 moves correspond to the picture (not as solver and not as a generator). Commented Jun 17 at 22:58
• @HerbertKociemba Sorry, I have no idea because the website says it's solved. I checked on another website and it also doesn't report any errors, but the final result is not really solved for some reason. (I constructed it again and it seems a bit different but has the same problem) rubikscu.be/solver/… Commented Jun 17 at 23:14
• Yes, your online solver does not check the stickering of cubes correctly which results in unsolvable cubes in cases where the stickering is wrong. Commented Jun 18 at 9:19
• @HerbertKociemba I found a new solution, hopefully it's real this time. Commented Jun 18 at 22:37
• No, the stickering also is invalid. Commented Jun 18 at 23:13

Since the bounty has ended and nobody tackled question 2 I will show my way of solving this part (which obviously solves question 1 too).
First we observe that it is impossible to put two stickers of the same color on two edges or two corners. So there is a maximum of two stickers of the same color with one on an edge and one on a corner. The only possibilies are now

1. 5 colors on a face with 4 pairs of same color stickers and a 5th color
2. 6 colors on a face with 3 pairs of same colors stickers and 3 single stickers with different colors.

In the 5 color case the only possible distribution looks like this

ADB                         BDA
CEA    or the mirror image  AEC
DBC                         CBD


In the six colors case we have

ACB                         BCA
BDA or the mirror image     ADB
EFC                         CFE


and

ADC                       CDA
BEA  and the mirror image AEB
FCB                       BCF


Different letters mean different colors, same letters mean same colors. Of course the patterns can be rotated arbitrarily by 90°, 180° or 270°.

In the pattern editor of Cube Explorer we enter the four possible cases with 6 colors like shown below. The actual colors we choose for the letters are unimportant.

Running a couple of minutes the program finds all possible valid cubes with 6 colors on every face and with the restrictions given in the puzzle description. There are exactly 4082 different cubes up to rotation and reflection.
With "File|Save Maneuvers..." we save these cubes and clear the Main Window from the context menu by right clicking in the Main Window.

With "Options|Huge Optimal Solver..." we prepare the program to use a relatively fast optimal solver to solve the 4082 cubes optimally.

We load the 4082 cubes again with "File| Load Maneuvers..." and start the optimal solver using "Run|Start Autorun for Optimal Solver". It takes several hours to compute the optimal maneuvers for the 4082 cubes.

Finally we sort the results with "Edit|Sort Cubes by Maneuver Length". There is only a single cube which needs 14 moves and the generator D' L2 U R D F2 R2 D2 U2 R' U R B' R' (14f*)

I hope the description motivates you to search for other - eventually even more interesting - cubes with the pattern editor of Cube Explorer.

• Cool! I recently saw a video (wonder why YT started recommending so many Rubik's cube videos lol) where a cube has multiple solutions using different sets of stickers like this youtu.be/fL7HS2DXT6k , but the distribution of the stickers doesn't look very nice because when one set is solved, other sets are not evenly distributed and can look clumped together. It would be nice if multiple sets of stickers are distributed so that if any set is solved, the other sets all have no two squares are on the same line. Is this possible for more sets of stickers? If so you can make such a cube! Commented Jun 24 at 17:56
• Also, is the 14-step scramble special in some way? For example is it a composition of other interesting scrambles, or is it impossible to build it out of simpler symmetric scrambles? And by the way, thanks for the bounty! Commented Jun 24 at 18:08
• From an esthetic point of view I am no fan of these multiple sticker cubes so I am not really interested in extending my puzzle to this kind of cubes. The 14 moves scramble has no special secret behind it, the pieces simply fall into the right places after 14 moves. Btw I did not award the 25 points to you. This was automatically done by the system because the guidelines say that if the most upvoted solution has at least two upvotes you get half of the bounty even if the donator of the bounty does not accept the answer. Commented Jun 25 at 14:00
• So 25 points is a good solution in this case because you solved half of the puzzle. Commented Jun 25 at 14:01