Search found 113 matches

by StefanoLanzavecchia
Tue Jul 30, 2024 4:07 pm
Forum: Language
Topic: Combining Take and Drop on a matrix for efficiency?
Replies: 15
Views: 35829

Re: Combining Take and Drop on a matrix for efficiency?

The ravel and the reshape are one copy each. Plus one copy from C memory space to the workspace memory space for the returned array. Which is 3 copies, instead of just the two required by a take and a drop. I don't think this is going to fly. In particular the first copy (the ravel) acts on all the ...
by StefanoLanzavecchia
Tue Jul 30, 2024 7:09 am
Forum: Language
Topic: )SI When Threading
Replies: 1
Views: 6631

Re: )SI When Threading

In my mental model, those are the Dyalog threads that were associated with a system OS or .NET thread. Not all of them need to be. In fact, the fewer are the better since Dyalog threads are supposed to be lighter than system threads.
by StefanoLanzavecchia
Tue Jul 30, 2024 7:05 am
Forum: Language
Topic: Combining Take and Drop on a matrix for efficiency?
Replies: 15
Views: 35829

Re: Combining Take and Drop on a matrix for efficiency?

The read-only pointer has a few shortcomings: 1) you don't know the type of the array, which means you don't know the size in bytes (or bits...) of each element; 2) you don't know its rank and shape, which you'd have to pass as extra arguments; 3) you don't have a way to build a result of the proper ...
by StefanoLanzavecchia
Tue Apr 30, 2024 9:29 am
Forum: APL Chat
Topic: Help with complex numbers wanted
Replies: 7
Views: 26308

Re: Help with complex numbers wanted

My sense of pitch is quite bad, so what I am going to write is hardly from direct experience. I read more than once that choirs drift towards perfect intervals (a.k.a. just intonation) almost instinctively. Therefore, especially in emotional moments like important cadences, they sing perfect thirds ...
by StefanoLanzavecchia
Tue Dec 19, 2023 11:20 pm
Forum: Windows: GUI, COM/OLE/ActiveX
Topic: Motion-JPEG from APL
Replies: 7
Views: 57148

Re: Motion-JPEG from APL

Nicely done!
by StefanoLanzavecchia
Mon Dec 11, 2023 9:42 am
Forum: Windows: GUI, COM/OLE/ActiveX
Topic: Motion-JPEG from APL
Replies: 7
Views: 57148

Re: Motion-JPEG from APL

Ray, I wish I could spend more time on this because it sounds like a fun weekend project. But at the moment life is throwing wrenches and I'll have to shelve it for a while. In the meantime, if you want to get something done, I suggest you take a look at ffmpeg (ffmpeg.org). It's an all-in-one ...
by StefanoLanzavecchia
Fri Dec 01, 2023 8:18 am
Forum: Functional Programming
Topic: Mathematica and Dyalog
Replies: 4
Views: 68868

Re: Mathematica and Dyalog

Please notice that Mathematica's RandomInteger[max,n] returns n number in the range 0..max, possibly with repetitions, whereas dyadic deal ( x?y ) returns a partial permutation of the array ⍳y . https://aplwiki.com/wiki/Deal . To replicate the behaviour of Mathematica's RandomInteger just apply roll ...
by StefanoLanzavecchia
Wed Apr 26, 2023 4:33 pm
Forum: UNIX and Linux
Topic: Support for Microsoft .Net 6.0
Replies: 3
Views: 88303

Re: Support for Microsoft .Net 6.0

I haven't tried much (just []NEW System.DateTime and System.Environment.Version) but it seems to work with .NET 7.0 as well. Nice :)
by StefanoLanzavecchia
Mon Apr 24, 2023 3:41 pm
Forum: Language
Topic: sound with Dyalog APL
Replies: 5
Views: 29335

Re: sound with Dyalog APL

To remove the clicks, which are due to discontinuities in the sample waveform, I recommend fading all the notes: fade in (less important because you always start from 0), and fade out (so that the last sample of each note is a 0). You can simply apply a linear ramp which goes from 1 to 0 in the last ...
by StefanoLanzavecchia
Fri Mar 31, 2023 6:36 am
Forum: Language
Topic: sound with Dyalog APL
Replies: 5
Views: 29335

Re: sound with Dyalog APL

A starting point could be to check this message on this same forum: https://forums.dyalog.com/viewtopic.php?f=12&t=1044&start=10 The code, especially the one in the github repo mentioned further down the thread, looks ready to be used, though I have not tried it. I have had success with similar ...