Questions on the spline-related functions of Mathematica (BezierCurve[], BSplineCurve[], etc.).

learn more… | top users | synonyms

5
votes
1answer
56 views

How to use BSplineFunction for calculating derivative

I have a set of data like the following data = {{x1,y1},{x2,y2},{x3,y3},......} Now I use ...
4
votes
1answer
67 views

More efficient method to implement knots instertion algorithm

Knots instertion algorithm of B-spline About the definition of B-spline, please see here. Suppose $\overline u \in [u_{k},u_{k+1})$initially has multiplicity $s$, and suppose it is to be inserted ...
6
votes
0answers
61 views

Artefact at joints within BSplineCurve of low Opacity

I want to eliminate the dots of higher opacity that occur at the joints within a BSplineCurve of low opacity. Small rectangles of greater opacity, shown below, ...
1
vote
2answers
74 views

Creating B-splines using a For Loop

I'm very new to Mathematica (as will make itself clear with this question) and I'm trying to create a program that makes b-splines to fit n points. I'm not quite sure how to reference the i-th point ...
8
votes
1answer
157 views

How to discretize a BezierCurve?

Bug introduced in version 10.0 and persisting through 10.3 DiscretizeGraphics is new in 10.0. I need to create a discretized region from a ...
1
vote
1answer
51 views

Different results with BSplineSurface and BSplineFunction [closed]

There seems to be some differences when plotting a surface with BSplineSurface and with BSplineFunction. ...
4
votes
1answer
90 views

How to get coordinate from spline interpolation

Hi, I would like to find 10 coordinates between each points of this spline interpolation. I have done some research, but cannot find an appropriate answer. Any help will be appreciated. ...
15
votes
2answers
449 views

How to generate a closed B-spline curve?

I wrote a function called deBoor using the Cox-de Boor algorithm to generate a B-spline curve. ...
0
votes
0answers
39 views

How do I change a 3d bspline curve to a polygon based graphic? [duplicate]

I have a graphics image generated with bsplines: Graphics3D[Tube[BSplineCurve[pts], 2]] I want to export this to a .stl file. To do so I know I need to modify ...
7
votes
1answer
97 views

Where is the other half of my fourth degree Bézier curve?

