Skip to content

Commit

Permalink
Merge pull request #468 from Omar-Elrefaei/patch-1
Browse files Browse the repository at this point in the history
Simplify degenerate ifelse cases. Fix JuliaSymbolics/Symbolics.jl#170
  • Loading branch information
shashi authored Mar 24, 2023
2 parents 7a9f0c5 + 1acb9c2 commit 224e752
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/simplify_rules.jl
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ let
@rule(real(~x::_isreal) => ~x)
@rule(imag(~x::_isreal) => zero(symtype(~x)))
@rule(ifelse(~x::is_literal_number, ~y, ~z) => ~x ? ~y : ~z)
@rule(ifelse(~x, ~y, ~y) => ~y)
]

TRIG_EXP_RULES = [
Expand Down

0 comments on commit 224e752

Please sign in to comment.