Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have question about a matrix calculation like $\mathbf{b}^{t}\,\Sigma\,\mathbf{b}$, where $\Sigma$ is a 7 by 7 matrix, and $\mathbf{b}$ is vector of 7 elements, and each element in the vector $\mathbf{b}$ or $\Sigma$ is a symbolic formula,

For example, the (i, j)-th element of $\Sigma$ could have the form $\Sigma_{i,j}=ab+c+u+m$.

How can I do this calculation in Mathematica?

share|improve this question

closed as off-topic by MarcoB, Yves Klett, Sjoerd C. de Vries, Mr.Wizard Jun 25 '15 at 6:31

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – MarcoB, Sjoerd C. de Vries, Mr.Wizard
If this question can be reworded to fit the rules in the help center, please edit the question.

up vote 3 down vote accepted

You may need to use the "list" data structure in mathematica. Say, $\Sigma$ is a two by two matrix. In Mathematica, you just input

Sigma = {{x+y, m+n}, {x+y-w, m-n.l}}



Then, $b\Sigma b^T$ is just


Hope it works for you.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.