On the prediction of earthquakes