You can't use == for symbolic operations anywhere in SymPy, because ==
always does a direct structural equality check, and always results in
either True or False
>>> import sympy.stats as stats
>>> D = stats.Die('D', 6)
>>> D == 3
False
If you want to create an equality object you should use Eq(), like
>>> Eq(D, 3)
Eq(D, 3)
>>> stats.P(Eq(D, 3))
1/6
Aaron Meurer
> --
> You received this message because you are subscribed to the Google Groups "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
sympy+un...@googlegroups.com.
> To view this discussion visit
https://groups.google.com/d/msgid/sympy/fd662394-3e69-f9f0-70a7-388a01a669a%40SamsungLaptop.WORKGROUP.