Solving Noisy Weather Sensor Probability: Day 5 Sunny

In summary, the conversation discusses the use of an imperfect sensor to measure weather conditions in a fixed location. The probability of a certain weather condition on day 5 is being calculated using a known stochastic matrix. The conversation also mentions the use of Bayes Rule and previous exercises for similar situations. The code for a Bayes Filter is also provided.
  • #1
carllacan
274
3

Homework Statement



An imperfect sensor measures the weather (which can only be either sunny, cloudy or rainy) in a fixed place. Suppose we know the weather on the first day was sunny. In the following days we obtain the measurements cloudy, cloudy, rainy, sunny.

What is the probability that the weather at day 5 is indeed sunny as our sensor says?

Homework Equations



The noise of the sensor is given by a known stochastic matrix:

[itex]
S_{ij} = p(z_n = j | x_n = i)
[/itex]

where [itex]z_n[/itex] refers to a measurement and [itex]x_n[/itex] to the real state at day n, and [itex]i[/itex] and [itex]j[/itex] refer to the possible weathers (sunny, cloudy, rainy).

The Attempt at a Solution



I just tried to find a general formulation, as I saw that I would probably need it later.

By straightforward application of Bayes Rule I've found the expression:

[itex]
p(x_n = i | z_n = j) = \frac{p(z_n = j | x_n = i)p(x_n = i)}{p(z_n = j)}
[/itex]

Now, here is where I have trouble. How can I find out the real probability that one day had a certain weather?

In a previous exercise I was presented with a similar situation and was given a stochastic matrix that described the probability of weather on a certain day based on the weather of the previous day. I am not sure that it applies also to this exercise. Is there any way to solve it with the given data?
 
Last edited:
Physics news on Phys.org
  • #2
I had misread the statement of the problem. I have update the info now. Can someone help me?
 
  • #3
I've worked out this code for the Bayes Filter, would you mind telling me if I've done it right?
Code:
function newx = posterior(z, x0, transmat, sensmat)
  if size(z)(2) = 0
    newx = x0
  end
  
  prior = posterior(z(1:end-1), x0, transmat, sensmat)*transmat(:,x)	
  norm = sensmat*prior   
  newx = sensmat(x)(z)* prior / norm
endfunction
 
Last edited:

1. How do you determine the probability of a sunny day using noisy weather sensors?

The probability of a sunny day can be determined using a mathematical model that takes into account the noise factor in the weather sensors. This model uses data from multiple sensors and applies statistical techniques to calculate the probability of a sunny day.

2. What are the main challenges in solving this problem?

The main challenges in solving this problem include dealing with the uncertainty and variability of the weather data collected by the sensors, finding an accurate and reliable way to filter out the noise, and developing a robust mathematical model that can accurately predict the probability of a sunny day.

3. How can you improve the accuracy of the weather sensors?

To improve the accuracy of weather sensors, you can use advanced signal processing techniques to filter out noise, calibrate the sensors regularly, and use multiple sensors to gather data from different locations. Additionally, using more advanced and sophisticated sensors can also lead to improved accuracy.

4. Can this model be applied to other weather conditions besides sunny days?

Yes, this model can be applied to other weather conditions such as rainy, cloudy, or snowy days. However, the model may need to be adjusted or modified based on the specific weather conditions and type of noise present in the data.

5. How can this model be useful in real-life applications?

This model can be useful in various real-life applications such as predicting weather patterns for agricultural or transportation purposes, improving the accuracy of weather forecasts, and aiding in disaster preparedness and response. It can also be used in industries that heavily rely on weather conditions, such as energy and construction.

Similar threads

  • Set Theory, Logic, Probability, Statistics
Replies
4
Views
1K
  • Precalculus Mathematics Homework Help
Replies
5
Views
4K
Replies
118
Views
10K
  • Set Theory, Logic, Probability, Statistics
Replies
6
Views
2K
Replies
152
Views
5K
  • Math Proof Training and Practice
4
Replies
105
Views
12K
  • Set Theory, Logic, Probability, Statistics
Replies
22
Views
4K
  • General Math
4
Replies
125
Views
16K
  • Math Proof Training and Practice
2
Replies
42
Views
6K
Replies
10
Views
2K
Back
Top