Matrix differential equation