**Edit**
I realized that the key piece of information that I need is question 1, and so I'd like to rephrase this post:



> 
> What are the possible eigenvalues of nonnegative integer matrices?
> 
> 
> 


Any answer to this question would be appreciated and checkmarked.




---


**Original Question:**


My question is related to [this question](https://mathoverflow.net/questions/99845/properties-of-eigenvalues-of-general-nonnegative-matrices) about integer nonnegative matrices but goes in a slightly different direction. Like the previous poster, my question comes from solving linear recursions (specifically, computing the discrete modulus of a product finite subdivision rule acting on a grid).


Given $A$ a square matrix with nonnegative integer entries and $v$ a column vector of the same dimension, we can use the Jordan canonical form to get a closed expression for $A^n(v)$. If we sum the entries of $A^n(v)$, we get a function of the form $f(n)=a\_1 P\_1(n)\lambda\_1^n+...+a\_kP\_k\lambda\_k$, where the $\lambda$'s are the distinct eigenvalues and each $P\_i$ is a *monic* polynomial in $n$. 


My question is, what are the possible values for the $a\_i$ and the $\lambda\_i$? In particular:


1. Can the $\lambda\_i$ be any algebraic integer?
2. Can the $a\_i$ be non-integers?
3. (My real question): Given an algebraic integer $\lambda$, can we construct two matrices $A\_1$ and $A\_2$ such that the ratio of their associated polynomials $\frac{f\_1(n)}{f\_2(n)}$ (where, as above, $f\_i(n)$ is the sum of the entries of $A\_1^n v$) has limit $\lambda$? The limit of such a fraction will be 0 unless the 'largest terms' of each polynomial have the same magnitude; my worry is that it would be impossible to get some algebraic integers in this way because they have Galois conjugates of equal or larger size. But it seems that the column vector $v$ might allow one to 'cancel out' unwanted eigenvalues. Is this possible? Is it even possible to get $\sqrt{3}$ in this way?


Thank you for your help! The first two questions seem like they would be easily answerable by experts in matrix theory, but google searches have led to nothing. I appreciate in advance your help.


An example of $f\_1(n)$
-----------------------


Let $A=\left[ \begin{array}{cc} 1 & 2 \\ 0 & 2
\end{array} \right]$. It can be diagonalized as $A=\left[ \begin{array}{cc}
1 & 2
\\ 0 & 1 \end{array} \right]
\left[ \begin{array}{cc} 1 & 0
\\ 0 & 2 \end{array} \right]
\left[ \begin{array}{cc} 1 & -2
\\ 0 & 1 \end{array} \right]$. Now, let $v = \left[ \begin{array}{c} 2
\\ 3 \end{array} \right] $.


Then $A^{n} v=
\left[
\begin{array}{cc} 1 & 2
\\ 0 & 1 \end{array} \right]
\left[ \begin{array}{cc} 1 & 0
\\ 0 & 2^{n} \end{array} \right]
\left[ \begin{array}{cc} 1 & -2
\\ 0 & 1 \end{array} \right]
\left[ \begin{array}{c} 2
\\ 3 \end{array} \right] =
\left[
\begin{array}{cc} 1 & 2^{n+1} -2
\\ 0 & 2^{n} \end{array} \right]
\left[ \begin{array}{c} 2
\\ 3 \end{array} \right] =
\left[ \begin{array}{c} 3(2^{n+1})-4
\\ 3(2^{n}) \end{array} \right]$. Adding all the entries of this matrix together, we see that
the growth function $f(n)$ is $3(2^{n+1} +
2^{n})-4=9(2^{n})-4$.



Eigenvalues of nonnegative integer matrices
I claim that any algebraic integer $\lambda$ is the eigenvalue of a nonnegative matrix with integer coefficients. This answer relies on Doug Lind's answer [here](https://mathoverflow.net/questions/3939/when-is-a-monic-integer-polynomial-the-characteristic-polynomial-of-a-non-negativ/60503#60503). Let $\lambda\_1$, $\lambda\_2$, ..., $\lambda\_r$ be the Galois conjugates of $\lambda$. Let $\ell = \max(|\lambda\_i|)$. Choose an integer $L$ large enough that $L^n \cdot (L-2)/(L-1) > \ell^n \cdot \ell/(\ell-1)$ for all positive integers $n$. I claim there will be a nonnegative integer matrix with eigenvalues $(\lambda\_1, \lambda\_2, \ldots, \lambda\_r, L,L,\ldots, L)$ where there are $r$ copies of $L$.


Let $\mu\_1$, $\mu\_2$, ..., $\mu\_{2r}$ be $(\lambda\_1, \lambda\_2, \ldots, \lambda\_r, L,L,\ldots, L)$. According to Lind's answer, all we have to check is that, for all $n>0$,
$$\frac{1}{n} \sum\_k \sum\_{d|n} \mu(n/d) \mu\_k^d$$
is a nonnegative integer.


**It's an integer:** Let $g(x) = \prod\_{i=1}^{2r} (x-\mu\_i)$. Since $\lambda$ is an algebraic integer, $g$ is a monic polynomial with integer coefficients. So there is a $(2r) \times (2r)$ integer matrix $B$ with characteristic polynomial $g$ -- the companion matrix. 
As explained on the second paper Lind links, if $g$ is the characteristic polynomial of an integer matrix, then there is a graph theoretic interpretation of the above quantity which is manifestly integral. (I gave a slightly incorrect description of this interpretation before; I'll stick to just citing for now.)


**It's nonnegative**


We have 
$$\sum\_{d|n} \mu(n/d) L^d \geq L^n - \sum\_{-\infty < d<n} L^d = L^n - \frac{L^{n-1}}{1-1/L}=L^n \frac{L-2}{L-1}.$$
and
$$\left| \sum\_{d|n} \mu(n/d) \lambda^d \right| \leq \sum\_{- \infty < d \leq n} |\lambda|^d = \frac{|\lambda|^n}{1-1/|\lambda|} = |\lambda|^n \frac{|\lambda|}{|\lambda|-1}$$


So, for every $i$, $\sum\_{d|n} \mu(n/d) L^d$ is a positive integer which is greater than the norm of $\sum\_{d|n} \mu(n/d) \lambda\_i^d$.


So the real part of 
$$\sum\_{i=1}^r \left( \sum\_{d|n} \mu(n/d) L^d + \sum\_{d|n} \mu(n/d) \lambda\_i^d \right)$$
is nonnegative. By Galois symmetry, the sum is real, so it is a nonnegative real, as desired.


**Disclaimer:** I haven't read the paper Lind cites.




---


In response to Turbo's question: Any eigenvalue of an nonnegative integer matrix is an eigenvalue of a $(0,1)$ matrix. Choose $N$ larger than any matrix entry and replace each matrix entry $a\_{ij}$ with an $N \times N$ block of the form
$$\begin{pmatrix} 
1 & 1 & \cdots & 1 & 0 & 0 \cdots & 0 \\
1 & 1 & \cdots & 1 & 0 & 0 \cdots & 0 \\
1 & 1 & \cdots & 1 & 0 & 0 \cdots & 0 \\
\vdots & \vdots & \vdots & \vdots & \vdots & \ddots & \vdots & \\
1 & 1 & \cdots & 1 & 0 & 0 \cdots & 0 \\
\end{pmatrix}$$
where there are $a\_{ij}$ columns of $1$'s.
If $(v\_1, v\_2, \dots, v\_n)^T$ is an eigenvector of the old matrix, then $(v\_1, v\_1, \dots, v\_1, v\_2, v\_2, \dots, v\_2, \dots, v\_n, v\_n, \dots, v\_n)^T$ is an eigenvector of the new matrix with the same eigenvalue.


