How to write an explicit one-line code for matrix multiplication A*B, each of size n by n, for example using the summation definition of matrix multiplication (here, eq 14)?
I know how to do it for matrix-vector multiplication: if A is n by n and x is n by 1, then
Just in case someone stumbles onto this answer: the performance can be improved a lot by avoiding copies in the slices and dot product. But of course the best implementation in most cases will be built-in multiplication
What you originally posted sounded very much like a request for solving a homework problem. It would have sounded less like that if you had provided some context/motivation for the request or shown what you had already tried.