# Questions tagged [matrix]

Questions on the manipulation of matrices in Mathematica.

2,275 questions
Filter by
Sorted by
Tagged with
2answers
670 views

### Loop and do operations on Matrix, then graph the results

I'm trying to do some operations to a matrix in a loop, and then I want to graph the results. The results are pair of numbers. Can I store the results of each iteration on "something" and the use ...
2answers
996 views

### Total Variation Distance of probability matrix

How can I calculate the Total Variation Distance of a transition Matrix? is there any built in function? I've searched all documentation and haven;t found anything. ** More information: Let me try ...
2answers
537 views

### Transform x-scale of data for e.g. MatrixPlot

I have to transform in a nonlinear way the x-scale of some data for a MatrixPlot (or ReliefImage or ...
1answer
372 views

### Numerical comparisons of matrices

I have a matrix which should be equal to a null matrix. However due to the numerical precision, a brutal equality test with a matrix initialized with zeros does not work. How should I perform the ...
1answer
2k views

### stationary distribution of a transition matrix

How can I solve the stationary distribution of a finite Markov Chain? In other words, how can I estimate the eigenvectors of a transition matrix?
1answer
5k views

### Mathematica won't give eigenvectors but Wolfram Alpha will? What am I doing wrong?

If I ask Mathematica to find the eigenvectors and eigenvalues of the matrix: ...
1answer
3k views

### Creating a random normal matrix

I would like to create a random matrix with the constraint that the matrix must be normal, i.e. the matrix and its Hermitian conjugate must commute. I would create a random matrix "without constraints"...
4answers
371 views

2answers
302 views

### Symbolically associate vectors and their norms

I am wondering how to handle the following situation: I do have vectors of known dimension that I would like to handle symbolically. I suppose I can do something like ...
1answer
1k views

### How do I use a matrix that has a variable?

I seem to be getting an error whenever I try running this piece of code. Matrix12[n_] := {{1, 0}, {0, {\[Kappa]1[n]}/{\[Kappa]2[n]}}} I've already defined the ...
3answers
6k views

### Passing a matrix as a function argument

I am trying to do the following: ...
1answer
1k views

### vectorial ODE in mathematica with matrix exponentials

I want to solve the following equation in mathematica : DSolve[{X'[t] == A.X[t], X == ( {{0},{0}} )}, X[t], t] It is a system of 2 ODEs coupled by the matrix A, ...
3answers
582 views

### Can RowReduce work in this matrix?

The matrix $Q$ with dimensions $n\times2*n*m$ is structured by $$Q=[B|AB|\cdots|A^{2*n-1}B]$$ where $Q$ is an augmented matrix built from a $3\times3$ matrix, $A$, and a $3\times2$ matrix, $B$. I ...
1answer
905 views

1answer
108 views

### Trouble using FindInstance with MatrixRank

I'm really confused about what's going wrong with my call to FindInstance: ...
2answers
2k views

### Using the Krylov method for Solve: Speeding up a SparseArray calculation

I'm trying to implement this Total Variation Regularized Numerical Differentiation (TVDiff) code in Mathematica (which I found through this SO answer): essentially, I want to differentiate noisy data. ...
3answers
2k views

### Add lists with unequal lengths together to create a matrix

I'm trying to create a stacked bar chart using raw data coming from a MySQL server. The result coming back from one query is: ...