An apparatus includes a magnetically biased multilayer structure having a
reference layer and a free layer separated by a spacer layer; a DC
current source connected to the multilayer structure; an AC current
source connected to the multilayer structure; and a phase detector for
measuring a phase difference between an AC current and a voltage across
the multilayer structure. A method performed by the apparatus is also
provided.