How would a food surplus in the ancient river valley of Mesopotamia create trade and establish a formal government and strong military?
When agricultural practices become efficient enough so that food production increases, a given culture will begin to flourish. This applies not only to Mesopotamia, but to any culture. If there's enough agricultural efficiency, not everybody has to grow food; in most ancient cultures a small food surplus allowed the creation of a priestly/ruling class that didn't till the fields, but became the leaders. As food supplies increase, more people were freed to become members of a soldier class, that would safeguard the leaders and farmers. At this point in a culture, if most of the people are fed, the surplus can be traded for other commodities from other cultures. So surplus food stores allow for the division and specialization of labor within a culture which promotes its development. As more members of a culture do other activities than farming, the leaders become a structured government, the defending soldiers become a military, with offensive capabilities, and traders become a merchant class.