DiscreteApprox

DiscreteApprox(julia_obj)

Rational approximation on a discrete point set.

Represents a rational function approximation computed on a discrete set of points in the complex plane. The approximation is constructed adaptively using methods like AAA or TCF.

Attributes

Name Type Description
julia The underlying Julia DiscreteApproximation object.
data The discrete data points and values.
domain The discrete point set (numpy array).
fun The rational function approximation (Thiele, Bary, etc.).
test_index Indices of points used for testing.
allowed Allowed pole locations.
history History of the approximation process.
status ConvergenceStatus saying why the iteration stopped, or None if none was recorded.

Methods

Name Description
getfunction Get the underlying rational function.
isapprox Check if this approximation is close to another function.
nodes Get the interpolation nodes of the approximation.
testpoints Get the test points used to validate the approximation.
values Get the function values at the interpolation nodes.

getfunction

DiscreteApprox.getfunction()

Get the underlying rational function.

Returns

Name Type Description
Thiele, Bary, or JuliaRatfun: The rational function approximation.

isapprox

DiscreteApprox.isapprox(other)

Check if this approximation is close to another function.

Parameters

Name Type Description Default
other Another JuliaApprox or callable function. required

Returns

Name Type Description
bool True if approximations are close on all domain points.

nodes

DiscreteApprox.nodes()

Get the interpolation nodes of the approximation.

Returns

Name Type Description
np.ndarray: Array of node locations.

testpoints

DiscreteApprox.testpoints()

Get the test points used to validate the approximation.

Returns

Name Type Description
np.ndarray: Array of test point locations from the domain.

values

DiscreteApprox.values()

Get the function values at the interpolation nodes.

Returns

Name Type Description
np.ndarray: Array of function values.