Questions tagged [rubiks-cube]

Rubik's Cube is a 3-D combination puzzle invented in 1974 by Hungarian sculptor and professor of architecture Ernő Rubik.

Rubik's Cube is a 3-D combination puzzle invented in 1974 by Hungarian sculptor and professor of architecture Ernő Rubik. Originally called the "Magic Cube", the puzzle was licensed by Rubik to be sold by Ideal Toy Corp. in 1980 via German businessman Tibor Laczi and Seven Towns founder Tom Kremer, and won the German Game of the Year special award for Best Puzzle that year.

Source: Wikipedia (Rubik's Cube)

128 questions
3
votes
2 answers

Rubik cubefinder.py error

I wanted to use some code that I found for detecting the Rubiks cube from this site: cubefinder.py. After managing to install all the OpenCV libraries, I get this error when I show the cube to the camera: Python 2.7.2 (default, Jun 12 2011,…
dichterDichter
  • 315
  • 7
  • 16
3
votes
5 answers

Help designing a hash function to detect duplicate records?

Let me explain my program thus far. It is a rubiks cube solver. I am given a scrambled cube (this is the initial state). This becomes the root node of a graph. I am using iterative deepening depth first search to "brute force" this scrambled cube to…
dfetter88
  • 5,381
  • 13
  • 44
  • 55
3
votes
2 answers

Rotating cubes in XNA

So far I have managed to create a Quaternion for rotation. Only problem is now, how do I apply it to only certain cubes? As when I press the right key on the keyboard at the moment, every cube is being rotated continiously around the origin. For…
DAVETELFA
  • 39
  • 3
3
votes
1 answer

Rotating faces Rubik's Cube C#

I've been looking around the internet for a few days now, and I can't really find an answer that i can understand well enough to rotate my Rubik's Cube. I have made my own 3D Model using Blender of a Rubik's Cube and imported it in to Unity which is…
Nicholas
  • 783
  • 2
  • 7
  • 25
3
votes
2 answers

How to solve rubik's cube in a efficient way

Possible Duplicate: Solving Rubik’s cube programmatically i would like to create an application to solve rubik's cube. I read that a computer can solve it in max 20 moves. However searching on internet I can't find how to implement that. So i…
3
votes
2 answers

Camera and Image recognition

I recently watched a youtube video where a guy got a camera to recognize when a rubik's cube was held up to it, and it captured the 9 square color combination before snapping a picture of the cube and displaying the 3x3 grid on the screen of his…
kjh
  • 3,407
  • 8
  • 42
  • 79
2
votes
2 answers

Python 3.2.1: exec('x = y()') sets a value in a toy example, but not in the full code

I'm using an exec() statement to set a value, like so: foo = 3 def return_4(): return 4 instruction = 'foo = return_4()' exec(instruction) # <---- WHERE THE MAGIC HAPPENS print(foo) This comes out as 4, as I expect. My…
Brownbat
  • 266
  • 1
  • 8
2
votes
4 answers

Sequence generation/ breadth first searching

Essentially what I'm doing is trying to solve a Rubik's cube with a breadth first search of all possible moves. I know this isn't the best way to solve the cube, but I only need it for very short sequences (so the depth of the search is unlikely to…
2
votes
3 answers

OpenGL: smudges drawn on image surfaces

I am trying to code an interface to a rubik's cube. However when I draw it there are smudges on the faces of the cube: Here is the well-commented code. Can someone please help me and perhaps run the code and tell me where I might be going…
John Goche
  • 689
  • 2
  • 12
  • 27
2
votes
2 answers

Basics of 3d to draw Rubik's Cube

I'd like to draw a Rubik's Cube on html canvas element with some perspective, but I've never had any experience with 3d graphics, perspective etc. so I'm looking for all helpful resources to achieve this. The only helpful link I've found is for this…
mike_hornbeck
  • 1,612
  • 3
  • 30
  • 51
2
votes
2 answers

Rubik's Cube solving API in Java

I'm currently building a robot which solves a Rubik's Cube. I use an Android phone to scan the cube and I want to solve it in Android too. Is there a library which can solve a Rubik's Cube? Thanks in advance
dbrettschneider
  • 3,173
  • 1
  • 29
  • 28
2
votes
0 answers

Rubik race solving algorithm

I am trying to write an algorithm for solving RUBIK Race. It is a 5 * 5 board with each cell either having a color RED, WHITE, YELLOW, GREEN, BLUE, ORANGE or an EMPTY cell. ie, There will be 4 cells for each color, and 1 EMPTY cell. The cells on…
davidvarghese
  • 637
  • 2
  • 10
  • 18
2
votes
2 answers

Why is my rubik's cube calculation off by 4000?

I'm trying to throw together some quick and dirty javascript code to give me the number of possible piece permutations on a rubik's cube given a constraint such as "1 edgepiece is solved". (sticking to 3x3 for simplicity) When I run the normal 12…
naytivlost
  • 23
  • 3
2
votes
0 answers

Rubik's cube solver in C: program gets killed trying to generate a database

I'm trying to implement Korf's algorithm to generate all Rubik's cube corners permutations. In total it must be 8! * 3^7(88,179,840), but the program gets Killed after generating around (36,000,000) permutations. I used Lehmer code indexing for the…
2
votes
3 answers

Make an object model of a rubik's cube

I've made a small algo which allows me to resolve a rubik's cube on the paper. I now want to implement it, but I can't found an object representation which satisfied me. I easily can see a rubiksCube object, and a "cube" object, which can be…
J4N
  • 19,480
  • 39
  • 187
  • 340
1
2
3
8 9