 Complete the following phrase:  He graduated from the United States Military Academy in 1839 as a brevet second lieutet in the 2nd U.S. Artillery. He served in the Mexican War under Winfield Scott, and was appointed a brevet captain for gallantry at 