Consider a general equation, x=Acosωt
Apply for OP, A−a=Acosωt
From here, cosωt=A−aA
Similarly, A−(a+2a)=Acos2ωt
[∴ time doubled]
cos2ωt=A−3aAcos2θ=2cos2θ−1(A−aA)2=A−3a+A2A
From here, A=2a
So, amplitude of the motion is 2a
2a−a=2acosωtπ3=ωtπ3=2πTtT=6t
⟹n=6