multiplay colum of matrix

1 visualizzazione (ultimi 30 giorni)
Lior Genfon
Lior Genfon il 28 Mar 2020
Modificato: Adam Danz il 31 Mar 2020
say i have matrix
a=[1,2,3;4,5,6;7,8,9]
i whant to get a vector that will be the multipal of every colum
the answer here [35;80;162]
how can i do this
  1 Commento
Adam Danz
Adam Danz il 28 Mar 2020
The correct product would be [28 80 162] if you're multiplying by column.

Accedi per commentare.

Risposte (1)

Adam Danz
Adam Danz il 28 Mar 2020
Modificato: Adam Danz il 31 Mar 2020
y = prod(a);

Categorie

Scopri di più su Shifting and Sorting Matrices in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by