How to get the product multiplication of element matrix with equal size?

How to get the product multiplication of element matrix with equal size? I tray with this, but failed
X=pascal(4);
Y=magic(4);
Z(i,j)=X(i,j)*Y(i,j)

 Respuesta aceptada

Try
X=pascal(4);
Y=magic(4);
Z=X*Y
Z=X.*Y
returns
Z =
34 34 34 34
69 101 101 69
125 217 219 119
206 396 403 185
Z =
16 2 3 13
5 22 30 32
9 21 36 120
4 56 150 20

Más respuestas (0)

Categorías

Más información sobre Image Processing Toolbox en Centro de ayuda y File Exchange.

Preguntada:

el 10 de Feb. de 2014

Comentada:

el 10 de Feb. de 2014

Community Treasure Hunt

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

Start Hunting!

Translated by