# Display problem multiplying matrix [duplicate]

I'm multiplying matrices and I don't get answer I want I just get matrix M times matrix N, there is no result. What to do and what to fix in order to get result displayed?

M = {{1, 3, 3}, {3, 4, 4}, {5, 5, 5}} // MatrixForm


P = {{1, 2, 6}, {3, 6, 4}, {5, 9, 5}} // MatrixForm


M.P


• You need to include more detail of what you are doing. Possibly using Dot (short form .) will solve your problem if you have actual matrix data. The data might potentially need to be transposed. Also you can/should not use N as a variable as it is already a defined System function. – Mr.Wizard Oct 23 '14 at 20:11
• Printscreen: postimg.org/image/qgo5cqz3t – VlS Oct 23 '14 at 20:15
• @VladimirS, This is not a good way to share your code, see the edits I did for you. – rhermans Oct 23 '14 at 20:23
• Oh, sorry. Thanks, I'll learn how to do that for my next question. – VlS Oct 23 '14 at 20:24
• The problem is MatrixForm. See, detail is important. :-) I am closing this question as a duplicate. (A link will be inserted at the top of your post.) See the answers there fore a full explanation. – Mr.Wizard Oct 23 '14 at 20:28

M = {{1, 3, 3}, {3, 4, 4}, {5, 5, 5}}

{{1, 3, 3}, {3, 4, 4}, {5, 5, 5}}

P = {{1, 2, 6}, {3, 6, 4}, {5, 9, 5}}

{{1, 2, 6}, {3, 6, 4}, {5, 9, 5}}

M.P

{{25, 47, 33}, {35, 66, 54}, {45, 85, 75}}


Or, if you want the nice display be sure not to include that in the definition of your matrix

MatrixForm[M = {{1, 3, 3}, {3, 4, 4}, {5, 5, 5}}]