Interpolation
Functions
LUSE_ENGR701_704_NumericalMethods.Interpolations.bezier
— Methodbezier(x, y, xguides, yguides)
An application of Hermitic polynomials to draw Bezier curves between points.
Notes
Each argument should be a one-to-one mapping of points, (xᵢ, yᵢ) and (xᵢ₊₁, yᵢ₊₁) and their respective guide points, (xᵢ⁺, yᵢ⁺) and (xᵢ₊₁⁻, yᵢ₊₁⁻).
LUSE_ENGR701_704_NumericalMethods.Interpolations.clamped
— Methodclamped(x, f, fp)
The bookend polynomials will have the same slope entering and exiting the interval as the derivative at the respective endpoint.
LUSE_ENGR701_704_NumericalMethods.Interpolations.lagrange
— Methodlagrange(x, f[; n=nothing])
Given a domain, x
and range, f
, construct the n
th Lagrangian polynomial.
Notes
If n=nothing
, then method will utilize entire dataset. Polynomials will quickly oscillate for larger datasets.
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearinterpolation
— Methodlinearinterpolation(x0, y0, x1, y1, x)
$y = y₀ + (x - x₀)*(y₁ - y₀)/(x₁ - x₀)$
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearinterpolation
— Methodlinearinterpolation(x, y, p)
Calls linearinterpolation
with the first index in x
less than and greater than p
. If for any p
∈ x
, then the first occurrence in y
is returned.
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearleastsquares
— Methodlinearleastsquares(x, f, n::Int64)
Construct a polynomial of degree, n
while minimizing the least squares error.
Notes
Least squares error := $E = \sum_{i=1}^{m}[y_{i} - P_{n}(x_{i})]^{2}$
Constructed polynomial of the form: $P(x) = a_{n}x^{n} + a_{n - 1}x^{n - 1} + \dots + a_{1}x + a_{0}$
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearleastsquares
— Methodlinearleastsquares(x, f, type::Symbol)
Given a domain and range, yield the coefficients for an equation and the equation of the form $y = ax^{b}$.
LUSE_ENGR701_704_NumericalMethods.Interpolations.natural
— Methodnatural(x, f)
The bookend polynomials do not assume the slope entering and exiting the interval as the derivative at the respective endpoint.
LUSE_ENGR701_704_NumericalMethods.Interpolations.newtondifference
— Methodnewtondifference(x, f, α[; dir::Symbol=:auto])
Given a domain, x
and range, f
, construct some polynomial by Newton's Divided Difference centered around α
. :forward
or :backward
construction.
Notes
Direction will be chosen if not specified. Polynomials best made with even spacing in x
; although, this is not completely necessary.
Index
LUSE_ENGR701_704_NumericalMethods.Interpolations.bezier
LUSE_ENGR701_704_NumericalMethods.Interpolations.clamped
LUSE_ENGR701_704_NumericalMethods.Interpolations.lagrange
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearinterpolation
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearinterpolation
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearleastsquares
LUSE_ENGR701_704_NumericalMethods.Interpolations.linearleastsquares
LUSE_ENGR701_704_NumericalMethods.Interpolations.natural
LUSE_ENGR701_704_NumericalMethods.Interpolations.newtondifference