Well... it could not really be a bitmap for this design unless you
limited it to two partitions.
That said, if I remember right, Erling Hellenäs was generating a
similar data structure (to be the left argument to wrote:
> This thread has been an interesting exploration of the many ways to
> imple
This thread has been an interesting exploration of the many ways to
implement
"all combinations of y unique items, x items at a time". I like the idea
that these
combination verbs produce a bitmap that can be used to select from a list
of
unique items to produce the final combinations.
Does it mak
I could not resist... :)
". noun define -. CRLF
CombBit=.
>@:(,.&.>/)@:((-@:(5&({::)) {. -@:(4&({::) | 1&({::)) , <.@:(1&({:
:) % 4&({::)) # 4&({::)) <@:([ {."1 #:@:])"0 1 >@:(,.&.>/)@:(3&({:
:)))@:((<@:(2&({::) 23 b.&.> ,.&.>/\.@:((2 (((_2) 32 b. 2 #: [) 23
b. (_1) 33 b. ])/\ ])@:(0 , ])&.>)@
The verb combboolT is neat. Yet, this seems to be another one of those
cases where relative terseness does not necessarily imply relative
outperformance.
On Sun, Nov 12, 2017 at 1:32 AM, Raul Miller wrote:
> I couldn't resist making a more concise tacit implementation of combbool:
>
> or=. +."1
Mike's trick on the last line might be what's needed. /Erling
On 2017-11-13 16:31, Erling Hellenäs wrote:
Hi all!
A new combbit with the limit lifted. Unfortunately somewhat slower.
x=:12
y=:24
ts'x combbit y'
0.213853 2.34326e8
ts'x combbitOld y'
0.108748 1.33655e8
combbit=: 4 :
Hi all!
A new combbit with the limit lifted. Unfortunately somewhat slower.
x=:12
y=:24
ts'x combbit y'
0.213853 2.34326e8
ts'x combbitOld y'
0.108748 1.33655e8
combbit=: 4 : 0
or=.23 b.
lshift=.33 b.
lrot=. 32 b.
shift=. 2 ((_2 lrot 2 #: [) or _1 lshift ])/\ ]
n=.<:##:_1 (32 b.) 1
I very recently tried j806.
I did not know if my machine had avs.
Tried it first.
The install just failed.
Did not tell me anything.
I then tried the other and it worked.
Something of a guesswork to get the sockets working.
On 13 Nov 2017 14:18, "Eric Iverson" wrote:
> J806 has survived its bet
J806 has survived its beta program and is now available as a final release.
J806 is solid. There are few good reasons for not moving to it promptly.
Our community is small enough that we don't need unnecessary fragmentation
of forum discussions that need to mention version. Over the next few
month
Hmm... nice.
combbit pulls out way ahead by working with a more compact and fixed
width representation, which makes sense. You give up being able to do
things like 3 combbit 100, but that might not be relevant in some
contexts.
That said, I'd probably put those -: test cases in asserts rather tha
Hi all!
Comparison
-Project-
ts=: 6!:2 , 7!:2@] NB. Time and space
require 'stats'
NB. Erling Hellenäs
combbool=: 4 : 0
k=. <"1 (-i.1+d=.y-x)|."0 1 y{.1
z=. (d$<(0,y)$0),<,:y#0
for. i.x do. z=. k (+."1)&.> ,&.>/\. (_1&|."1)&.> z end.
; z
)
combbit=: 4 : 0
assert y<:<:##:_1 (32
10 matches
Mail list logo