Commit ab94aa87 authored by Sylvain Soliman's avatar Sylvain Soliman
Browse files

allow division by a squared constant in tropicalize

parent d6797710
......@@ -235,7 +235,7 @@ subst_deg_and_vars(A/N, Vars, Ai, AA - D) :-
!,
subst_deg_and_vars(A, Vars, Ai, AA).
% Only accept division by constants
% Only accept addition of constants
subst_deg_and_vars(N + M, _Vars, _Ai, D) :-
const_degree(N+M, D),
!.
......@@ -263,7 +263,7 @@ const_eval(N, N) :-
const_eval(Term, D) :-
Term =.. [Op, A, B],
member(Op, ['+', '*', '-', '/']),
member(Op, ['+', '*', '-', '^', /']),
const_eval(A, AA),
const_eval(B, BB),
TTerm =.. [Op, AA, BB],
......
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