The problem is that the function Eigenvalues[] returns 2 values but I am only interested in the value of the 1st Eigenvalue as shown above with == {1, }. In these functions that return multiple values, is there a way that I can select only the variables of interest. In the above example, I am only interested in solving for the value of p if the first Eigenvalue equals “1” and I don’t care about the value of the 2nd Eigenvalue.
I find your response extremely interesting. Correct me if I am wrong, but it appears that you are using the Eigenvalues function as a pure function identifying and isolating the first Eigenvalue as the comparison value. What would the syntax look like if I wanted to make comparisons on both Eigenvalues, if that is possible?
To answer your question about which Eigenvalue to use, I used trial and error by obtaining an answer and plugging it back into the matrix and then calculating the Eigenvalues using the updated matrix.
Sure, you can think of Eigenvalues as a pure function, but that’s beside the point in terms of an explanation. Eigenvalues returns a list, and Part (I’m using the [[]] syntax for Part) extracts elements from a list. So, when you said you wanted to use the first eigenvalue, I just used [[1]] to extract the first item from the list given by Eigenvalues.
To make the same type of comparison on both eigenvalues simultaneously, you probably want to do some sort of threading. There are several functions that do some form of threading, but the simplest and most obvious one is Thread: