Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Defining Identical Piece in Solved State, values not contiguous #65

Open
DougCube opened this issue Nov 23, 2024 · 14 comments
Open

Defining Identical Piece in Solved State, values not contiguous #65

DougCube opened this issue Nov 23, 2024 · 14 comments

Comments

@DougCube
Copy link

DougCube commented Nov 23, 2024

I modified a working definition file's solved state to have some identical pieces but get this error:

11: ! values are not contiguous

Why must values be contintiguous here? Isn't it just to identify which pieces are unique and which are identical to each other?

My use-case is this. I want to branch a definition file with all unique pieces to a series of definition files with different subsets of pieces being identical. If I have say 8 corner pieces, I'd like to use the number "9" to denote the pieces I no longer want to "solve" because trying to pick say the lowest unused index may still leave gaps, and it would also force me to pick possibly different numbers for each new definition file when I'm trying to generate them in bulk.

CORNERS
1 2 3 4 5 6 7 8
0 0 0 0 0 0 0 0

to

CORNERS
1 2 9 4 9 9 9 9
0 0 0 0 0 0 0 0

Would it be possible to change the behavior and support such usage?

(I should probably start a separate thread for this:)
In addition, I would like a way to indicate certain pieces can ignore orientation within that "Solved" section -- not certain set of pieces but a subset of the same piece type. I realize that as a workaround I could switch to defining the set of 8*3 stickers (with no orientation) instead of 8 pieces (with 3 orientations), but that can become unwieldy.

@rokicki
Copy link
Collaborator

rokicki commented Nov 23, 2024 via email

@DougCube
Copy link
Author

Let's say I want to take a 3x3x3 and solve only F2L. I want to ignore the orientation of LL corners and LL edges, but keep orientation on the F2L corner and edge pieces. Decomposing the pieces with orientation into separate stickers did workaround it for me because I can make all the stickers for pieces I don't care about identical to each other (within the same 'pieces' type).

@rokicki
Copy link
Collaborator

rokicki commented Nov 23, 2024 via email

@DougCube
Copy link
Author

I don't know what you mean by "wildcarded." What is the syntax and how and where is it used?

@rokicki
Copy link
Collaborator

rokicki commented Nov 23, 2024 via email

@DougCube
Copy link
Author

Where is this feature documented?!

@DougCube
Copy link
Author

Also, how would I apply this to a "ScrambleAlg" instead of a "Scramble?"

@lgarron
Copy link
Member

lgarron commented Nov 24, 2024

For what it's worth, my experience with using masks makes me think this is pretty useful. In particular, I think it would be useful for a default masking algorithm to convert each identical piece to the lowest index of any of them, rather than the lowest index available. This is more stable when modifying or composing masks, and it can be a useful default while also allowing choices for hand-written patterns to use larger numbers for convenience.

@rokicki
Copy link
Collaborator

rokicki commented Nov 24, 2024 via email

@DougCube
Copy link
Author

I misread your last message. I through to place '?' in the scramble file not the definition file.

@rokicki
Copy link
Collaborator

rokicki commented Nov 24, 2024 via email

@rokicki
Copy link
Collaborator

rokicki commented Nov 26, 2024 via email

@rokicki
Copy link
Collaborator

rokicki commented Nov 26, 2024

I'm willing to implement support for noncontiguous permutation "labels" or "values". Need an upvote from @lgarron before proceeding, since this introduces a divergence from Rust/cubing.js and earlier discussions.

@lgarron
Copy link
Member

lgarron commented Nov 28, 2024

Need an upvote from @lgarron before proceeding, since this introduces a divergence from Rust/cubing.js and earlier discussions.

Still in favor. As far as I can tell, this would strictly bring feature parity rather than divergence. I can't actually find any current code that enforces contiguous values in JS/Rust, and it should be easy to fix if we find any related assumptions in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants