# How do I color one line of a display equation?

I want to color only one line of this display equation:

\begin{align*}
i_{fb} &= - \frac{v_o}{Z_F} \\
F(s) = \frac{i_{fb}}{v_o} &= - \frac{1}{Z_F} \\
\color{red} F(s) &= - \frac{1 + sR_F C_F}{R_F}
\end{align*}


How do I do it? The above example only provides color to F(s). Enclosing whole line in {} causes ref to appear at the right side.

Use the color package and do

\color{red} F(s) &\color{red}= - \frac{1 + sR_F C_F}{R_F}

• So \color{...} does not work across alignment columns? – Kit Feb 28 '14 at 10:34
• @Kit No, each cell is a group – daleif Feb 28 '14 at 10:34

You can use the hf-tikz package, which was built as a result of Beamer: highlighting aligned math with overlay. Here's a MWE- note that I had to use \tikzmarkin{c}(0.1,-0.4)(-0.1,0.5) to get the boundaries corrected- you might want to adjust them further as you see fit :)

% arara: pdflatex
% arara: pdflatex
% !arara: indent: {overwrite: yes}
\documentclass{article}
\usepackage{amsmath}
\usepackage{hf-tikz}

\begin{document}

\begin{align*}
i_{fb}                                 & = - \frac{v_o}{Z_F}                         \\
F(s) = \frac{i_{fb}}{v_o}              & = - \frac{1}{Z_F}                           \\
\tikzmarkin{c}(0.1,-0.4)(-0.1,0.5)F(s) & = - \frac{1 + sR_F C_F}{R_F}\tikzmarkend{c}
\end{align*}

\end{document}