Commit c5e531f4 authored by Mathieu Hemery's avatar Mathieu Hemery
Browse files

Start correction by removing null kinetics

parent 21646af9
/*
Implement the automatic correction of models loaded from a sbml file
Coder: M. Hemery
*/
:- module(
correction,
[
% Commands
correct_model/0
% API
]
).
% Only for separate compilation/linting
:- use_module(arithmetic_rules).
:- use_module(doc).
:- use_module(formal_derivation).
:- use_module(reaction_rules).
:- use_module(util).
correct_model :-
biocham_command,
doc(''),
single_model(ModelId),
findall(
Molecule,
identifier_kind(ModelId, Molecule, object),
List_Molecule
),
reactions_with_species(List_Molecule, List_Reaction),
forall(
member(Reaction, List_Reaction),
remove_null_kinetic(Reaction)
).
%! remove_null_kinetic(+Reaction)
%
% Detect and remove reactions with identically null kinetics
remove_null_kinetic(Expression for Reaction) :-
(
is_null(Expression)
->
delete_reaction(Expression for Reaction)
;
true
).
......@@ -52,6 +52,7 @@
* Importing and Exporting BIOCHAM Models
** Biocham files
- models.pl
- model_correction.pl
** SBML and SBML-qual files
- sbml_files.pl
- qual_files.pl
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment