diff --git a/dev/.documenter-siteinfo.json b/dev/.documenter-siteinfo.json index 502f038..ba81eea 100644 --- a/dev/.documenter-siteinfo.json +++ b/dev/.documenter-siteinfo.json @@ -1 +1 @@ -{"documenter":{"julia_version":"1.10.3","generation_timestamp":"2024-05-30T09:29:57","documenter_version":"1.4.1"}} \ No newline at end of file +{"documenter":{"julia_version":"1.10.3","generation_timestamp":"2024-06-02T09:22:48","documenter_version":"1.4.1"}} \ No newline at end of file diff --git a/dev/api/index.html b/dev/api/index.html index 8a8d6c6..0025fa1 100644 --- a/dev/api/index.html +++ b/dev/api/index.html @@ -1,9 +1,9 @@ -API · IntervalRootFinding.jl

API

Main interface

IntervalRootFinding.branch_and_pruneMethod
branch_and_prune(X, contractor, search_order, tol)

Generic branch and prune routine for finding isolated roots using the given contractor to determine the status of a given box X.

See the documentation of the roots function for explanation of the other arguments.

source
Polynomials.rootsMethod
roots(f, X, contractor=Newton, search_order=BreadthFirst, tol=1e-15)
+API · IntervalRootFinding.jl

API

Main interface

IntervalRootFinding.branch_and_pruneMethod
branch_and_prune(X, contractor, search_order, tol)

Generic branch and prune routine for finding isolated roots using the given contractor to determine the status of a given box X.

See the documentation of the roots function for explanation of the other arguments.

source
Polynomials.rootsMethod
roots(f, X, contractor=Newton, search_order=BreadthFirst, tol=1e-15)
 roots(f, deriv, X, contractor=Newton, search_order=BreadthFirst, tol=1e-15)
 roots(f, X, contractor, tol)
-roots(f, deriv, X, contractor, tol)

Uses a generic branch and prune routine to find in principle all isolated roots of a function f:R^n → R^n in a region X, if the number of roots is finite.

Inputs:

  • f: function whose roots will be found
  • X: Interval or IntervalBox in which roots are searched
  • contractor: function that, when applied to the function f, determines the status of a given box X. It returns the new box and a symbol indicating the status. Current possible values are Bisection, Newton and Krawczyk
  • deriv: explicit derivative of f for Newton and Krawczyk
  • search_order: SearchStrategy determining the order in which regions are processed.
  • tol: Absolute tolerance. If a region has a diameter smaller than tol, it is returned with status :unknown.
source

Root object

IntervalRootFinding.RootType
Root

Object representing a possible root inside a given region. The field status is either :unknown or :unique. If status is :unique then we know that there is a unique root of the function in question inside the given region.

Internally the status may also be :empty for region guaranteed to contain no root, however such Roots are discarded by default and thus never returned by the roots function.

Fields

  • interval: a region (either Interval of IntervalBox) searched for roots.
  • status: the status of the region, valid values are :empty, unknown and :unique.
source

Contractors

IntervalRootFinding.KrawczykType
Krawczyk{F, FP} <: AbstractContractor{F}

AbstractContractor type for the interval Krawczyk method.

Fields

- `f::F`: function whose roots are searched
+roots(f, deriv, X, contractor, tol)

Uses a generic branch and prune routine to find in principle all isolated roots of a function f:R^n → R^n in a region X, if the number of roots is finite.

Inputs:

  • f: function whose roots will be found
  • X: Interval or IntervalBox in which roots are searched
  • contractor: function that, when applied to the function f, determines the status of a given box X. It returns the new box and a symbol indicating the status. Current possible values are Bisection, Newton and Krawczyk
  • deriv: explicit derivative of f for Newton and Krawczyk
  • search_order: SearchStrategy determining the order in which regions are processed.
  • tol: Absolute tolerance. If a region has a diameter smaller than tol, it is returned with status :unknown.
source

Root object

IntervalRootFinding.RootType
Root

Object representing a possible root inside a given region. The field status is either :unknown or :unique. If status is :unique then we know that there is a unique root of the function in question inside the given region.

Internally the status may also be :empty for region guaranteed to contain no root, however such Roots are discarded by default and thus never returned by the roots function.

Fields

  • interval: a region (either Interval of IntervalBox) searched for roots.
  • status: the status of the region, valid values are :empty, unknown and :unique.
