Commit e0a90cda authored by HEMERY Mathieu's avatar HEMERY Mathieu
Browse files

Merge branch 'feature/Hybrid' of https://gitlab.inria.fr/lifeware/biocham into feature/Hybrid

parents fdefcf23 04737870
......@@ -1303,9 +1303,12 @@ hybrid_dynamic_simulation(InputFile,OutFilename,Volume,Time,PropTresh,PartTresh)
prepare_change_list(Reactions,SortedSpecies,List),
%format("List is ~w ~n",[List]),
assertz(minimum_reactant_change(inf)),
% Because inf/0 is not defined in old versions of SWI-Prolog, we use
% something else
current_prolog_flag(max_tagged_integer, Inf),
assertz(minimum_reactant_change(Inf)),
assertz(maximum_reactant_change(0)),
assertz(minimum_product_change(inf)),
assertz(minimum_product_change(Inf)),
assertz(maximum_product_change(0)),
findall([Species_change, Alpha],
(
......
......@@ -294,9 +294,15 @@ rw_coeff(floor(Element),CurrentState,Parameters,Time,Result) :-
rw_coeff(random,_,_,_,Result) :-
!,Result is random_float.
% skipped to test continous integration
% rw_coeff(infinity,_,_,_,Result) :-
% !,Result is 1.0Inf.
rw_coeff(infinity,_,_,_,Result) :-
!,
catch(
Result is inf,
% old SWIPL (7.2.3) doesn't have inf/0
error(type_error(evaluable, inf/0), _),
% use something big
current_flag(max_tagged_integer, Result)
).
rw_coeff(t,_,_,Time,Time) :-
!.
......
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