1
$\begingroup$

I recently came across an "interpolation" scheme of the form $$ P_1\frac{(1-x)^3}{6} + P_2\left(\frac{x^3}{2} - x^2 + \frac{2}{3}\right) + P_3 \left(-\frac{x^3}{2} + \frac{x^2}{2} + \frac{x}{2} + \frac{1}{6}\right) + P_4 \frac{x^3}{6} $$ where $0 < x < 1$ is the interpolation weight and the $P_n$ appear to be evenly-spaced points.

I put "interpolation" because the curve does not necessarily pass through any of the points at $0$ or $1$, nor is it guaranteed to pass through $P_1$ or $P_4$ in that interval. Other notable properties are that it is monotone on $0 < x < 1$ if the $P_n$ are and it is symmetric under the transform $x\rightarrow 1-x, P_1 \leftrightarrow P_4, P_2 \leftrightarrow P_3$.

I'm trying to figure out two things. First, is this a known interpolation scheme? It has some apparent similarity to Bezier curves, but it's not the same. Second, why would this scheme be chosen over one that actually passes through the points?

$\endgroup$
3
  • $\begingroup$ What's the context where this scheme was found? Seems like it is set up for a specific usage, perhaps a "sophisticated" regression idea.. $\endgroup$
    – abiessu
    Commented Sep 10, 2021 at 14:45
  • 1
    $\begingroup$ @abiessu Moving the camera around during cutscenes in a video game. $\endgroup$ Commented Sep 10, 2021 at 15:08
  • $\begingroup$ So maybe the usage is to create the feel of moving the camera smoothly through the listed points, even if the camera doesn't actually land exactly in the specific locations... $\endgroup$
    – abiessu
    Commented Sep 10, 2021 at 17:18

1 Answer 1

2
$\begingroup$

I believe this is the so-called uniform cubic B-spline curve, which is a regular cubic B-spline curve with uniform knot sequence. However, the 3rd basis function associated with $P_3$ should be $(-3x^3+3x^2+3x+1)/6$.

The special property for uniform cubic B-spline curve is that the cubic segment defined by $P_1, P_2, P_3$ and $P_4$ will have $C^2$ continuity with the cubic segment defined by $P_2, P_3, P_4$ and $P_5$ at a common point $Q=(P_2+4P_3+P_4)/6$. So, basically you can use $N$ control points to define a curve of $(N-3)$ cubic segments, which are joined in a $C^2$ manner.

$\endgroup$
1
  • $\begingroup$ Ah, so it is. Thanks. And yes, I did copy the sign of the 1/6 wrong. $\endgroup$ Commented Sep 13, 2021 at 12:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .