During the 4th century BC, the maximum number of standing troops Carthage expected at its service can be estimated from the capacity of the barracks located in the three rings of walls that protected the city, offering accommodation to 24,000 infantry, 4,000 cavalry, and 300 elephants. In addition to their own conscripted forces, large contingents of mercenaries and auxiliaries would be employed. Appian mentions that in total 40,000 infantry, 1,000 cavalry, and 2,000 heavy chariots were recruited to oppose the invasion of Agathocles of Syracuse.