4 ms·
For an intuitive understanding, try to build one in one dimension. Imagine you have a position that's drifting at a roughly constant, but noisy, rate, modeled b
by jtolmar 6y ago
For an intuitive understanding, try to build one in one dimension. Imagine you have a position that's drifting at a roughly constant, but noisy, rate, modeled by a normal distribution. You also have an occasional 1D GPS reading about that position. As building blocks, check out conjugate priors, specifically normal-normal [1] and the algebra of random variables, specifically the sum of normally distributed variables [2].
Briefly:
If you have a normal distribution as a prior and a normal distribution as new evidence, then applying Bayes Theorem on them results in a new normal distribution (times a constant we'll ignore). The calculation can actually be pretty simple - the mean is a weighted average, weighted by precision (precision is 1/variance), and the precision is the sum of the two precisions.
If you have two normal distributions modeling unknown variables a and b, and you know x=a+b, then you can model your knowledge of x as another normal distribution. The calculation for this one is also simple - its mean is the sum of the two means (intuitively has to be) and its variance is the sum of the two variances (I've seen several math books say it's surprising. It's very convenient though).
So you have all the pieces you need to do (new state guess = old state knowledge + noise from passage of time) and (new state knowledge = new state guess | new observation), where all the variables are normal distributions, and the new knowledge ends up being a normal distribution too, so you can use it as the old knowledge next time you get information.
[1] https://en.wikipedia.org/wiki/Conjugate_prior#When_likelihood_function_is_a_continuous_distribution https://en.wikipedia.org/wiki/Conjugate_prior#When_likelihoo...
[2] https://en.wikipedia.org/wiki/Sum_of_normally_distributed_random_variables https://en.wikipedia.org/wiki/Sum_of_normally_distributed_ra...
- kqr 6y agoThis is a great suggestion. For any topics like these, starting in very low dimensional space and working through an example is a fantastic way to understand it. I'd also suggest not only trying to imagine this in your head: implement it in code. That's how I truly learn these types of things. For extra fun, you can make it into a game. After you've implemented the filter, create a way for a human to input a guess at the filtered output. Score it depending on how close it is. This way you get to practise your intuition for it too.