I wanted to use Monotone cubic interpolation, but the site only provide explanation for 2D case. How can I extend it to 3D?
Asked
Active
Viewed 499 times
3
-
Do you mean that you have a set of 3D control points, C0, C1...Cn, and, I assume, some rotation matrix, P, such that, (P.Ci) [x] is strictly increasing, as are (P.Ci) [y] and (P.Ci) [z] ? – Simon F Apr 24 '17 at 11:56
-
No, i mean in 3D a point is defined by (x, y, z) instead of (x, y). – Bla... Apr 24 '17 at 12:04
-
Your question is ambiguous as you don't specify monotonic in relation to what in 3D? – JarkkoL Apr 25 '17 at 13:10
-
@JarkkoL You need to check the link that I provided. – Bla... Apr 25 '17 at 15:27
-
It doesn't disambiguate how you want the function to be monotonic in 3D. If you want the function to be monotonic along y-axis like in the 2D case, it's trivial extension, but if you want it to be monotonic along each axis, it's different. So which is it? Please clarify your question. – JarkkoL Apr 25 '17 at 15:58
-
@JarkkoL Oh, I see.. How can you tell that the function in the site is monotonic along y-axis only? I think the important step is "Compute the slopes of the secant lines between successive points:", but the site only provide the 2D case. I think if I can extend that to 3D than the rest are the same. Am I right? – Bla... Apr 26 '17 at 01:42
1 Answers
4
Ok, monotonic interpolation depends on what you are monotonic about. For a simple 1D function interpolation monotonicity is easy to define. But for a 2D and 3D dataset its not so self evident what the situation would be.
First you could interpolate along a independent variable t in which case your monotonicity is most probably in relation to t. This is the same as interpolating each direction separately.
Second you could interpolate along one of the axes, so that your interpolant becomes a function of position on that axis. Reducing a 2D case into a 1D case and a 3D case to two separate 2D cases.
Third you could interpolate on some other spatial variable.
So you see the question is a bit open ended and is hard to say for sure.

joojaa
- 8,437
- 1
- 24
- 47
-
1In the link provided above it's Monotone cubic Hermite interpolation. The idea is to maintain the direction of tangent vectors. Any idea how to extend it for 3D case? – Bla... Jul 05 '17 at 06:40
-
@Bla... So you dont actually want a monotone curve at all then? As you ar not defining what your going to be monotone about. Try a catmul-rom spline. – joojaa Jul 05 '17 at 06:52