Cognition by synchronization