What was a primary reason for the shift from agrarian economies to industrial production in Western Europe during the 18th century?