Number of Unique Necklaces upto Rotation AND Reflection Say I have beads of $5$ colours, White, Yellow, Red, Green and Blue. I want to create a necklace of length $17$. How many unique necklaces can I create? (Up to rotation and reflection. For example, if the length was just 3, RGB and RBG should be identical)
The main problem I was facing was I could not choose a "uniform" factor to divide with. There are way too many different cases. Any tips/hints? I'm not even sure if this can be done via elementary combinatorics only.

There     is      a     fact      sheet     on      necklaces     and
bracelets. We find
the cycle index
$$Z(D_{17}) =
\frac{1}{2}
\frac{1}{17} \left( a_1^{17}+ 16 a_{17}\right)
+ \frac{1}{2} a_1 a_2^{8}.$$
We get for at most five colors,
$$\frac{1}{34} 5^{17} + \frac{16}{34} 5 +
\frac{1}{2} 5^9.$$
This is
$$\bbox[5px,border:2px solid #00A000]{
22440372245.}$$
