Theory of the threshold field for the depinning transition of a charge density wave