\(B=4sin^4\dfrac{\pi}{16}+2cos\dfrac{\pi}{8}\)
\(=4sin^4\dfrac{\pi}{16}-4sin^2\dfrac{\pi}{16}+2\)
\(=4sin^2\dfrac{\pi}{16}\left(sin^2\dfrac{\pi}{16}-1\right)+2\)
\(=-4sin^2\dfrac{\pi}{16}.cos^2\dfrac{\pi}{16}+2\)
\(=-sin^2\dfrac{\pi}{8}+2\)
\(=\dfrac{1}{2}\left(1-2sin^2\dfrac{\pi}{8}\right)+\dfrac{3}{2}\)
\(=\dfrac{1}{2}cos\dfrac{\pi}{4}+\dfrac{3}{2}\)
\(=\dfrac{\sqrt{2}+6}{4}\)