From plummer@iarc.fr  Thu Jul 22 08:56:44 1999
From: plummer@iarc.fr (Martyn Plummer)
Date: Thu, 22 Jul 1999 09:56:44 +0200 (CEST)
Subject: tensor() function and sets
In-Reply-To: <Pine.GSO.3.96.990720143125.9359C-100000@laplace>
Message-ID: <XFMail.990722095644.plummer@iarc.fr>

On 20-Jul-99 Jonathan Rougier wrote:
> Hi Everyone,
> 
> To complete the outer() and kronecker() functions in the base, may I
> suggest the following tensor() function, which allows the multiplication
> of arrays through sets of conformable dimensions.  I am happy to write a
> help page if required. 

I have some code that could certainly be tidied up with the tensor()
function [1], but I wonder if "tensor" is the right name.
1) I would expect a function called "tensor" to construct a tensor object
   rather than multiply two arrays together.
2) The arguments aren't tensors. They are arrays.

How fast is it? It would be _really_ nice if this were done efficiently
in C code.

Martyn

[1] ar.yw in the "bats" package. I was just looking at this wondering how
    to speed it up before rewriting the whole thing in C or Fortran.
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


tensor() function and sets
Martyn Plummer