You are looking for a linear combination with integer coefficients of the given number and the powers of the root of unity with an absolute value that's very small (where "very" is determined by the precision of the given approximation). This translates into a search for short vectors in a lattice, preceded by a standard lattice basis reduction.
Computer algebra systems like PARI/GP have suitable algorithms built in.
Working in the maximal real subfield for the sake of this example:
gp > ?lindep
lindep(v,{flag=0}): integral linear dependencies between components of v. flag
is optional, and can be 0: default, guess a suitable accuracy, or positive:
accuracy to use for the computation, in decimal digits.
gp > 2*cos(2*Pi/7)
%22 = 1.2469796037174670610500097680084796213
gp > lindep([1.,%22, sqr(%22),5.7137917357844], 12)
%23 = [3, -2, -4, 1]~
gp > 4*sqr(%22)+2*%22-3
%24 = 5.7137917357844188877887990200426011668