# Bandaged cube scrambler

#### Pedro

##### Member
I'm not sure if this belongs here, but...

I was wondering how to make a bandaged cube scrambler...

I thought about creating a (big) tree, with all the possible moves after , [R] and [F] (possible moves at the start), but I think it would be too big

anybody has an idea?

#### tim

##### Member
I thought about creating a (big) tree, with all the possible moves after , [R] and [F] (possible moves at the start), but I think it would be too big

1202436585430588041033063616 elements. Yes, it is too big.

My idea was using an array for each layer
Code:
1 1 4
2 2 4
3 3 0
and a nice algorithm to check whether a move is allowed without destroying any block of numbers.

#### TomZ

##### Member
You would need backtracking for this, the best way to implement it would be recursion. If you had a way to handle moves on the bicube and see which ones are available, you could generate a scramble like this (pseudocode):

Code:
global string scramblefound

scramblefound = ""
biscramble(25, bicube.solved, "")

string biscramble(int length, bicube cubestate, string scramble){
if length == 0{
scramblefound = scramble
}else{
for each avaiable move sorted by random{
return scramblefound
biscramble(length-1, cubestate.applyMove, scamble + move)
}
}
return scramblefound
}
I don't know if this will result in a scramble in a reasonable amount of time, but I suspect it could be quite fast.

#### tim

##### Member
TomZ: The interesting part is "for each avaiable move sorted by random"
and "cubestate.applyMove". The algorithm itself is rather trivial. But i can't think of a decent (small) data structure, which allows both easy manipulation and available move detection.

Pedro told me, that there's just one corner. Maybe it's possible to determine the possible moves from the orientation and permutation of this corner. That would make things much easier.

#### TomZ

##### Member
Yes of course That is the hard part I don't fancy doing.

I think it (the bicube handling part) might be out there already. Jaap mentions he once did a search of the number of positions and configurations. [http://www.geocities.com/jaapsch/puzzles/bandage.htm]

There are only 440 configurations of the bandaged blocks. So that is manageable.

#### JLarsen

Yeah I thought about this once. I just did what would solve it until it was scrambled, then misaligned the center edge blocks as best I could.

#### Isaev

##### Member
For especially complex bandages, which are not so easy to scramble manually, you can write a scramble, as there are usually not many configurations.
And weakly bandaged can be mixed without scrambler

#### ProStar

##### Member
For especially complex bandages, which are not so easy to scramble manually, you can write a scramble, as there are usually not many configurations.
And weakly bandaged can be mixed without scrambler
last post was 11 years ago