Linear fitting in physics experiments with errors

  • #1
2
0
Hello!

I have a question that maybe has to do more with Mathematics, but if you do experimental physics you find it quite often.

Let's assume that we want to measure two quantities x and y that we know that they relate to each other linearly. So we have a set of data points xi and yi, i=1,...,n, and we want to make a linear fit. According to the method of least squeares there exist formulas for a, b, where y=a+bx, and their errors da and db. These formulas, if I'm not wrong, are these in the following link: http://prntscr.com/iz15tk ( [ ] means sum)

But in the most common case, for each xi and yi value we have an error dxi and dyi, i =1,...,n respectively. In this case wich are the formulas about a, b, da, db? Of course these values shoud be different from the first case. I've searched on the internet but I couldn't find anything in this general case.

Do you have any ideas?
Thank you.
 

Answers and Replies

  • #2
tnich
Homework Helper
1,048
336
Hello!

I have a question that maybe has to do more with Mathematics, but if you do experimental physics you find it quite often.

Let's assume that we want to measure two quantities x and y that we know that they relate to each other linearly. So we have a set of data points xi and yi, i=1,...,n, and we want to make a linear fit. According to the method of least squeares there exist formulas for a, b, where y=a+bx, and their errors da and db. These formulas, if I'm not wrong, are these in the following link: http://prntscr.com/iz15tk ( [ ] means sum)

But in the most common case, for each xi and yi value we have an error dxi and dyi, i =1,...,n respectively. In this case wich are the formulas about a, b, da, db? Of course these values shoud be different from the first case. I've searched on the internet but I couldn't find anything in this general case.

Do you have any ideas?
Thank you.
What you are looking for is called a Maximum Likelihood Estimator.
 
  • #3
hilbert2
Science Advisor
Insights Author
Gold Member
1,530
553
Usually the error bars of data points are ignored when doing a least squares fit, as the slope and intercept should approach the "correct" value if there's a large enough number of data points and the error is not systematic.
 

Related Threads on Linear fitting in physics experiments with errors

  • Last Post
Replies
1
Views
4K
Replies
5
Views
888
  • Last Post
Replies
3
Views
6K
Replies
4
Views
9K
Replies
5
Views
998
  • Last Post
Replies
1
Views
1K
  • Last Post
Replies
19
Views
2K
  • Last Post
Replies
1
Views
2K
  • Last Post
Replies
1
Views
3K
  • Last Post
Replies
1
Views
2K
Top