Skip to main content
17-Peridot
January 24, 2011
Solved

Finding roots of a non-rational function

  • January 24, 2011
  • 2 replies
  • 8520 views

Hello folks,

I have a weird problem: for some measurement data I'm trying to find the roots. This data appears to be best approximated by a sine function. As MathCad's roots/polyroots function works with rational functions only (or am I wrong on this one?) I tried to use the MATCH function together with the control parameter "near".

Weird enough, it finds only a few of the roots (see graph in the attached MC 11 file). Why doesn't it work and how could I improve this?

Thanks in advance

Raiko

Best answer by MikeArmstrong

Slightly different approach and I have used your match function.

Mike

2 replies

1-Visitor
January 24, 2011

Your fitting functions doesn't look right, have you tried using the smoothing functions with Mathcad?

Clipboard01.jpg

Mike

Raiko17-PeridotAuthor
17-Peridot
January 24, 2011

Hello Mike,

yes this fitting function is an approximation by utilising a sine-function. I tried smoothing, but I'm more confident with the sine function.

Nonetheless, this doesn't solve my problem: finding the roots. Do you believe that MATCH might work better with a smoothed data set?

Thanks

Raiko

19-Tanzanite
January 24, 2011

You don't have the correct x-axis for the zero points.

The data doesn't look very sinusoidal to me. If you look at the spectrum there's at least two main frequency components. I think even two frequency components could not model that data very well though.

I have included a different approach to find the zeros using a function that finds the maxima or minima in data (I've posted this function before).

Raiko17-PeridotAuthor
17-Peridot
January 24, 2011

Hello Richard,

you're correct in guessing that this isn't a pure sinusoidal function. It is a oscillator who's hampered by a second oscillator ; coupled therefore.

However, with this fit it is easier to determine the frequency of the oscillation. I still don't get it why the match function fails! Any idea?

Anyhow, thanks a lot for your time. Your approach yields better results.

Raiko

19-Tanzanite
January 24, 2011

The match isn't failing. You are just plotting the dots with the wrong x-axis, so they are off the graph.