\(\Leftrightarrow\left|x^2-x+1\right|=x\)
\(ĐK:x\ge0\)
\(\Leftrightarrow\left[{}\begin{matrix}-x^2+x-1=x\\x^2-x+1=x\end{matrix}\right.\) \(\Leftrightarrow\left\{{}\begin{matrix}-x^2-1=0\left(vô.lí\right)\\x^2-2x+1=0\end{matrix}\right.\)
\(\Leftrightarrow\left(x-1\right)^2=0\)
\(\Leftrightarrow x=1\left(tm\right)\)
Vậy \(S=\left\{1\right\}\)