Consider the three-term recurrence relation on $y^{n}=y^{n}(\theta) \in \mathbb{C}$ depending on the parameter $\theta$: $$ y^{n+1}(\theta) = \alpha_{2}(\theta) y^{n}(\theta) + \alpha_{1}(\theta) y^{n-1}(\theta) + \alpha_{0}(\theta) y^{n-2}(\theta), $$ where $\alpha_{2}$, $\alpha_{1}$, $\alpha_{0} \in \mathbb{C}$ are smooth functions of $\theta \in \mathbb{R}$. The characteristic equation of the problem is: $$ z^{3} - \alpha_{2}(\theta)z^2 - \alpha_{1}(\theta) z - \alpha_{0}(\theta) = (z-z_1(\theta))(z-z_2(\theta))(z-z_3(\theta)) = 0. $$ Assume that, concerning the roots of the characteristic equation:
- $|z_1(\theta)| = |z_2(\theta)| = |z_3(\theta)| = 1$ for every $\theta \in \mathbb{R}$, id est, the roots are on the unit sphere for every value of the parameter.
- $z_1(\theta)$, $z_2(\theta)$, and $z_3(\theta)$ are distinct for every $\theta \neq 0$ and for $\theta = 0$, we have that $z_1(0) = 1$ and $z_2(0) = z_3(0) = -1$, hence we have a double root.
The theory on linear constant coefficient recurrence relation states that the (general) solution $y^{n}(\theta)$ is: \begin{align*} y^{n}(\theta) &= \begin{cases} \sigma_1(\theta) z_1(\theta)^n + \sigma_2(\theta) z_2(\theta)^n + \sigma_3(\theta) z_3(\theta)^n, \qquad &\theta \neq 0, \\ \tilde{\sigma}_1 + \tilde{\sigma}_2 (-1)^n + \tilde{\sigma}_3 n (-1)^n, \qquad &\theta = 0, \end{cases} \\ &= \begin{cases} \sigma_1(\theta) z_1(\theta)^n + \sigma_2(\theta) z_2(\theta)^n + \sigma_3(\theta) z_3(\theta)^n, \qquad &\theta \neq 0, \\ \tilde{\sigma}_1 (1)^n + \tilde{\sigma}_2 (-1)^n + \tilde{\sigma}_3 n (-1)^n, \qquad &\theta = 0, \end{cases} \end{align*} where $\sigma_1$, $\sigma_2$, $\sigma_3$ and $\tilde{\sigma}_1$, $\tilde{\sigma}_2$, $\tilde{\sigma}_3$ will be determined by enforcing the initializations of the recurrence relation.
Question: is there a way of writing a closed formula for $y^n(\theta)$ valid for every $\theta \in \mathbb{R}$ (including $\theta = 0$) as a function of $z_1, z_2, z_3$ and $n$, with coefficient determined by the initialization, without having to treat $\theta = 0$ and $\theta \neq 0$ separately as done here?
The issue is that, despite the fact that the coefficient of the recurrence relation are smooth, the nature of the roots of the characteristic equation changes with $\theta$ (see also Do eigenvalues depend smoothly on the matrix elements of a diagonalizable matrix? or Regularity of the eigenvalues of a matrix-valued function).