brownadder / magpy

Magnus based time-integration for spins and qubits under a magnetic field
MIT License
1 stars 2 forks source link

Hop with matrix example doesn't seem to be working #12

Closed brownadder closed 2 years ago

brownadder commented 2 years ago

Try A = 2x2 matrix and Hop(A), propagate 1 spin.

gc759 commented 2 years ago

It is actually working. The QSystem function requires the input Hamiltonian to be specified as a dictionary of functional coefficients paired with an HOp object. After passing a square NumPy array directly, aforementioned dictionary need to be constructed.