The Massachusetts economy contracted slightly in the third quarter, local economists reported Wednesday, the same day that the federal goverment reported the U.S. economy grew 1.9 percent in the quarter that ended Sept. 30.