1
$\begingroup$

If I have a signal of the form $x\left(n\right)=Acos\left(nω+ϕ\right)$

where

$\omega \in \left[\omega -\lambda ,\omega \:+\lambda \:\right]$ is a uniform random variable and

$\phi $ is also a uniform random variable $\left[-\pi ,\pi \right]$.

I need to find the mean and the autocorrelation.

So we know the mean $E\left[x\left(n\right)\right]\:=\:AE\left[cos\left(n\omega +\phi \right)\right]$.

I think the $E\left[x\left(n\right)\right]\:=0$ regardless of the random variables just because of the periodicity of the cosine sequence.

Now I would also like to find the auto-correlation function

$R\left(n,k\right)=\:E\left[x\left(n\right)x\left(n+k\right)\right]=A^2E\left[cos\left(n\omega +\phi \right)cos\left(\left(n+k\right)\omega \:+\phi \:\right)\right]=\frac{A}{2}^2\left\{E\left[cos\left(2\left(n\omega +\phi \right)+k\omega \right)\right]+E\left[cos\left(k\omega \right)\right]\right\}=\frac{A}{2}^2cos\left(k\omega \right)$

I am not sure if am solving this the right way, can somebody please tell me if am doing something wrong? because I think the random variables must have a role in this

$\endgroup$
2
  • $\begingroup$ Can somebody please help me with this??? $\endgroup$
    – JordenSH
    Apr 4 at 1:44
  • $\begingroup$ yes, that looks correct to me. $\endgroup$
    – mark leeds
    Apr 4 at 2:38
2
$\begingroup$

The "periodicity of the cosine" has little to do with the matter at hand. Indeed, unless $\omega/\pi$ is a rational number, it is not even the case that the discrete-time sequence $x[n] = A\cos(n\omega + \phi)$ is a periodic sequence at all. See, for example, this question which asks "Why is $\cos\left(\frac n6\right)$ aperiodic?" Now, coming to the meat of the question and correcting meaning-less notation such as $\omega \in [\omega-\lambda,\omega+\lambda]$ to $\omega \in [\omega_0-\lambda,\omega_0+\lambda]$, we have from LOTUS, the law of the unconscious statistician, that $$E\left[x[n]\right] = E[A\cos(n\omega + \phi)] = A \int_{-\pi}^{\pi}\int_{\omega_0-\lambda}^{\omega_0+\lambda}\cos(n\omega + \phi)f_{\omega,\phi}(\omega,\phi)\, \mathrm d\omega \,\mathrm d\phi \tag{1}$$ where $f_{\omega,\phi}(\omega,\phi)$ is the joint density of $\omega $ and $\phi$. The OP has not stated that $\omega$ and $\phi$ are independent random variables, but if they are assumed to be independent (as is most likely the intention), then the joint density in $(1)$ factors into the product of the marginal densities (which are given to be uniform on $[\omega_0-\lambda,\omega_0+\lambda]$ and $[-\pi,\pi]$ respectively,) and so $(1)$ can be written as $$E\left[x[n]\right] = A \int_{-\pi}^{\pi}\frac{1}{2\pi}\left[\frac{1}{2\lambda}\int_{\omega_0-\lambda}^{\omega_0+\lambda} \cos(n\omega + \phi) \, \mathrm d\omega\right] \,\mathrm d\phi. \tag{2}$$ Similarly, the autocorrelation function is given by $$E\left[x[n]x[m]\right] = A \int_{-\pi}^{\pi}\frac{1}{2\pi}\left[\frac{1}{2\lambda}\int_{\omega_0-\lambda}^{\omega_0+\lambda} \cos(n\omega + \phi)\cos(m\omega + \phi) \, \mathrm d\omega\right] \,\mathrm d\phi. \tag{2}$$

$\endgroup$
8
  • $\begingroup$ Would you please tell me why we're integrating? I thought we're supposed to use summation in discrete time. Please explain. Thank you so much in advance. $\endgroup$
    – JordenSH
    Apr 4 at 3:17
  • 1
    $\begingroup$ @Raykh you're discrete in time, but not in the values your random variables take. Take care -the expectation operator here is not "averaging over time"! $\endgroup$
    – mmmm
    Apr 4 at 8:06
  • 1
    $\begingroup$ (That's a pretty common confusion to have: you're not calculating a time average; the time is fixed as $m,n$. You're calculating an expectation at that time. See also: ergodicity (which isn't given here)) $\endgroup$
    – mmmm
    Apr 4 at 8:33
  • $\begingroup$ Dilipe wrote a beautiful, detailed and educational answer but I just want to point out that the OP's answer is correct because the integrals simplify because of the uniform distribution. See example 9-1-5 at homepages.wmich.edu/SW-Notes09.pdf $\endgroup$
    – mark leeds
    Apr 4 at 13:10
  • $\begingroup$ link doesn't work but if you google for autocorrelation with uniform phase, the chapter 9 random processes result has it in SW-notes09.pdf. it's for the sine but similar argument holds. $\endgroup$
    – mark leeds
    Apr 4 at 13:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.