If $$0 < x < 2\pi,$$ the sum of all the roots of $\tan^2 x-4\tan x+1=0$ can be expressed as $$a\pi.$$ What is the value of $$a?$$