# C L.'s periodic sequences

**Discrete Mathematics**Level 5

The sequence \( x_0, x_1, x_2, \ldots \) is defined by the recurrence relation

\[ x_{n+1} = a x_n + b x_{n-1} + c x_{n-2} + d x_{n-3}, n\ge 3.\]

For fixed integers \(a, b, c, d\), it turns out that regardless of the initial values \(x_0, x_1, x_2, x_3\), the sequence is eventually periodic. Find the sum of all possible periods.

This problem is posed by C L.

**Details and assumptions**

As an explicit example, \(3\) is a possible period since the recurrence relation \(x_{n+1} = x_{n-2}, n\ge 3\) is eventually periodic regardless of the starting values \(x_0, x_1, x_2, x_3\).