Skip to content

Commit

Permalink
Add missing sympy operators for boolean logic
Browse files Browse the repository at this point in the history
  • Loading branch information
MilesCranmer committed Sep 19, 2023
1 parent 6c92e1c commit ff2f93a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pysr/export_sympy.py
Expand Up @@ -47,6 +47,8 @@
"ceil": sympy.ceiling,
"sign": sympy.sign,
"gamma": sympy.gamma,
"logical_or": lambda x, y: sympy.Piecewise((1.0, 0.0), ((x > 0) | (y > 0), True)),
"logical_and": lambda x, y: sympy.Piecewise((1.0, 0.0), ((x > 0) & (y > 0), True)),
}


Expand Down

0 comments on commit ff2f93a

Please sign in to comment.