  We consider how to obtain a nontrivial two-qubit unitary transformation
purely based on geometric phases of two spin-1/2's with Ising-like interaction
in a magnetic field with a static z-component and a rotating xy-component. This
is an interesting problem both for the purpose of measuring the geometric
phases and in quantum computing applications. In previous approach, coupling of
one of the qubit with the rotating component of field is ignored. By
considering the exact two-spin geometric phases, we find that a nontrivial
two-spin unitary transformation purely based on Berry phases can be obtained by
using two consecutive cycles with opposite directions of the magnetic field and
opposite signs of the interaction constant. In the nonadiabatic case, starting
with a certain initial state, a cycle in the projected space of rays and thus
Aharonov-Anandan phase can be achieved. The two-cycle scheme cancels the total
phases, hence any unknown initial state evolves back to itself without a phase
factor.
