update to the de-superpermutation (demutator) program#48
Open
kro-cat wants to merge 7 commits intosuperpermutators:masterfrom
Open
update to the de-superpermutation (demutator) program#48kro-cat wants to merge 7 commits intosuperpermutators:masterfrom
kro-cat wants to merge 7 commits intosuperpermutators:masterfrom
Conversation
depermutate is a tool for finding all the permutations in a list. It's output has been made machine-readable, as compared to demutator. The output may be re-formatted by additional programs to become a better visual aid. Logic changes: This program has been rewritten to work on streams of characters, so that it may use less memory parsing larger lists. The program attempts to identify the set of all elements contained in the list it's processing before finding the permutations. This is to eliminate the need for a separate radix, character set, or other information besides the list itself. This assumes that all elements of that set are already present in the list.
Contributor
Author
|
Also, food for thought with the new superpermutations, if that's helpful at all. |
The provided awkscript uses the --numbered option of the program and calculates the (node) weights between successive permutations. Added the -0 and --null command-line options. This switches from newline-separated superpermutations to null-separated superpermutations. This mode is helpful when working with newline-buffered streams like stdout and stdin.
Fixed the example to be accurate
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I'd like to remove the original demutator from this repository and replace it with the current version I've been using recently. It's technically a fork/mirror of the actual repository I'm using, but I'd argue it's appropriate in this circumstance.
Main motivation: after 5 years, I honestly can't figure out how to make the original code work anymore.
I recently resumed interest in superpermutations, and I've been working on some personal code for now. I think, at least, this tool is due for an update, so I'd like to share the latest version of it. It's helped me pick out some patterns in superpermutations, which can be really insightful.
Sorry for all the C code. At least I've learned autotools, so that helps.
DE-SuperPERmutATE (called "desperate", because I thought that was silly) is a tool for finding all the permutations in a list. It's output has been made machine-readable, as compared to demutator. The output may be re-formatted by additional programs to become a better visual aid.
Logic changes:
This program has been rewritten to work on streams of characters, so that it may use less memory parsing larger lists.
The program requires a character-set (a set of elements, which are 8-bit characters each) as one of its arguments. This is to eliminate the need to determine an otherwise unknown character-set, which starts to get really cumbersome once you get to permutations of more than like, 13 elements. desperate takes advantage of pipes, so hopefully the data doesn't need to take up a lot of space in order to analyze it.