https://github.com/markmbaum/basicinterpolators.jl
Basic (+chebyshev) interpolation recipes in Julia
https://github.com/markmbaum/basicinterpolators.jl
chebyshev interpolation
Last synced: 11 months ago
JSON representation
Basic (+chebyshev) interpolation recipes in Julia
- Host: GitHub
- URL: https://github.com/markmbaum/basicinterpolators.jl
- Owner: markmbaum
- License: mit
- Created: 2021-03-01T18:26:19.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2023-04-15T12:40:22.000Z (over 3 years ago)
- Last Synced: 2025-08-21T01:54:28.337Z (11 months ago)
- Topics: chebyshev, interpolation
- Language: Julia
- Homepage:
- Size: 409 KB
- Stars: 32
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# BasicInterpolators.jl

*Interpolation methods with a simple interface*
*contributions welcome*
| Documentation | Status |
| :-----------: | :----: |
| [](https://markmbaum.github.io/BasicInterpolators.jl/dev) | [](https://github.com/markmbaum/BasicInterpolators.jl/actions) [](https://codecov.io/gh/markmbaum/BasicInterpolators.jl) |
Use Julia's package manager to install
```
julia> ]add BasicInterpolators
```
-----
### Interpolation Methods
##### One Dimension
- [x] linear
- [x] piecewise cubic
- [x] cubic spline (natural or clamped)
- [x] Chebyshev
- [x] arbitrary order polynomials (Neville's method)
- [x] polynomial coefficients (efficient Vandermonde solver)
- [x] end-point cubic Hermite
##### Two Dimensions, Regular Grid
- [x] linear
- [x] piecewise cubic
- [x] Chebyshev
##### N-Dimensions, Scattered Points
- [x] radial basis functions (any choice of function)
- [x] Shepard
-----
### Basic Usage
See the [**tutorial**](https://markmbaum.github.io/BasicInterpolators.jl/dev/tutorial/) for more complete examples.
```julia
using BasicInterpolators, ForwardDiff
#some data to interpolate
x = [-1, 0.5, 2, 3]
y = [1, 3, -0.5, 0]
#a linear interpolation struct
p = LinearInterpolator(x, y)
#interpolate at one point
p(2.5)
#interpolate at lots of points
p.(LinRange(-1, 3, 100))
#compute the derivative dy/dx
ForwardDiff.derivative(p, 1.0)
#make an interpolator that doesn't check boundaries (allows extrapolation)
p = LinearInterpolator(x, y, NoBoundaries())
```
-----
### Other packages
Some notable packages with other/advanced methods:
1. [Interpolations.jl](https://github.com/JuliaMath/Interpolations.jl)
2. [Dierckx.jl](https://github.com/kbarbary/Dierckx.jl)
3. [GridInterpolations.jl](https://github.com/sisl/GridInterpolations.jl)
4. [ApproXD.jl](https://github.com/floswald/ApproXD.jl)
5. [FastChebInterp.jl](https://github.com/stevengj/FastChebInterp.jl)
6. [ApproxFun.jl](https://github.com/JuliaApproximation/ApproxFun.jl)
For a longer list, look [here](https://github.com/JuliaMath/Interpolations.jl#other-interpolation-packages).