Skip to content

Commit a977cf0

Browse files
committed
writing fix
1 parent 5ec6ea7 commit a977cf0

File tree

4 files changed

+3
-6
lines changed

4 files changed

+3
-6
lines changed

docs/src/catalyst_functionality/dsl_description.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -703,7 +703,7 @@ nothing # hide
703703
```
704704

705705
## Incorporating (differential) equations into reaction network models
706-
Some models cannot be purely described as a reaction network. E.g. consider the growth of a cell, where the rate of change in cell's volume depends on some growth factor. Here, the cell's volume would be described by a normal equation. Such equations can be incorporated into a model using the `@equations` option. Here, we create a model where a growth factor ($G$) is produced and degraded at a linear rates, and the rate of change in cell volume ($V$) os linear to the amount of growth factor:
706+
Some models cannot be purely described as reaction networks. E.g. consider the growth of a cell, where the rate of change in cell's volume depends on some growth factor. Here, the cell's volume would be described by a normal equation. Such equations can be incorporated into a model using the `@equations` option. Here, we create a model where a growth factor ($G$) is produced and degraded at a linear rates, and the rate of change in cell volume ($V$) os linear to the amount of growth factor:
707707
```@example eqs1
708708
using Catalyst #hide
709709
rn = @reaction_network begin
@@ -731,7 +731,7 @@ plot(sol)
731731
```
732732
Here, growth is indefinite. To improve the model, [a callback](@ref advanced_simulations_callbacks) can be used to half the volume (cell division) once some threshold is reached.
733733

734-
When creating differential equations this way, the subject of the differential is automatically inferred to be a variable, however, any component on the right-hand side must be declare somewhere in the macro. E.g. to add a scaling parameter ($k$), we must declare that $k$ is a parmaeter using the `@paraemters` option:
734+
When creating differential equations this way, the subject of the differential is automatically inferred to be a variable, however, any component on the right-hand side must be declare somewhere in the macro. E.g. to add a scaling parameter ($k$), we must declare that $k$ is a parameter using the `@parameters` option:
735735
```@example eqs1
736736
rn = @reaction_network begin
737737
@parameters k
@@ -742,6 +742,7 @@ rn = @reaction_network begin
742742
end
743743
nothing #hide
744744
```
745+
If the differential does not appear isolated on the lhs, its subject variable must also be explicitly declared (as it is not inferred for these cases).
745746

746747
It is possible to add several equations to the model. In this case, each have a separate line. E.g. to keep track of a supply of nutrition ($N$) in the growth media, we can use:
747748
```@example eqs1

src/networkapi.jl

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,6 @@ function reactions(network)
9797
[rxs; reduce(vcat, namespace_reactions.(systems); init = Reaction[])]
9898
end
9999

100-
101100
"""
102101
speciesmap(network)
103102
@@ -585,7 +584,6 @@ end
585584
symmap_to_varmap(sys, symmap) = symmap
586585
#error("symmap_to_varmap requires a Dict, AbstractArray or Tuple to map Symbols to values.")
587586

588-
589587
######################## reaction complexes and reaction rates ###############################
590588

591589
"""

src/reaction_network.jl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -921,7 +921,6 @@ function check_default_noise_scaling!(default_reaction_metadata, options)
921921
end
922922
end
923923

924-
925924
### Functionality for expanding function call to custom and specific functions ###
926925

927926
#Recursively traverses an expression and replaces special function call like "hill(...)" with the actual corresponding expression.

src/reactionsystem.jl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1662,7 +1662,6 @@ function Base.convert(::Type{<:SDESystem}, rs::ReactionSystem;
16621662
spatial_convert_err(rs::ReactionSystem, SDESystem)
16631663

16641664
flatrs = Catalyst.flatten(rs)
1665-
#error_if_constraints(SDESystem, flatrs)
16661665

16671666
remove_conserved && conservationlaws(flatrs)
16681667
ists, ispcs = get_indep_sts(flatrs, remove_conserved)

0 commit comments

Comments
 (0)