source

Contractors

IntervalRootFinding.KrawczykType
Krawczyk{F, FP} <: AbstractContractor{F}

AbstractContractor type for the interval Krawczyk method.

Fields

- `f::F`: function whose roots are searched
 - `f::FP`: derivative or jacobian of `f`

(K::Krawczyk)(X ; α=where_bisect)

Contract an interval X using Krawczyk operator and return the contracted interval together with its status.

Inputs

- `R`: Root object containing the interval to contract.
-- `α`: Point of bisection of intervals.
source
IntervalRootFinding.NewtonType
Newton{F, FP} <: AbstractContractor{F}

AbstractContractor type for the interval Newton method.

Fields

- `f::F`: function whose roots are searched
+- `α`: Point of bisection of intervals.
source
IntervalRootFinding.NewtonType
Newton{F, FP} <: AbstractContractor{F}

AbstractContractor type for the interval Newton method.

Fields

- `f::F`: function whose roots are searched
 - `f::FP`: derivative or jacobian of `f`

(N::Newton)(X, α=where_bisect)

Contract an interval X using Newton operator and return the contracted interval together with its status.

Inputs

- `R`: Root object containing the interval to contract.
-- `α`: Point of bisection of intervals.
source
IntervalRootFinding.refineMethod
refine(op, X::Tuple{Symbol, Region}, tol)

Wrap the refine method to leave unchanged intervals that are not guaranteed to contain an unique solution.

source
IntervalRootFinding.refineMethod
refine(C, X::Region, tol)

Refine a interval known to contain a solution.

This function assumes that it is already known that X contains a unique root.

source

Branch-and-bound search interface

Others

IntervalRootFinding.gauss_seidel_interval!Method

Iteratively solves the system of interval linear equations and returns the solution set. Uses the Gauss-Seidel method (Hansen-Sengupta version) to solve the system. Keyword precondition to turn preconditioning off. Eldon Hansen and G. William Walster : Global Optimization Using Interval Analysis - Chapter 5 - Page 115

source
IntervalRootFinding.newton1dMethod

newton1d performs the interval Newton method on the given function f with its derivative f′ and initial interval x. Optional keyword arguments give the tolerances reltol and abstol. reltol is the tolerance on the relative error whereas abstol is the tolerance on |f(X)|, and a debug boolean argument that prints out diagnostic information.

source
IntervalRootFinding.newton1dMethod

newton1d performs the interval Newton method on the given function f and initial interval x. Optional keyword arguments give the tolerances reltol and abstol. reltol is the tolerance on the relative error whereas abstol is the tolerance on |f(X)|, and a debug boolean argument that prints out diagnostic information.

source
IntervalRootFinding.quadratic_rootsMethod

Function to solve a quadratic equation where the coefficients are intervals. Returns an array of intervals of the roots. Arguments a, b and c are interval coefficients of , x and 1 respectively. The interval case differs from the non-interval case in that there might be three disjoint interval roots. In the third case, one interval root extends to −∞ and another extends to +∞. This algorithm finds the set of points where F.lo(x) ≥ 0 and the set of points where F.hi(x) ≤ 0 and takes the intersection of these two sets. Eldon Hansen and G. William Walster : Global Optimization Using Interval Analysis - Chapter 8

source
+- `α`: Point of bisection of intervals.
source
IntervalRootFinding.refineMethod
refine(op, X::Tuple{Symbol, Region}, tol)

Wrap the refine method to leave unchanged intervals that are not guaranteed to contain an unique solution.

source
IntervalRootFinding.refineMethod
refine(C, X::Region, tol)

Refine a interval known to contain a solution.

This function assumes that it is already known that X contains a unique root.

source

Branch-and-bound search interface

Others

IntervalRootFinding.gauss_seidel_interval!Method

Iteratively solves the system of interval linear equations and returns the solution set. Uses the Gauss-Seidel method (Hansen-Sengupta version) to solve the system. Keyword precondition to turn preconditioning off. Eldon Hansen and G. William Walster : Global Optimization Using Interval Analysis - Chapter 5 - Page 115

source
IntervalRootFinding.newton1dMethod

newton1d performs the interval Newton method on the given function f with its derivative f′ and initial interval x. Optional keyword arguments give the tolerances reltol and abstol. reltol is the tolerance on the relative error whereas abstol is the tolerance on |f(X)|, and a debug boolean argument that prints out diagnostic information.

