# variance and covariance need to clarify!

• Jan 11th 2009, 08:21 AM
ArixII
variance and covariance need to clarify!
Hi,
There is an example in an article where the author calculates variance and covariance, but I can't understand how (I'm novice in the topic). The example is about a vehicle that is traveling straight on the road:

The postition is measured with an error of 10 feet (one standard deviation)
The command acceleration is a constant 1 foot/sec^2
The acceleration noise is 0.2 feet/sec^2 (one standard deviation)
The position is measured 10 times per second.

Since the position is proportional to 0.0005 times the acceleration, and the acceleration noise is 0.2 feet/sec^2, the variance of the position noise is (0.005)^2 * (0.2)^2 = 10^(-6)
...

[and what formula is used to calculate this? (Surprised)]

[author continues]
...Similarly, since the velocity is proportional to 0.1 times the acceleration, the variance of the velocity noise is (0.1)^2 * (0.2)^2 = 4 * 10^(-4). Finally, the covariance of the position noise and velocity noise is equal to the standard deviation of the position noise times the standard deviation of the velocity noise, which can be calculated as (0.005 * 0.2) * (0.1 * 0.2) = 2 * 10^(-5).
=================================================

Well I know that:
cov(X,Y) = E[(X - mu_x) * (Y - mu_y)]
but this is not what he used, right? does somebody knows the formulas used in such calculations?

Thank you! (Clapping)
• Jan 11th 2009, 08:52 AM
Laurent
Quote:

Originally Posted by ArixII
Hi,
There is an example in an article where the author calculates variance and covariance, but I can't understand how (I'm novice in the topic). The example is about a vehicle that is traveling straight on the road:

The postition is measured with an error of 10 feet (one standard deviation)
The command acceleration is a constant 1 foot/sec^2
The acceleration noise is 0.2 feet/sec^2 (one standard deviation)
The position is measured 10 times per second.

Since the position is proportional to 0.0005 times the acceleration, and the acceleration noise is 0.2 feet/sec^2, the variance of the position noise is (0.005)^2 * (0.2)^2 = 10^(-6)
...

[and what formula is used to calculate this? (Surprised)]

It seems to be simply a consequence of $\displaystyle {\rm Var}(\lambda X)=\lambda^2{\rm Var}(X)$, which is easily seen from the definition of the variance.

So the variance of $\displaystyle X=0.005 A$ is $\displaystyle {\rm Var}(X)=0.005^2 {\rm Var}(A)=0.005^2\cdot 0.2^2$.

Quote:

[author continues]
...Similarly, since the velocity is proportional to 0.1 times the acceleration, the variance of the velocity noise is (0.1)^2 * (0.2)^2 = 4 * 10^(-4). Finally, the covariance of the position noise and velocity noise is equal to the standard deviation of the position noise times the standard deviation of the velocity noise, which can be calculated as (0.005 * 0.2) * (0.1 * 0.2) = 2 * 10^(-5).
=================================================

Well I know that:
cov(X,Y) = E[(X - mu_x) * (Y - mu_y)]
but this is not what he used, right? does somebody knows the formulas used in such calculations?

Thank you! (Clapping)
Again, this is in fact quite simple, and very specific to your setting: you have $\displaystyle X=\lambda A$ from above, and $\displaystyle V=\mu A$ where $\displaystyle \lambda=0.005$ and $\displaystyle \mu=0.1$ (with appropriate units), so that $\displaystyle {\rm Cov}(X,V)=E[(X-E[X])(V-E[V])]$$\displaystyle =E[\lambda(A-E[A])\mu(A-E[A])]=\lambda\mu E[(A-E[A])^2]$$\displaystyle =\lambda\mu{\rm Var}(A)=\sqrt{\lambda^2{\rm Var}(A)}\sqrt{\mu^2{\rm Var}(A)}$$\displaystyle =\sqrt{{\rm Var}(X)}\sqrt{{\rm Var}(V)}=\sigma(X)\sigma(V). I hope I'm right, I didn't try to understand the physics beneath. The whole thing relies on the way proportional quantities behave for the variance/covariance. • Jan 12th 2009, 01:06 AM ArixII Quote: Originally Posted by Laurent It seems to be simply a consequence of \displaystyle {\rm Var}(\lambda X)=\lambda^2{\rm Var}(X), which is easily seen from the definition of the variance. So the variance of \displaystyle X=0.005 A is \displaystyle {\rm Var}(X)=0.005^2 {\rm Var}(A)=0.005^2\cdot 0.2^2. Again, this is in fact quite simple, and very specific to your setting: you have \displaystyle X=\lambda A from above, and \displaystyle V=\mu A where \displaystyle \lambda=0.005 and \displaystyle \mu=0.1 (with appropriate units), so that \displaystyle {\rm Cov}(X,V)=E[(X-E[X])(V-E[V])]$$\displaystyle =E[\lambda(A-E[A])\mu(A-E[A])]=\lambda\mu E[(A-E[A])^2]$$\displaystyle =\lambda\mu{\rm Var}(A)=\sqrt{\lambda^2{\rm Var}(A)}\sqrt{\mu^2{\rm Var}(A)}$$\displaystyle =\sqrt{{\rm Var}(X)}\sqrt{{\rm Var}(V)}=\sigma(X)\sigma(V)$.

I hope I'm right, I didn't try to understand the physics beneath. The whole thing relies on the way proportional quantities behave for the variance/covariance.

Thank you!! It helped me to understand ) (Clapping)