help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: stack and append


From: heberf
Subject: Re: stack and append
Date: Tue, 15 Jun 1999 22:36:20 -0500 (CDT)

I figured out the stack and append thing and then noticed on the list
archive that JWE had commented that insert would be more efficient.  Boy
did he turn out to be right.

Eduardo Gallestey suggested a faster way to write the m-file.  The
oct-file using stack and append gives about the same speed improvement as
Eduardo's suggestion (a little faster than Edwardos m-file but not much).
Attached is the function using insert.  It's MUCH faster than any of the
above (the cputime is less than 1/10 that of kron.m) and really simple.

However if anyone can suggest an even better way I'll take it.  If not
I'll post this to the octave-sources list.

Heber

On Tue, 15 Jun 1999, heberf wrote:

> I need a faster implementation of the kronecker product.  The one that comes 
> with octave is in linear-algebra/kron.m and it's not suitable for me because 
> my 
> problem involves many large matrices.  I'm trying to rewrite it as an oct 
> file.
> 
> A few weeks ago there was some discussion on this list of using stack and 
> append 
> as defined in dMatrix.h.  I'm pretty poor at C++ and I can't tell from 
> reading 
> that file how to implement it.  Could someone point out a function where 
> either 
> of these are used or send a few lines of an oct file so I can see how to do 
> it?
> 
> Much thanks,
> Heber Farnsworth
> 
> 
> 
> ---------------------------------------------------------------------
> Octave is freely available under the terms of the GNU GPL.  To ensure
> that development continues, see www.che.wisc.edu/octave/giftform.html
> Instructions for unsubscribing: www.che.wisc.edu/octave/archive.html
> ---------------------------------------------------------------------
> 
> 

Attachment: newkron.cc
Description: oct file for kron


reply via email to

[Prev in Thread] Current Thread [Next in Thread]