Design and operation of spin valve sensors