Question about fitting periodic data

  • #1
21
0
My experience with data fitting is poor so I am in real need for help.
The potential in the following is periodic over [0,Pi]
-TvEuURwmnboNeDc1hN8aBhBkWcK4kYbjZhf4lPAZeE6fUeQvsEFcp56MUrHXa2Y9tATurVnxQLgm3EVsdR=w360-h211-no.gif

I need to find a fitting function that I can use to perform further mathematics. Fourier series does not work, but a 40-degree polynomial give the following fit
9iL8mytaLHj6GJp882dVJnCy-Nqr62qTLGS0dNx4JEdCKuJWhwD_DRFy3JoUr6X6kWcId3eSMQshzo9jtIM=w360-h215-no.gif

However, the polynomial does not preserve its periodicity over the cycle. Could someone please advice what I should do to get a good fitting function for my data?
 
Mathematics news on Phys.org
  • #2
Fitting with a polynomial with degree larger than 3 is a really bad idea.

Why don't you try to fit this function with a combination of straight lines?? And why do Fourier series not work?
 
  • #3
A set of straight lines for different ranges should fit best. A Fourier series should give reasonable approximations, but only if you include many terms.
 
  • #4
Looking at the vertical scale: Is your data set really constricted to the value -9.74771?
 

Suggested for: Question about fitting periodic data

Replies
6
Views
657
Replies
4
Views
252
Replies
33
Views
1K
Replies
1
Views
699
Replies
17
Views
1K
Replies
22
Views
3K
Replies
19
Views
1K
Replies
7
Views
559
Replies
3
Views
2K
Back
Top