[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
NDarray, inner/outer tensor products
From: |
daniel heiserer |
Subject: |
NDarray, inner/outer tensor products |
Date: |
Mon, 24 May 2004 08:46:08 -0500 |
Hi,
is there a way to create the inner and outer product of a NDarray?
eg:
b=rand(3,4,5);
c=rand(3,2);
d=tensor_product(b,c,[1 1]);
==> size(d)= 4 5 2
or with multiple "condensations":
b=rand(3,4,5);
c=rand(3,4);
d=tensor_product(b,c,[1 1;2 2]);
==> size(d)= 1
the outer product would be without/empty third argument:
b=rand(3,4,5);
c=rand(3,4);
d=tensor_product(b,c);
==> size(d)= 3 4 5 3 4
--
Mit freundlichen Gruessen
Daniel Heiserer
--------------------------------------------------------------
Dipl.-Phys. Daniel Heiserer, BMW AG, Knorrstrasse 147, 80788 Muenchen
Abteilung EK-212
Tel.: 089-382-21187, Fax.: 089-382-42820
mailto:address@hidden
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- NDarray, inner/outer tensor products,
daniel heiserer <=