tensor product

Charles R Harris charlesr.harris at gmail.com
Sun Oct 8 21:19:02 CDT 2006

Hi Nadav,

On 10/8/06, Nadav Horesh <nadavh at visionsense.com> wrote:
> There is a "tensortdot" function in numpy1.0rc1

The tensordot is not the same thing as a tensor product. What I want is the

def tensor(a, b) :
    """Tensor product of a and b

    a = asarray(a)
    b = asarray(b)
    return outer(a, b).reshape(a.shape + b.shape)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://projects.scipy.org/pipermail/numpy-discussion/attachments/20061008/80ebb029/attachment.html 
-------------- next part --------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
-------------- next part --------------
Numpy-discussion mailing list
Numpy-discussion at lists.sourceforge.net

More information about the Numpy-discussion mailing list