Causes and Explanations: A Structural-Model Approach --- Part 1: Causes