Skip to content

Commit 9780927

Browse files
franckgagagdalle
andauthored
doc: add docstrings to the result anlysis methods for sparse matrix preparations (#984)
* doc: add DI.jl sparse preperation method docstrings * Format with Runic --------- Co-authored-by: Guillaume Dalle <22795598+gdalle@users.noreply.github.com>
1 parent 1a1ff88 commit 9780927

File tree

1 file changed

+61
-0
lines changed

1 file changed

+61
-0
lines changed

DifferentiationInterface/ext/DifferentiationInterfaceSparseMatrixColoringsExt/DifferentiationInterfaceSparseMatrixColoringsExt.jl

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,81 @@ import SparseMatrixColorings as SMC
1919

2020
abstract type SMCSparseJacobianPrep{SIG} <: DI.SparseJacobianPrep{SIG} end
2121

22+
"""
23+
SMC.sparsity_pattern(prep::DI.SparseJacobianPrep)
24+
25+
Return the sparsity pattern of a sparse `prep` object created by [`prepare_jacobian`](@ref).
26+
"""
2227
SMC.sparsity_pattern(prep::DI.SparseJacobianPrep) = prep.sparsity
28+
29+
"""
30+
SMC.column_colors(prep::DI.SparseJacobianPrep)
31+
32+
Return the column colors of a sparse `prep` object created by [`prepare_jacobian`](@ref).
33+
"""
2334
SMC.column_colors(prep::DI.SparseJacobianPrep) = column_colors(prep.coloring_result)
35+
36+
"""
37+
SMC.column_groups(prep::DI.SparseJacobianPrep)
38+
39+
Return the column groups of a sparse `prep` object created by [`prepare_jacobian`](@ref).
40+
"""
2441
SMC.column_groups(prep::DI.SparseJacobianPrep) = column_groups(prep.coloring_result)
42+
43+
"""
44+
SMC.row_colors(prep::DI.SparseJacobianPrep)
45+
46+
Return the row colors of a sparse `prep` object created by [`prepare_jacobian`](@ref).
47+
"""
2548
SMC.row_colors(prep::DI.SparseJacobianPrep) = row_colors(prep.coloring_result)
49+
50+
"""
51+
SMC.row_groups(prep::DI.SparseJacobianPrep)
52+
53+
Return the row groups of a sparse `prep` object created by [`prepare_jacobian`](@ref).
54+
"""
2655
SMC.row_groups(prep::DI.SparseJacobianPrep) = row_groups(prep.coloring_result)
56+
57+
"""
58+
SMC.ncolors(prep::DI.SparseJacobianPrep)
59+
60+
Return the number of colors of a sparse `prep` object created by [`prepare_jacobian`](@ref).
61+
"""
2762
SMC.ncolors(prep::DI.SparseJacobianPrep) = ncolors(prep.coloring_result)
2863

64+
65+
"""
66+
SMC.sparsity_pattern(prep::DI.SparseHessianPrep)
67+
68+
Return the sparsity pattern of a sparse `prep` object created by [`prepare_hessian`](@ref).
69+
"""
2970
SMC.sparsity_pattern(prep::DI.SparseHessianPrep) = prep.sparsity
71+
72+
"""
73+
SMC.column_colors(prep::DI.SparseHessianPrep)
74+
75+
Return the column colors of a sparse `prep` object created by [`prepare_hessian`](@ref).
76+
"""
3077
SMC.column_colors(prep::DI.SparseHessianPrep) = column_colors(prep.coloring_result)
78+
79+
"""
80+
SMC.column_groups(prep::DI.SparseHessianPrep)
81+
82+
Return the column groups of a sparse `prep` object created by [`prepare_hessian`](@ref).
83+
"""
3184
SMC.column_groups(prep::DI.SparseHessianPrep) = column_groups(prep.coloring_result)
85+
86+
"""
87+
SMC.ncolors(prep::DI.SparseHessianPrep)
88+
89+
Return the number of colors of a sparse `prep` object created by [`prepare_hessian`](@ref).
90+
"""
3291
SMC.ncolors(prep::DI.SparseHessianPrep) = ncolors(prep.coloring_result)
3392

93+
3494
include("jacobian.jl")
3595
include("jacobian_mixed.jl")
3696
include("hessian.jl")
3797

98+
3899
end

0 commit comments

Comments
 (0)