# What does the arbitrary constant in cosine equation of displacement in S.H.M say?

The phase and phase constant in a displacement time equation show from where the particle has started.

In my school textbook, first the displacement equation was given as :- $$x= A\sin(\omega t+\phi)$$

where $$\phi$$ is the phase constant.

But then it said if the particle is at extreme position then we add $$\pi/2$$ because obviously displacement is maximum at $$\pi/2$$ So now the equation at extreme should be :- $$x=A\sin\left(\omega t+\frac{\pi}{2}\right)$$ $$x=A\cos(\omega t)$$

But in my textbook the equation is :- $$x=A\cos(\omega t + \phi')$$

It says that $$\phi '$$ is another arbitrary constant. But technically $$\phi$$ is $$\sin ^{-1} (x/A)$$, here $$x$$ will be $$A$$ and we get $$\pi/2$$ so no constant remains. But what is this $$\phi '$$ constant and on which thing it depends?

OK, you already understood the most important part. This is that $$\sin{(wt + \frac{\pi}{2})} = \cos{(wt)}$$ This implies, that the two following equations are equally valid

• $$x(t) = A \sin{(wt + \phi)}$$ or
• $$x(t) = A \cos{(wt + \phi^\prime)}$$

to define the position of an oscillator. If we like to start at the max. amplitude at $$t=0$$ we can either write

• $$x(t) = A \sin{(wt + \pi/2)}$$, where we used $$\phi = \pi/2$$ or
• $$x(t) = A \cos{(wt)}$$, where we used $$\phi^\prime = 0$$.

Thus, no matter what, you will always obtain $$\phi = \phi^\prime + \pi/2$$.

• Please trade your $w\to\omega$ to make it nice... Commented Feb 2, 2020 at 14:43
• @ZeroTheHero: Thank you very much for your compliment, but I don't feel that my $w$ are ugly :) Furthermore, I don't want to bring this answer to the top of the stack just by eliminating this minor "defective appearance". Commented Feb 2, 2020 at 15:11
• the OP did use $\omega$, not $w$. Anyways agreed it's not worth sending back to the top now. Commented Feb 2, 2020 at 15:23
• @ZeroTheHero FWIW, the OP used non-MathJax $\Omega$ which I edited to $\omega$.
– user253029
Commented Feb 2, 2020 at 15:30
• @FakeMod much nicer with $\omega$ or $\Omega$... :D Commented Feb 2, 2020 at 15:31

It depends on the initial conditions. If its at maximum displacement at $$t=0$$ then the equation is $$x=A\cos{\omega t}$$. If it is at equilibrium position and maximum velocity at $$t=0$$ then $$x=A\sin{\omega t}$$. In general, the solution is $$x=a\cos{\omega t} + b\sin{\omega t}$$ which simplifies to either $$A\cos{(\omega t + \phi ')}$$ or $$A\sin{(\omega t +\phi)}$$ using the harmonic addition formula.

At $$t=0$$ the displacement $$x$$ is not necessarily $$0$$: $$x(0)=A\sin(\phi) \tag{1}$$ In addition, the velocity at $$t=0$$ $$\dot{x}(0)=\omega A \cos(\phi) \tag{2}$$ (1) and (2) are two equations for your 2 unknowns $$A$$ and $$\phi$$. Thus, as you alluded to $$\frac{x(0)}{\dot x(0)}= \omega\tan(\phi)$$ from which you can determine $$\phi$$, and plug it back into either (1) or (2) to obtain $$A$$ if you need the amplitude.