source
IntervalRootFinding.newton1dMethod

newton1d performs the interval Newton method on the given function f and initial interval x. Optional keyword arguments give the tolerances reltol and abstol. reltol is the tolerance on the relative error whereas abstol is the tolerance on |f(X)|, and a debug boolean argument that prints out diagnostic information.

source
IntervalRootFinding.quadratic_rootsMethod

Function to solve a quadratic equation where the coefficients are intervals. Returns an array of intervals of the roots. Arguments a, b and c are interval coefficients of , x and 1 respectively. The interval case differs from the non-interval case in that there might be three disjoint interval roots. In the third case, one interval root extends to −∞ and another extends to +∞. This algorithm finds the set of points where F.lo(x) ≥ 0 and the set of points where F.hi(x) ≤ 0 and takes the intersection of these two sets. Eldon Hansen and G. William Walster : Global Optimization Using Interval Analysis - Chapter 8

source
diff --git a/dev/biblio/index.html b/dev/biblio/index.html index b9788c2..d4320b5 100644 --- a/dev/biblio/index.html +++ b/dev/biblio/index.html @@ -1,2 +1,2 @@ -Bibliography · IntervalRootFinding.jl

Bibliography

  • Applied Interval Analysis, L. Jaulin, M. Kieffer, O. Didrit & E. Walter. Springer (2001)
  • Global Optimization Using Interval Analysis: Revised And Expanded, E. Hansen & G.W. Walster. CRC Press (2003)
  • Introduction to Interval Analysis, R.E. Moore, R.B. Kearfott & M.J. Cloud. SIAM (2009)
  • Validated Numerics: A Short Introduction to Rigorous Computations, W. Tucker. Princeton University Press (2010)
+Bibliography · IntervalRootFinding.jl

Bibliography

  • Applied Interval Analysis, L. Jaulin, M. Kieffer, O. Didrit & E. Walter. Springer (2001)
  • Global Optimization Using Interval Analysis: Revised And Expanded, E. Hansen & G.W. Walster. CRC Press (2003)
  • Introduction to Interval Analysis, R.E. Moore, R.B. Kearfott & M.J. Cloud. SIAM (2009)
  • Validated Numerics: A Short Introduction to Rigorous Computations, W. Tucker. Princeton University Press (2010)
diff --git a/dev/index.html b/dev/index.html index 30c521d..d49eb6d 100644 --- a/dev/index.html +++ b/dev/index.html @@ -47,4 +47,4 @@ using Plots; plotlyjs() surface(-5:0.1:6, -6:0.1:6, (x,y) -> f([x, y])) -scatter!(xs, ys, f.(midpoints))

The result is the following:

stationary points

+scatter!(xs, ys, f.(midpoints))

The result is the following:

stationary points

diff --git a/dev/internals/index.html b/dev/internals/index.html index 980335d..ed04b89 100644 --- a/dev/internals/index.html +++ b/dev/internals/index.html @@ -49,4 +49,4 @@ ⋮ # several lines omitted for brevity The tree at iteration 17 has 10 nodes The tree at iteration 18 has 9 nodes -The tree at iteration 19 has 9 nodes +The tree at iteration 19 has 9 nodes diff --git a/dev/roots/index.html b/dev/roots/index.html index 64aa484..b2804e8 100644 --- a/dev/roots/index.html +++ b/dev/roots/index.html @@ -80,4 +80,4 @@ 3-element Array{Root{Interval{Float64}},1}: Root([0.107541, 0.165989], :unknown) Root([0.283803, 0.3555], :unknown) - Root([0.0499999, 0.107542], :unknown)

The last example shows a case where the tolerance was too large to be able to isolate the roots in distinct regions.

Warning

For a root x of some function, if the absolute tolerance is smaller than eps(x) i.e. if tol + x == x, roots may never be able to converge to the required tolerance and the function may get stuck in an infinite loop.

+ Root([0.0499999, 0.107542], :unknown)

The last example shows a case where the tolerance was too large to be able to isolate the roots in distinct regions.

Warning

For a root x of some function, if the absolute tolerance is smaller than eps(x) i.e. if tol + x == x, roots may never be able to converge to the required tolerance and the function may get stuck in an infinite loop.