Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refer to the @edit macro #70

Merged
merged 1 commit into from
Sep 20, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions docs/src/examples/02d-constraint-modifications.jl
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,9 @@ fermentation_constraint = C.Constraint(total_fermentation, (10.0, 1000.0))

fermenting_ct = ct * :fermentation^fermentation_constraint

#md # !!! tip "What if I need more complicated changes?"
#md # Almost all analysis functions have an associated constraint-building function that internally builds the constraint system, for example the [`parsimonious_flux_balance_analysis`](@ref) is implemented with [`parsimonious_flux_balance_constraints`](@ref), which can be used just as [`flux_balance_constraints`](@ref) here. Additionally, to reach various custom goals, it is recommended to re-use and modify the source of the functions -- use the macro [`@edit`](https://docs.julialang.org/en/v1/stdlib/InteractiveUtils/#InteractiveUtils.@edit), such as `@edit parsimonious_flux_balance_constraints`, to get a working source code that serves well as a base for implementing new constraint systems.

# Constraint trees can be "solved", simply by choosing the objective and sending
# them to the appropriate function. Here, [`optimized_values`](@ref) rewrites
# the constraints into a JuMP model, which is subsequently solved and the
Expand Down
Loading