Interpolation is the process of estimating the values of a function, when the function's values are known only at a particular set of points. Questions on interpolation in one or more dimensions, as well as algorithms for doing so, should have this tag.

learn more… | top users | synonyms

1
vote
0answers
33 views

Comparison between of higher order interpolations

A while ago I came up with an algorithm which can be used to numerically solve optimal control problems, which basically came down to discretizing the control input $u(t)$ and interpolating this to ...
2
votes
0answers
93 views

Diffrence between moving least square and weighted least square in interpolation

Could you explain exact difference between moving least square (MLS) and weighted least square (WLS). I personally feel that moving least square is a sub case of weighted least square. My ...
2
votes
1answer
50 views

Generating harmonic polynomials in cartesian coordinates

TLDR: Are these polynomials really harmonic polynomials, and how can I generate them? Long version: I want to describe an electrostatic potential $\Phi(x,y,z)$ over a source-free volume, by using ...
1
vote
1answer
34 views

Interpolation using compactly supported radial basis function

I have been struggling for two days with the following problem. I would like to do a $d$-dimensional interpolation over some data. I tried first to use polyharmonic splines, but when the size of data ...
1
vote
1answer
56 views

How to update velocity to include pressure when using P2/P1 elements

I am in the process of writing a finite element code to solve the Navier-Stokes equations using the theta method for time stepping (basically Crank-Nicholson for diffusion and forward Euler for ...
2
votes
1answer
80 views

Is my Restricted (Natural) Cubic Spline equation wrong?

I am trying to fit a restricted cubic spline (natural cubic spline) with 4 knots to toy data, attempting to follow Hastie, Tibshirani, Friedman 2nd ed. 5.2.1 p.144-146, Eqs 5.4 and 5.5. Data: Is ...
0
votes
0answers
41 views

Gauss Integration over Zero Order Element

I'm working with the Boundary Element Method and want to integrate an expression over a triangular region. I would like to use Gauss Integration to do this, but I'm having trouble since the triangular ...
1
vote
0answers
21 views

Anybody using kriging for surface interpolation from huge point datasets? [closed]

Is anybody here using kriging for surface interpolation from huge datasets (> 1 million points)? How large datasets are your datasets and what do you model? Also what software are you using?
2
votes
1answer
135 views

L2-Projection using quadratic basis functions

I am trying to understand 1D $L^2$-projections using quadratic basis functions. Using 3 data points, and the Lagrange polynomial it is easy enough to see how to write out 3 basis functions. With the ...
4
votes
1answer
402 views

What is the preferred and efficient approach for interpolating multidimensional data?

What is the preferred and efficient approach for interpolating multidimensional data? Things I'm worried about: performance and memory for construction, single/batch evaluation handling dimensions ...
1
vote
1answer
58 views

What are good parametrizations of rational functions for response surface models?

For fitting a response surface model to a physical process, I have 3-4 relevant "signals", like a feature density, a signal based on a feature width, or a signal based on a distance to the next ...
0
votes
1answer
88 views

Interpolating 3D Array non-monotonic data in MatLab

I am working on creating a program for simulations where three variables are parametrized, and we modify one parameter while keeping the other two constant. An example array looks like this when ...
0
votes
0answers
20 views

Is there a standard for determining the accuracy of a polygon interpolation technique?

I'm looking into polygon interpolation, and was curious if there are any standards for determining the accuracy of polygon interpolation techniques. I've been looking through papers and lecturers ...
0
votes
1answer
59 views

How to present a polynomial interpolation if the first order information of function f(x) is given?

Suppose $f'(x_1),\ f'(x_2),\ f'(x_3)$ are given, how to give a polynomial interpolation $p(x)$ such that $p'(x_1)= f'(x_1),\ p'(x_2)=f'(x_2),\ p'(x_3)=f'(x_3)$? And how to give an error analysis?
2
votes
1answer
93 views

Error of interpolating polynomial

$f(x)= \frac{1}{1+x^2}$ and when I computed the interpolating polynomial of 5 equally spaced points in [-5,5] I got $ p(x)= 0.0053x^4 -0.1711x^2 +1$ Now I need to estimate the error in the ...
0
votes
0answers
24 views

Find the period of the function

My question is as follows:- Find the trigonometric interpolant $ \bar{f}(x)$ for $f(x)= \frac{\pi}{x+3\pi}$ and $n=1$. Thant is, find coefficients $c_{-1}, c_0 ,c_1$ such that ...
1
vote
1answer
725 views

Plot a surface from data sets in MATLAB

I tried to plot a surface in MATLAB but, since it is the first time I had to do something like this, I need a confirmation on the process I followed because it is important for my project to plot the ...
0
votes
0answers
16 views

Convergence criterion for overset grids

If there are two overset grids, how do you decide whether convergence is reached or not? What I did was, after interpolating from one grid to another, I check the rms of conservative variables and if ...
2
votes
1answer
661 views

Is there a Gauss-Laguerre integration routine in Python?

I am reading the book "Numerical Recipes in Fortran 77: The Art of Scientific Computing" (Second Edition) and I came across some methods for numerical integration of 1D functions. More specifically ...
5
votes
1answer
104 views

What spline functions are used in Section 13.9 of “Numerical Recipes in C”?

I asked a similar question on MathSE but with more added fluff, but didn't really get any straight answers, so I figured I'd ask here. Computing Fourier coefficients of a function using the FFT is ...
0
votes
0answers
48 views

Interpolation using two chebyshev grid points

I want to do the interpolation on a interval. I can do it using with one chebyshev grid points, but i want to do it using two chebyshev grids on each half of this interval. I can do it separately for ...
1
vote
1answer
154 views

How to minimize the artefact of a cartesian to polar transform followed by a polar to cartesian transform?

I'm transforming cartesian images into polar images. (x,y) => (angle, radius) I fill the polar image by iterating on each of its pixels and filling them by doing the reverse polar transform. For a ...
0
votes
0answers
216 views

Fast way to compute barycentric lagrange interpolation

Is there any fast way to compute the barycentric Lagrange interpolation using matlab? something more faster than using repmat instead of for loops
2
votes
2answers
172 views

Interpolating irregular data on a sphere

I am trying to interpolate irregular data $f(\theta, \phi)$ on a sphere and I have so far tried a scipy approach using Kd-Trees and inverse distance weighting, which works ok - however I was wondering ...
1
vote
0answers
74 views

NURBS surface fitting for a closed region on mesh

I'm developing a tool that allows users to select a closed boundary (a polygon) on the triangle mesh and then from this boundary, generate a NURBS surface fitting the original mesh surface. My idea ...
0
votes
1answer
41 views

interpolating a periodic time series

I have a bunch of readings that run every 4 hours, however each sensor has a different offset. One sensor might read at $t = 0,4,8,12,16,20$ and another senor reads at $t = 1,5,9,13,17,21$. This ...
1
vote
1answer
316 views

How do I integrate this function in python?

Essentially this is the problem: $\hat{F}(\omega) = \int_0^{\infty} f(s)e^{-i\omega s}ds$ The function $f$ is in general complex valued. I know this looks like the fourier transform but I don't want ...
4
votes
2answers
61 views

Fitting a surface to scalar functions given on the edges of a triangulation

Given a triangle mesh $\mathcal{T}$ with vertices $V=\{\mathbf{v}_i\}_{i=1}^n$ in $\mathbb{R}^3$ and triangles $T_{ijk}=[\mathbf{v}_i, \mathbf{v}_j, \mathbf{v}_k]$. For each vertex $\mathbf{v}_i$, I ...
8
votes
1answer
478 views

Help deciding between cubic and quadratic interpolation in line search

I'm performing a line search as part of a quasi-Newton BFGS algorithm. In one step of the line search I use a cubic interpolation to move closer to the local minimizer. Let $f : R \rightarrow R, f ...
0
votes
0answers
28 views

Mass-conservative reprojection (on a sphere)

I have a 2D distribution of mass on a sphere given as a matrix of masses in latitude-longitude grid cells. I need these masses projected to another grid on the same sphere with different location of ...
4
votes
2answers
465 views

Interpolation by Solving a Minimization Problem (Optimization)

I will try to give the motivation behind this problem and later the math formality. Given a grayscale image (1 Channel - M by N Matrix). Someone marks some pixels as anchors. Now, you need to ...
5
votes
0answers
105 views

Integrating highly oscillatory functions

I have a logarithmic grid, upon which i have two functions that are similar to this one (this is only the last 100 points): These are essentially very similar to a Sin function at this point. I ...
2
votes
1answer
106 views

How do I do Chebyshev interpolation in multi-dimentional space?

This topic is used in spectral methods, for collocation grid. Literature mentions Chebyshev interpolation on a grid (defined by $\xi_j = cos(\pi \cdot j/N)$, $x_j = (\xi_j+1) L/2$, $j=0,...,N$) ...
4
votes
0answers
74 views

How do I perform chebyshev interpolation from a to b with custom angle range?

Typically Chebyshev interpolation from $-1$ to $1$ with angle from $0$ to $\pi$: $\xi_j=\cos \left ({\pi j \over N}\right )$ $x_j=(1+\xi_j) * {L \over 2}$ $w$: $w_0=\pi/(2N)$ ...
4
votes
1answer
2k views

Fortran, making a more efficient bilinear interpolation

I'm trying to write an efficient bilinear (2D)-interpolation, after reading some recipes, as a fortran-mex for Matlab that is used extensively throughout a long algorithm of solar image processing, ...
5
votes
1answer
166 views

Adaptive Table Lookup for Expensive Function Evaluation

I have a function that is expensive to evaluate whose inputs are n-dimensional (n is the order of a dozen or two). I need the output of this function at each node and each time step for a PDE ...
1
vote
1answer
419 views

Newton's method in interpolation

I've seen that in Newton's method for interpolating polynomials, the coefficients can be found algorithmically using (in Python-ish): ...
2
votes
1answer
3k views

How does Matlab's “interp2” compute bicubic interpolation?

Computational Science people: The title is the question: exactly how does Matlab's "interp2" command (with the "cubic" option) perform bicubic interpolation? I tried the Mathworks documentation ...
5
votes
2answers
126 views

Continuation procedure to solve for a 2D curve that satisfies f(x,y) = 0

I have some function of $R^2$, that must be numerically computed. For instance, I might be interested in a real-valued contour integral that begins from (x,y) = 0. $$ f(x,y) = \Re\left[\int_0^{x + ...
1
vote
1answer
33 views

Adding data with different abscissas

This question may be better suited for an Astronomy Stack Exchange site, but I figured I'd ask here. Say I have measurements of something as a function of radius for a number of objects. Here's an ...
4
votes
1answer
107 views

Surface interpolation from two lines

Sorry if this is a basic problem but I don't know where to start looking (mainly because being an outsider I don't know the terms and nomenclature). Imagine two perpendicular lines ("profiles") in a ...
6
votes
1answer
158 views

Full Multigrid Prolongation Operator

I am looking into full multigrid, FMG, and several sources, including these slides, that a lot of people are referring to, state that the prolongation operator used in FMG the first time you visit a ...
2
votes
0answers
81 views

How do I implement thin plate splines with barriers?

I want to implement thin spline interpolation of scattered elevation data $ \{z_i(x_i,y_i)\}_{i=1..n} $ in C++. This seems fairly simple using Radial Basis Functions: $$ z(x,y) = p(x,y) + \sum_i ...
7
votes
2answers
470 views

Do RBF kernel matrices tend to be ill-conditioned?

I use RBF kernel function to implement one kernel based machine learning algorithm(KLPP), the resulting kernel matrix $K$ $$K(i,j)= \exp\left({\frac{-(x_{i}-x_{j})^2}{ \sigma_{m}^2}}\right)$$ is ...
5
votes
2answers
681 views

Intermediate values (interpolation) after Runge-Kutta calculation

I have a numerical ODE simulation that I computed at fixed time step $h$ using a 4-th order Runge-Kutta method (RK4), producing a series of results $(x_1,y_1), ...
1
vote
0answers
24 views

Combining trend estimation and constrained Marquart fit

This title certainly needs some clarification: I need to compute parameters $a_i$ for a helper function $f(\vec{a};k)$ (for grid interpolation) which is fitted to a number of values $y_k$ which are ...
3
votes
1answer
581 views

Minimal surface solution in Python

Note: this question was also posted in StackOverflow and math.stackexchange. I have a set of 3D points defining a 3D contour, as shown below. The points in this contour lie in their best-fit plane ...
3
votes
2answers
291 views

How to properly use polynomial projection to get values at visualization nodes?

I am trying to implementing a nodal discontinuous Galerkin spectral element method for linear and non-linear systems of equations. The solution at each time step is given at ...
5
votes
2answers
3k views

SciPy interpolation with Univariate Splines

I have coded a routine for interpolation with B-splines, only to discover later that this functionality is already included in Python's SciPy. However, I do not understand one parameter in the SciPy ...
17
votes
2answers
456 views

Why do equi-spaced points behave badly?

Description of experiment: In Lagrange interpolation, the exact equation is sampled at $N$ points (polynomial order $N - 1$) and it is interpolated at 101 points. Here $N$ is varied from 2 to 64. ...