tanx(sin2x+1)=sinx(2+tanx)
⇒sinx[sin2x+1cosx−(2+tanx)]=0
⇒sinx=0
or sin2x+1=2cosx+sinx, cosx≠0
⇒sin2x−sinx+1−2cosx=0
⇒sinx(2cosx−1)−1(2cosx−1)=0
⇒(sinx−1)(2cosx−1)=0
⇒sinx=1,cosx=12
sinx=0,1; cosx=12
But sinx≠1
∴x=nπ,2nπ±π3
x=π,2π,3π,π3,2π±π3,4π−π3
i.e., a total of 7 solutions in (0,4π)