For
x=1, write
1+x+⋯+x17=x−1x18−1, so
(x−1)2P(x)=(x18−1)2−x17(x−1)2=x36−x19−x17+1=(x19−1)(x17−1). Hence the zeros of
P are the
34 complex numbers other than
1 satisfying
x17=1 or
x19=1; all lie on the unit circle, with angles
α=17k for
k=1,…,16 and
α=19k for
k=1,…,18.
The five smallest of these angles are
191<171<192<172<193, whose sum is
196+173=323102+57=323159. Since
159=3⋅53 and
323=17⋅19, this is in lowest terms, and
m+n=159+323=482.