Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

All Questions

Tagged with
Filter by
Sorted by
Tagged with
2
votes
2answers
69 views

How to overlay MatrixPlot with GridGraph?

I have a Matrixplot and a grid graph and I want to overlay them. But when I use show[g1,g2], it did come out what I wanted. I wonder how can I overlay them and make them like this? To make the points ...
9
votes
0answers
263 views

100 row numbers to find the shortest path [migrated]

I got a question that I have 100 rows of the number, as in the picture that continuous to 100 rows. There is a sequence by starting from the top, and then for each integer walk to the left or right ...
0
votes
1answer
53 views

How to plot multiple functions in a graph with different colors?

I have a general {i,x,y} dimensional matrix, and I want to plot all "i" {x,y} matrices in one graph. How can I do it in a way that I can still distinguish each "i"th curve from the other (I mean ...
3
votes
1answer
47 views

How can I make a scatter plot from a matrix with many y-axis values for each x-axis value?

Consider matrix A = {{0, 2.54343, 3.566, 4.2323, 2.3434}, {0.1, 6.432, 4.6465, 5.656, 1.34}, {0.2, 0.3423, 1.6342, 3.323, 2.04}}; The x-axis values ...
1
vote
1answer
38 views

Defining a function that outputs a matrix, and later finding its eigenvalues

I am trying to do the following: I have a simple 2x2 matrix that depends on three parameters (physically -- momentum coordinates kx, ky, kz). Then I want to replace each of these parameters by a ...
0
votes
0answers
33 views

Dynamical PlotLegends with two indices

I need to plot several eigenvalues from different matrices, so I would like to know how can I change the name of the curve with each set of matrices-eigenvalue. What I am doing is the following: <...
4
votes
1answer
78 views

Graphic representation of a triangle using ArrayPlot

So I need to write a function which takes natural integer $n$ and returns graphical representation of a matrix $n \times n$ using ArrayPlot[]. This matrix has to be ...
4
votes
1answer
362 views

Solving the eigenvalue problem for a double well potential using a 1D particle in a box as a basis set

My first question is how would I go about getting the 1D particle in a box eigenfunctions using matrix techniques and how would I use the particle in a box eigenfunctions as a basis set for the ...
1
vote
0answers
66 views

Find parameter which solves a 9-by-9 homogeneous system of linear equations, NSolve gives some incorrect answers

I have a set of 9 linear homogeneous simultaneous equations which depend on 2 parameters, p and x. For a chosen value of p, I aim to calculate the smallest 3 values of x which satisfy the simultaneous ...
1
vote
1answer
108 views

Plot nested matrix and label according to sublist

I have a nested matrix xyPairsAll that contains {x, y} pairs: ...
2
votes
1answer
199 views

Plotting eigenvalues in one plot for three different parameters

I am trying to plot eigenvalues of the matrix with different $W$. I can plot them separately but I want to merge them in a single plot with different colors. Is there any other type of plot other than ...
3
votes
1answer
128 views

Convert a colormap image into data values according to a legend

I have this image that I want to turn into data using this gradient black being 0, white being 1, and all the colors in between accordingly, so I could later use ...
1
vote
1answer
91 views

Extending MatrixPlot to complex-valued matrices

I'm looking to plot a complex-valued matrix in a way similar to MatrixPlot. I know how to map an individual complex number on to a colored swatch: if ...
2
votes
2answers
112 views

BarLegend Label and ColorScheme

Probably the answer to this question is already elsewhere, but I have looked for it in the last couple of days and I have't found it. So, I have the following code: ...
0
votes
0answers
39 views

3D Sparse array [duplicate]

Following the 3D matrix representation shown here Vitaliy Kaurov's answer for "Plot 3D boolean Array or matrix in Mathematica" Is it possible to use a SparseArray ...
0
votes
0answers
45 views

How to create a particular 3D variant of MatrixPlot?

Does anybody know an elegant way to implement a matrix plot of the following form in Mathematica? Where $Y_{ij}$ is just an matrix of complex numbers (the index $a$ just counts different matrices, ...
3
votes
4answers
385 views

Matrix plot using RGB color coding

I am looking to plot a line of 250 discrete sites with a specified RGB color value based on the import file values. The import file has the following format: I want the first element in each row to ...
1
vote
0answers
247 views

VectorPlot for Phase Plane for 2x2 Matrix

Can anyone help me with my VectorPlot of a phase plane? I've been able to set up a few VectorPlots for different differential equation systems, but this one I have trouble with. It has only one real ...
1
vote
1answer
116 views

Generate an array of ParametricPlots

I am editing an old .nb that generate the polarization map of a vector vortex beam from the Stokes parameters ( S1,S2,S3) stored in 3 different matrices (S1medie,S2medie,S3medie). the code initialize ...
2
votes
1answer
58 views

How to label group of ticks?

I am plotting a matrix in 3D and what I did so far is this: So, what I would like to do now is to add different labels to group of ticks, in this way: Even only on the bottom axis is perfect. The ...
2
votes
2answers
372 views

Engineering a colour scale for MatrixPlot

I am trying to find the best way to plot my data. I have a 2D list of scalar coefficients (rational numbers) whose value lies between 0 and 1 (being rational, they can be 0,..., 0.01,... 0.999,..., 1)....
6
votes
0answers
228 views

Why MatrixPlot give so many colors but only two types of number in data? [duplicate]

For example MatrixPlot[RandomInteger[1, {10, 300}], Frame -> False] MatrixPlot[RandomInteger[1, {10, 300}], Frame -> False, ColorFunction -> Hue] You ...
2
votes
1answer
235 views

Graphing a Custom Function

I'm trying to make a graph of a function involving several steps, steps that I can't put straight into the Plot[ ] function. Here is the outline of the process: Two real numbers, A and B, are defined,...
1
vote
1answer
59 views

Plot several MatrixPlots as “timeline” using Manipulate [closed]

I am currently struggling with a relatively simple problem, however, unfortunately, I am not as familiar as others with the Mathematica syntax. I would like to use ...
-3
votes
1answer
590 views

How can I plot eigenvalues?

...
12
votes
4answers
3k views

How to plot a matrix with 3D style

I have a list like SeedRandom[1] MatrixForm[list = RandomInteger[5, {5, 5}]] We can plot it with MatrixPlot directly with 2D ...
4
votes
3answers
548 views

How to plot the field of values (numerical range) of a matrix

I found some difficulties in plotting the set $$W(\mathbb{A}):=\{\langle x,\mathbb{A}x \rangle \mid \|x\|=1\},$$ where $\mathbb{A}\in\mathbb{C}^{n,n}$ is a given complex matrix and $\langle\cdot,\cdot\...
1
vote
3answers
361 views

ListDensity plot does not plot the actual data set

I have a dataset here here. It consists of three columns. It x values or the column 1 is not the same for all the data sets for corresponding z values (or in other words, x values are not equally ...
0
votes
0answers
512 views

Adding a colorbar legend to a matrix plot [duplicate]

Looking for the option to add a colorbar legend to the right of a matrix plot: ...
6
votes
1answer
540 views

How to plot the $\varepsilon$-pseudospectrum of a matrix

Let $A\in\mathbb{C}^{n\times n}$ and $\varepsilon>0$. The $\varepsilon$-pseudospectrum of $A$ is the set $$\sigma_{\varepsilon}(A)=\left\{z\in\mathbb{C} \middle| \|(A-zI)^{-1}\|\geq\frac{1}{\...
0
votes
1answer
204 views

Correct format and options of MatrixPlot

Why is that my plot is returning an error? My sect[[]] returns a correct format for the range parameter of the plot. But still only getting one color in the full ...
0
votes
2answers
220 views

Plot columns of matrix vs same variable

I have a table of dimensions {10,3} say. Each column is the value of some function f(x,a) wrt to x and the parameter $a~ ( =1,2,3$ say) refers to the columns. So for example if we let $f(x,a) = a \...
1
vote
1answer
402 views

ArrayPlot with logarithmic legend

I have a matrix that contains numbers in different orders of magnitude and I would like to plot it using ArrayPlot. For example purposes I create the matrix here, ...
3
votes
1answer
178 views

Discontinuities in eigenvalues plotting with Plot3D

I have a 6x6 matrix, depending on 2 variables kx and ky and defined as the sum of the two following matrices (...
2
votes
1answer
357 views

Plot certain parts of column of a matrix

I have a text file data1 (not comma separated) that consists of a huge number of numbers, it's basically a matrix of numbers. I would like to have a smooth code to ...
0
votes
0answers
82 views

locating points on ContourPlot

I tried using ContourPlot to plot a curve of $\omega$ vs $k$. $\omega$ and $k$ are related implicitly by the determinant of a 4x4 matrix ...
0
votes
1answer
63 views

How can I compute the difference in Y-axis values between data sets with similar X-values

I am new to Mathematica, so this might be a very basic question; however, I cannot find a solution to this and it is taking me very long. For my research I am probing the photoluminescence response ...
1
vote
1answer
88 views

How do I plot the columns of an $M \times N$ matrix as separate lines on the same graph using ListLinePlot?

I have seen many examples that show how to plot several functions on the same graph using ListLinePlot is this manner: e.g. ...
1
vote
2answers
1k views

How to plot columns of a matrix as vectors

Related: How to plot vectors in Mathematica I am not interested in vector fields and field plots. I'd like to pass a $(2 \times n)$ or $(3 \times n)$ matrix into a function (or 2 different functions) ...
0
votes
1answer
119 views

Plotting Matrix versus Matrix [closed]

So I recently started using Mathematica and I haven't been able to figure out how to simply plot elements of one matrix versus another matrix which are not directly related or are not a function of ...
0
votes
1answer
73 views

Probems using 2 For and a AppendTo to cycle through my Equation to solve some matrixes

I am trying to solve a few problems here. I have an equation with multiple variables that I am trying to solve in For loop method. I will attach the file below. In addition I am trying to get it to ...
3
votes
1answer
322 views

Optimize a parametric matrix to get a lowest possible eigenvalue

This question is a followup of Plot the lowest eigenvalues of a parametric matrix Now I can get the lowest eigenvalue LowEign(t) of the matrix for a given t numerically. When I plot the LowEign ...
2
votes
1answer
288 views

Plot the lowest eigenvalues of a parametric matrix

The question here is somewhat related to the comments in Computing eigenvectors and eigenvalues I have a matrix M, say 400 by 400, and all elements depend explicitly on one parameter t in a ...
3
votes
1answer
301 views

Drawing dynamical trajectories diagram in Mathematica

I've a Boolean gene regulation system composed of vectors(corresponding to cellular phenotypes). Their components are binary numbers such as $\{1,0,0,1\}$. A vector can change its statement in ...
2
votes
1answer
156 views

Help on order of evaluation within plot function

it is my first time asking a question here so please let me know if there's anything I should be doing that I'm unaware of. I'm sure the answer to my question already exists on the site but I'm having ...
3
votes
0answers
80 views

Optimization for iterating and plotting a matrix product and its elements?

I have an iterative matrix product of this type $$ \begin{pmatrix}y_{n+1} \\ x_{n+1} \end{pmatrix} = \begin{pmatrix} A & B \\ C & D \end{pmatrix} \begin{pmatrix}y_{n} \\ x_{n} \end{pmatrix} $...
5
votes
1answer
539 views

Plotting eigenvalues smoothly

I am trying to plot how the eigenvalues of a matrix change by changing a given a parameter t. Of course the ordering of the eigenvalues does not matter mathematically but it does when I want to make ...
0
votes
2answers
147 views

Plotting plane from a matrix or data table

After weeks collecting data I've decided to pass my results through Wolfram Alpha and see what it gets. The results are amazingly useful, specially the plane generated by linear regression. It is ...
0
votes
1answer
82 views

Plotting results of 'Do' loop in contour graph

I want to plot the results of a 'do' loop as a contour graph: ...