spline fitting with stiffness

Started by
1 comment, last by yapposai 17 years, 4 months ago
Hello, I am trying to make a sort of simulator for flexible hoses. The user inputs samples points/anchor points where the hose should pass and the program calculates the path of the hose. I am using cubic interpolation to make the a piecewise curve, however I am stumped as to how to add stiffness and diameter to the hose. A stiff/thick hose might not be able to bend as the interpolated spline. I would like to auto adjust the curve to fit the constraints or at the very least know if the path is not possible based on the diameter, stiffness. Is there a way to modify the cubic spline interpolation to take into account diameter and some sort of stiffness value? I was also thinking of not using splines but smaller line segments and max angle bend. stiffer hoses have longer subsegments and smaller max bends angle. Then I just try to get closer to the next anchor point within the max_bend angle. The problem with this is the bends will be concentrated at the start, which looks unnatural. Any help, suggestions will be much appreciated. Thanks.
---------------Magic is real, unless declared integer.- the collected sayings of Wiz Zumwalt
Advertisement
Given the possible non-existence of solutions, I'm not sure that splines are very well-suited to the problem. Certainly not in an analytical sense.

Perhaps you'd have more luck posing it as an extremal (variational) problem. If you set a constraint on the curvature of the hose (bounding the second derivative absolutely) while minimising the closest distance to each node, you'd be guaranteed a solution (not necessarily a unique one) and you have a host of numerical methods available to you. This would be a near-direct application of Euler-Lagrange. It doesn't exactly sound like a walk in the park though.

Regards
Admiral

Edit: Disappearing word.

[Edited by - TheAdmiral on November 27, 2006 6:52:11 AM]
Ring3 Circus - Diary of a programmer, journal of a hacker.
Yep, I don't think splines alone can cut this. Thanks for the suggestions, I'll look into them and see what I can come up with.
---------------Magic is real, unless declared integer.- the collected sayings of Wiz Zumwalt

This topic is closed to new replies.

Advertisement