\[a \neq b:\]
\[f(x) = f(2a - x) = f(2b - x).\]
\[1)\ b > a:\]
\[T = 2(b - a) = 2b - 2a > 0\]
\[f(x + T) = f(2b - x - T) =\]
\[= f(2b - x - 2b + 2a) =\]
\[= f(2a - x) = f(x).\]
\[2)\ a > b:\]
\[T = 2(a - b) = 2a - 2b > 0;\]
\[f(x + T) = f(2a - x - T) =\]
\[= f(2a - x - 2a + 2b) =\]
\[= f(2b - x) = f(x).\]
\[Ответ:\ \ 2|b - a|.\]