Posted By:
24 Mar, 2013 12:23 pm PDT

Use of dot operator in matlab

I want to use dot operator in matlab to perform element by element multiplication of a matrix.

How can I do it? for example: I have two 2x3 matrices

A=

1 2 3
1 1 1

B=

1 -1 2
4 1 1

 

My output after multiplying 2 matrices should look like:

 ‌‌‎1 -2 6

4 1 2

Attachment:None


To multiplty element by element operation of 2 matrices A and B, use dot operator as follows:

>>A.*B

 

For division:

>>A./B

Please watch the video for details

Was it useful?  




Please login to reply to this problem.



Related Problems on Fixoncloud