The displacement of a particle executing simple harmonic motion is given by y=A0+Asinωt+Bcosωt. Then the amplitude of its oscillation is given by
y=A0+Asinωt+Bcosωt
or y-A0=Asinωt+Bcosωt
or y'=Asinωt+Bcosωt=Acosπ2-ωt+Bcosωt
Amplitude =A2+B2+2ABcosπ2 ∵ϕ=π2 =A2+B2