Skip to content

Commit 211ac81

Browse files
committed
update docstrings
1 parent 4a691b4 commit 211ac81

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

src/network_analysis.jl

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ function complexstoichmat(::Type{Matrix{Int}}, rn::ReactionSystem, rcs)
193193
end
194194

195195
"""
196-
laplacianmat(rn::ReactionSystem, parammap=nothing; sparse=false)
196+
laplacianmat(rn::ReactionSystem, pmap=Dict(); sparse=false)
197197
198198
Return the negative of the graph Laplacian of the reaction network. The ODE system of a chemical reaction network can be factorized as ``\frac{dx}{dt} = Y A_k Φ(x)``, where Y is the [`complexstoichmat`](@ref) and A_k is the negative of the graph Laplacian, and Φ is the [`massactionvector`](@ref). A_k is an n-by-n matrix, where n is the number of complexes, where A_{ij} = k_{ij} if a reaction exists between the two complexes and 0 otherwise.
199199
Returns a symbolic matrix by default, but will return a numerical matrix if parameter values are specified via parammap.
@@ -204,11 +204,12 @@ function laplacianmat(rn::ReactionSystem, pmap = Dict(); sparse = false)
204204
end
205205

206206
"""
207-
fluxmat(rn::ReactionSystem, parammap = nothing; sparse=true)
207+
fluxmat(rn::ReactionSystem, pmap = Dict(); sparse=false)
208208
209209
Return an r×c matrix K such that, if complex j is the substrate complex of reaction i, then K_{ij} = k, the rate constant for this reaction. Mostly a helper function for the network Laplacian, [`networklaplacianmat`](@ref). Has the useful property that ``\frac{dx}{dt} = S*K*Φ(x)``, where S is the [`netstoichmat`](@ref) or net stoichiometry matrix.
210+
Returns a symbolic matrix by default, but will return a numerical matrix if rate constants are specified as a `Tuple`, `Vector`, or `Dict` of symbol-value pairs via `pmap`.
210211
"""
211-
function fluxmat(rn::ReactionSystem, pmap::Dict = Dict(); sparse=true)
212+
function fluxmat(rn::ReactionSystem, pmap::Dict = Dict(); sparse=false)
212213
rates = reactionrates(rn)
213214

214215
if !isempty(pmap)
@@ -265,7 +266,7 @@ function fluxmat(rn::ReactionSystem, pmap::Tuple; sparse = false)
265266
end
266267

267268
"""
268-
massactionvector(rn::ReactionSystem, scmap = nothing)
269+
massactionvector(rn::ReactionSystem, scmap = Dict())
269270
270271
Return the vector whose entries correspond to the "mass action products" of each complex. For example, given the complex A + B, the corresponding entry of the vector would be A*B, and for the complex 2X + Y, the corresponding entry would be X^2*Y. The ODE system of a chemical reaction network can be factorized as ``\frac{dx}{dt} = Y A_k Φ(x)``, where Y is the [`complexstoichmat`](@ref) and A_k is the negative of the [`networklaplacian`](@ref). This utility returns Φ(x).
271272
Returns a symbolic vector by default, but will return a numerical vector if species concentrations are specified as a tuple, vector, or dictionary via scmap.
@@ -275,7 +276,7 @@ function massactionvector(rn::ReactionSystem, scmap::Dict = Dict())
275276
sm = speciesmap(rn); specs = species(rn)
276277

277278
if !all(r -> ismassaction(r, rn), rxs)
278-
error("The supplied ReactionSystem has reactions that are not ismassaction. The monomial vector is only defined for pure mass action networks.")
279+
error("The supplied ReactionSystem has reactions that are not ismassaction. The mass action vector is only defined for pure mass action networks.")
279280
end
280281

281282
if !isempty(scmap)

0 commit comments

Comments
 (0)