In rep_ravel (which should be defined using =: rather than =. unless
you fix (f.) the definition of rep) you can replace
#&0@:(1&{)@:$@:]
with
0 * {.@]
You can also simplify rep_stride I imagine (and it should also be
defined using =:) but before I think about that, I'd want to
understand why you've used "0 1 in its definition - do you really
support vector left arguments?
Thanks,
--
Raul
On Wed, Apr 17, 2013 at 12:14 AM, Michal D. <[email protected]> wrote:
> Hi All,
>
> I've been exploring Spectral Graph Theory recently (
> http://www.cs.yale.edu/homes/spielman/561/) and thought I'd try my hand at
> implementing graph multiplication in J. It came out quite well. I wish
> the 'rep' definition for repeating matrices on a diagonal was shorter.
>
> Here's the code if you want to take a look:
> http://pastebin.com/J8aK74rD
>
> The course is also quite interesting I think.
>
> Cheers,
>
> Mike
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm