Dynamic simulation of sheared suspensions. I. General method | Synapse