Timeline for Efficient implementation of tensorial Rayleigh product
Current License: CC BY-SA 3.0
8 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Mar 29, 2020 at 15:12 | comment | added | yarchik | @HenrikSchumacher Yes, it's a very nice concise way of writing, and functional too. | |
Mar 29, 2020 at 10:16 | comment | added | Henrik Schumacher |
Also possible: Nest[A.Transpose[#, RotateLeft[Range[4]]] &, B, 4] .
|
|
Jan 19, 2020 at 18:19 | comment | added | yarchik |
@AccidentalFourierTransform The idea is to use matrix multiplication, which is a very efficient operation, for the computation of each sum. To this end, we need to change the order of indices of matrix B in such a way as to have the active one as the last one. Now concerning the generalization: d is the dimension of the inner sum in each matrix multiplication. Therefore, it is already taken care of. n is the number of sums= number of dimensions of B . To make it more general, we can write Do[c = Transpose[c.a, RotateLeft[Range[n]]], {i, n}];
|
|
Jan 16, 2020 at 16:53 | comment | added | AccidentalFourierTransform |
@yarchik can you please explain {2, 3, 4, 1} in the Transpose ? In particular, how to generalise this part of the function to arbitrary n and d (in the notation of the OP). Thanks!
|
|
Jul 5, 2016 at 16:53 | comment | added | Mauricio Fernández | Thank you very much, I just did not see the transposition! That was the crucial point. Thanks! | |
Jul 5, 2016 at 16:52 | vote | accept | Mauricio Fernández | ||
Jul 5, 2016 at 16:42 | history | edited | yarchik | CC BY-SA 3.0 |
added 443 characters in body
|
Jul 5, 2016 at 16:36 | history | answered | yarchik | CC BY-SA 3.0 |