Fast computation of 2D summation
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hello. I have two matrix, A and B and I want to compute the following 2D summation to get a 1D array T. Is it possible to use, e.g. convolution algorithm or other ones to acquire the solution? I try to use sum and it is a bit slow when A and B are large. Thanks a lot!

0 commentaires
Réponse acceptée
James Tursa
le 5 Avr 2018
Modifié(e) : James Tursa
le 5 Avr 2018
T = reshape(B,size(B,1),[]) * A(:);
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Matrix Indexing dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!