\[3 \cdot (a + c)^{2} - 6ac =\]
\[= 3 \cdot \left( a^{2} + 2ac + c^{2} \right) - 6ac =\]
\[= 3a^{2} + 6ac + 3c^{2} - 6ac =\]
\[= 3a^{2} + \ 3c^{2}\]