handberg

08-23-2006, 09:46 AM

I am experiencing problems with the SPLINE function from the math library.

I have collected a particular data set: The position data, call it x, has spacing of 0.036 mm, strictly increasing, over the domain -3.8 to 3.8. The profile, call it y, is gaussian in nature over the range 0 to 140.5. I would like to refine the spacing to 0.025 mm over the same domain.

To do this, I have created position data using the FINDGEN function, and modified it to get the correct spacing and correct range. This data set, call it t, is also strictly increasing.

When I run the spline function:

> result = spline(x, y, t)

The result data is all undefined (-1.#IND0).

However, I can create garbage data following the procedure outlined in the Reference text, and it works just fine. I have also taken one step farther and created a gaussian curve, added random noise, and further refined that data with the same function call and it works fine.

This is probably an obvious problem, but it's frustrating! Any ideas??

I have collected a particular data set: The position data, call it x, has spacing of 0.036 mm, strictly increasing, over the domain -3.8 to 3.8. The profile, call it y, is gaussian in nature over the range 0 to 140.5. I would like to refine the spacing to 0.025 mm over the same domain.

To do this, I have created position data using the FINDGEN function, and modified it to get the correct spacing and correct range. This data set, call it t, is also strictly increasing.

When I run the spline function:

> result = spline(x, y, t)

The result data is all undefined (-1.#IND0).

However, I can create garbage data following the procedure outlined in the Reference text, and it works just fine. I have also taken one step farther and created a gaussian curve, added random noise, and further refined that data with the same function call and it works fine.

This is probably an obvious problem, but it's frustrating! Any ideas??