Bug introduced in 10.0.0 and fixed in 10.2 When I enter the following command, half of the fourth-degree spline is missing from the graph (i.e. it doesn't touch the last point). Is this a bug in ...
0
votes
0answers
41 views

Working with Piecewise functions - Hexsplines

I'm trying to use the convolution definition of hexsplines, that is, a hexspline is the convolution of the indicator function of a hexagon (of sidelength 1 and centre $(0,0)$ ) with itself. I'm ...
11
votes
1answer
240 views

How to specify PDE Boundary condition on Bspline?

Context I would like to solve a PDE on a boundary which is parametrized as a BSpline. I am trying to solve the force-free Grad-Shafranov equation on a ...
2
votes
2answers
200 views
6
votes
2answers
190 views

What's the difference between Interpolation[pts, Method -> Spline] and BSplineCurve?

Last month, I answered a question about spline interpolation,please see here Now I do the following operations ...
0
votes
0answers
40 views

3D interpolation [duplicate]

I have four column data with first 3 column denoting x,y,z and fourth column energy. x variable is actually angle. Now I want to interpolate over all three indepdent variable (x,y.z) with ...
2
votes
1answer
172 views

Confusion with SplineFit (Angle calculation)

This question is continuation to this other one I am creating polymers (where each monomer is of equal length) using this method: ...
2
votes
1answer
68 views

Why are these methods giving me different results? (Trying to test SplineFit)

I am creating a polymer(where each monomer is of equal length) using this method: ...
2
votes
1answer
117 views

How to find if x-y point falls within a closed BSplineCurve

Here's a simple Manipulate with a closed BSplineCurve, and a Locator. ...
4
votes
1answer
125 views

Multidimensional arbitrary precision spline interpolation on the grid

This question is a generalization of the previous one for multiple dimensions. In the answer to that question an implementation for the clamped spline interpolation for 1D case and arbitrary degree of ...
11
votes
1answer
252 views

How can I make FilledCurve smoother?

In How can I generate and randomly assign color to annular sectors? J.M. showed an interesting way to create a sector graphic using FilledCurve. Unfortunately it ...
4
votes
3answers
446 views

How to find a length of a curve constructed using Spline?

By fitting the data using spline, I have created a curve. sp = SplineFit[data1, Cubic] I am trying to divide this curve into small segments of equal length. To ...
7
votes
0answers
92 views

Color Snapping When Using VertexColors with a Tube with BSplineCurve as an Argument

I think I've identified a bug in how VertexColors are treated when rendering a Tube object where the underlying data is a ...
6
votes
2answers
181 views

How do I get my spline based arrows to have rounded ends?

I would like to change the how the ends of the spline arrows in my figure are rendered to be "rounded", but ...
2
votes
1answer
185 views

How can I make a pretzel shape using Bézier curves?

I am trying to make a pretzel shape,but I cannot seem to get the loops even. Eventually, I need to make the pretzel shape loop in 3D so I need to nail the 2D concept first. Here's what I have so ...
3
votes
1answer
179 views

Failed to create a special random-disturbed initial condition for partial differential equation [closed]

I try to use BSplineFunction to creat a initial condition for NDSolve which has periodic boundary condition, that is realized by ...
2
votes
1answer
181 views

Interpolation of a NURBS curve

Known that NQ=P where N is the Bspline basis function, Q is the control point that we wish to locate, P is the data points given ( the curve must pass through it) is there any way to modify the "N" ...
3
votes
1answer
92 views

How to make the result of Piecewise be a closed interval?

Description This question comes from two questions. Namely Q1 and Q2 The defintion of B-Spline basis function as shown below: Let $\vec{U}=\{u_0,u_1,\ldots,u_m\}$ a nondecreasing sequence of real ...
1
vote
1answer
79 views

Bspline weights

I change weigts of my points, but nothing has changed. What should i do to solve this problem? ...
1
vote
1answer
81 views

BSplineSurface problem

Why does the result of this function is straight line.If problem is in the order of my points, what order is correct? ...
4
votes
1answer
199 views

Find GeometricTransform from 3D object external surfaces to a positional point cloud data

I am looking for another way to approach this problem. Any suggestion on how to optimize the computing speed is welcome. I have a BSplineFunction which accurately ...
2
votes
1answer
232 views

What extrapolation method does Interpolation use by default? [closed]

As far as I can tell, Interpolation uses cubic spline interpolation by default - please correct me if I'm wrong. What does it use for extrapolation outside of the ...
3
votes
2answers
263 views

Understanding polyharmonic splines

Rahul Narain and J.M. gives implementation of the thin plate polyharmonic splines in this post. Rahul Narain's method is clear. J.M.'s is convenient to reuse. But J.M. used too many ...
2
votes
3answers
162 views

BSpline or other curve through arbitrary ordered sequence of two-dimensional points

How does one create a BSplineCurve or other smooth curve passing through each point in an ordered list, where the curve may be non-simple, i.e., can double-back ...
6
votes
2answers
364 views

2D smoothing spline interpolation

Does Mathematica have 2D smoothing spline interpolation built in? I requires an interpolation method with smooth first derivatives and cubic bivariate splines fulfill this nicely. In python I would ...
10
votes
3answers
220 views

How to deal with the condition $u_i=u_{i+1}$ in B-Spline basis function?

The defintion of B-Spline basis function as shown below: Let $\vec{U}=\{u_0,u_1,\ldots,u_m\}$ a nondecreasing sequence of real numbers,i.e, $u_i\leq u_{i+1}\quad i=0,1,2\ldots m-1$ $$N_{i,0}(u)= ...
13
votes
1answer
848 views

Curve fit based on minimal data

Inspired by the fantastic answers here and here, I would like to ask a questions along similar lines. I have 6 curve types that follow these rules: Type A: If point 1 is positive and point 2 is ...
12
votes
5answers
550 views

Joining ordered set of points with splines in spiral

I have a collection of points ...
7
votes
2answers
408 views

How to create an adjustable Bézier curve?

I tried to create an adjustable Bézier curve with the following simple code. However the curve didn't show up. What is the problem? Please help. ...
2
votes
0answers
177 views

Exporting BSplineSurface to STL

I have encountered some difficulties getting BSplineSurface to export to STL. The following code works and generates a triangulated polygon mesh from the NURBS ...
2
votes
1answer
128 views

How to generate specific function using BSpline command/

I want to generate an approximation function that fits a curve to points. My goal is to obtain an actual formula. Is this possible with the BSpline function? Using the following code: ...
4
votes
2answers
417 views

How to get a uniformly distributed list of points from a B-spline function [duplicate]

I created a spline function from a list of points and made a plot as follows: ...
3
votes
1answer
139 views

How to color a BSplineSurface

I am trying to color a BSplineSurface in a complex way but not having any luck using ColorFunction. I can use ...
0
votes
1answer
175 views

How to fix problems solving for values of BSpline function?

I generated a spline function called f using the BSplineFunction with domain {t,0,1}. ...
0
votes
4answers
164 views

Minimization in single component of BSpline to extract points

I smoothed some data with a BSpline $B[t] = (x[t],y[t])$. I would like to extract certain points from this spline by their x-Values, $x_0$. The easiest way I came up with was to minimize ...
11
votes
3answers
855 views

Finding “Maxima” and “Minima” on a B-Spline

I need to find the "Maxima" and "Minima" on a B-Spline or more correct the points where the 2nd components of the derivate equal zero. For example: ...
2
votes
1answer
174 views

Problems with BSplineFunction vs. BSplineSurface

Why are those surfaces different? ...
1
vote
0answers
147 views

How to write my own interpolation method [duplicate]

I was comparing results of spline interpolation in Mathematica and C++/gsl-library Results of interpolation are different if I use ...
22
votes
4answers
824 views

Arbitrary precision spline interpolation

The current implementation of Interpolation does not allow arbitrary precision spline interpolation. Yu-Sung Chang says here that "it is not hard to implement it ...
1
vote
2answers
1k views

Cubic Splines Functions

I have this set of three data points and want the natural cubic spline functions for them: dat = {{-.0247500, .5}, {.3349375, -.25}, {1.101000, 0}}; I tried: ...
5
votes
2answers
477 views

Intersection of two splines

I have a collection of sets of points, each set defining the segment of a (nice) curve on the unit sphere $S^2 \subset \mathbb{R}^3$. The points are computed numerically. I now want to compute the ...