F(x)=sinx(sinx+2cosx)+3cos^2x
=sin^2x+2sinxcosx+3cos^2x
=1+2cos^2x+sin2x
=cos2x+sin2x+2
=根号2sin(2x+pai/4)+2