Consider a two letter alphabet \(\Sigma = \{a, b\}\). A formal series \(f : \Sigma^* \to \mathbb Q\) has relative degree \(r \in \mathbb N\) if
- all words \(w \in \Sigma^*\) in its support \(f(w) \neq 0\) are of the form \(w \in a^r \cdot \Sigma^* \), and
- \(f(a^r \cdot b) \neq 0\).
Decide whether a rational series has a relative degree.