No, but it seems interesting to see what you can do in J from the idea.
This paper seems to be about what I talk about:
https://www.sciencedirect.com/science/article/pii/0196677488900363
Here something similar:
https://pdfs.semanticscholar.org/58cc/367b283b4bbb6fc7cfa051a4af1f7e3867b6.pdf
/Erling
On 2017-11-11 20:20, Ivan S wrote:
11.11.2017, 23:38, "Erling Hellenäs" <[email protected]>:
Now when we are in bitmap representation, anyone can find a trick to
generate the next combination in some way similar to what I describe here?
http://www.jsoftware.com/pipermail/programming/2017-November/049551.html
With real bitmaps I mean. By manipulating the bits in integers. Not with
booleans as in my post.
This is probably not exactly what you mean, but one way to get the next k-combination
with bit operations is "Gosper's hack". It is described on this Wikipedia
page: https://en.wikipedia.org/wiki/Combinatorial_number_system#Applications
- Ivan
See also: "Bitwise reduction and scan" here:
http://code.jsoftware.com/wiki/Vocabulary/bslash
Ideally we would like to generate the next combination in one assembler
instruction, or even less, since there are wide registers that could
possibly hold many sets. You could also possibly operate on many such
registers with one assembler instruction.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm