Skip to content

Commit c019191

Browse files
committed
Add docs
1 parent df79819 commit c019191

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

src/algorithms.jl

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,16 @@ end
5656
@doc """
5757
select_algorithm(f, A; kwargs...)
5858
59-
Given some keyword arguments and an input `A`, decide on an algrithm to use for
59+
Given some keyword arguments and an input `A`, decide on an algorithm to use for
6060
implementing the function `f` on inputs of type `A`.
61+
62+
In general, if an algorithm is specified explicitly through the `alg` keyword argument
63+
(either as an algorithm type, an algorithm name as a Symbol, or as an algorithm object),
64+
that algorithm will be used instead of selecting it automatically. However, that
65+
behavior may be modified for factorization functions and/or matrix types.
66+
67+
In general, if the algorithm is not specified, a default algorithm specified by
68+
[`default_algorithm`](@ref) will be used.
6169
"""
6270
function select_algorithm end
6371

@@ -82,6 +90,15 @@ function _select_algorithm(f, A, alg; kwargs...)
8290
return throw(ArgumentError("Unknown alg $alg"))
8391
end
8492

93+
@doc """
94+
default_algorithm(f, A; kwargs...)
95+
96+
Select the default algorithm for a given factorization function `f` and input `A`.
97+
In general, this is called by [`select_algorithm`](@ref) if no algorithm is specified
98+
explicitly.
99+
"""
100+
function default_algorithm end
101+
85102
@doc """
86103
copy_input(f, A)
87104

0 commit comments

Comments
 (0)