Given :
$f(x)=\begin{vmatrix}\cos x&1&0\\1&2\cos x&1\\0&1&2\cos x\end{vmatrix}$
On expansion we get
$f(x)=\cos x(4\cos^2x-1)-2\cos x$
$\Rightarrow 4\cos^3x-3\cos x=\cos 3x$
$\int\limits_0^{\large\frac{\pi}{2}}2f(x)dx=2\int\limits_0^{\large\frac{\pi}{2}}\cos 3xdx$
$\Rightarrow 2\big[\large\frac{\sin 3x}{3}\big]_0^{\large\frac{\pi}{2}}$
$\Rightarrow -\large\frac{2}{3}$
Hence (B) is the correct answer.