Hebbian imprinting and retrieval in oscillatory neural networks