等比数列an,其前n项和为Sn,且Sn+1,Sn,Sn+2成等差数列,求公比q