# Plotting a list of Eigenvectors

For my Fractional Calculus course, I was asked to find a matrix that arbitrarily represents the second derivative. This eventually got me a tridiagonal matrix. I was letter asked to find the eigenvectors of a $n\times n$ tridiagonal matrix. In this case I did a $30 \times 30$ tridiagonal matrix. Afterwards we were asked to plot each eigenvectors to notice the behavior of the sinusoidal function as $n \rightarrow \infty$.

Mathematically the oscillation is suppose to increase as $n$ increases. We see the graph below confirms this, but it is hard to tell with all the points all over the place.

Anywho, once I got my list of eigenvectors, I plot the list of eigenvectors and I get the following image I was referring to earlier: Without having to do them one at a time, is there a way to plot each of these eigenvectors on their own graph? Is there a way to change the scaling from $1$ to $\frac{1}{30}$ (or in general \frac{1}{n})? I just wanted to change the spacing between the points since our professor wanted us to graph our vectors on the interval [0,1].

Below is a small sample of my code

n = 30;
A = Total[{DiagonalMatrix[Array[-1 &, n - 1], -1],
DiagonalMatrix[Array[2 &, n]],
DiagonalMatrix[Array[-1 &, n - 1], 1]}] // MatrixForm

...

Eigenvectors[A] //N

...
ListPlot[%15]


I know I skipped some details related to the assignment itself but I don't think they are needed for what I am asking for; however, if you are curious of what the assignment is, or think it will be helpful clarify a few things, let me know.

Thank You for your time. I appreciate any feedback or suggestions you may have. Have a wonderful day.

• A little bit of code would be nice, actually. But probably you could do ListPlot[#] & /@ Eigenvectors[mat]. Sep 22 '15 at 22:24
• Try ListPlot[ yourList , Joined->True] to see a solid curve for the oscillations. Changing the scaling on the x-axis visually will not really do anything. It will change the maximal x-axis number you see from 30 to 1, but the spacing ratio between points will still stay the same. Sep 22 '15 at 22:28

It sounds like you want one of these:

ListLinePlot[#, ImageSize -> 4*72, PlotRange -> {-5,5}]& /@ Eigenvectors[mat]


or

With[
{eigs = Eigenvectors[mat]},
Manipulate[
ListLinePlot[mat[[k]], ImageSize -> 4*72, PlotRange -> {-5,5}],
{{k, 1}, 1, Length[eigs], 1}]]


which will let you look at them one at a time.

In the case of the first code block, you can organize the plots using a GraphicsGrid, GraphicsRow, or GraphicsColumn:

With[
{plots = Map[
ListLinePlot[#, ImageSize -> 4*72, PlotRange -> {-5,5}]&,
Eigenvectors[mat]]},
GraphicsColumn[plots, ImageSize -> 4*72]]


Finally, if you want to just see them all at once on one graph, you can just do this:

ListLinePlot[Eigenvectors[mat]]

• Re: the scaling, I'm not sure what you mean, but you might look at the AspectRatio option?
– nben
Sep 23 '15 at 20:55