This is a bug. Can you open an issue with sympy on GitHub?
The correct answer is given if you use exact rational numbers (S(1)/2
or Rational(1, 2)) rather than the float 1/2:
In [6]: solveset(Eq(sin(x), S(1)/2), x, Reals)
Out[6]:
⎧5⋅π │ ⎫ ⎧π │ ⎫
⎨2⋅n⋅π + ─── │ n ∊ ℤ⎬
Hello - I'm trying to use Sympy Live to debug an issue with a program I'm
writing. When I try to use solveset for sin(x)=1/2, I get no solutions.
Apparently it thinks there's a tiny complex portion to the solution.
Why am I running into this? Ironically I'm not running into this problem in
my
Just opened a PR, thank you!
Mathias Louboutin
On Wednesday, October 4, 2023 at 3:09:05 PM UTC-4 asme...@gmail.com wrote:
> I think it can be added. Can you make a pull request?
>
> Aaron Meurer
>
> On Wed, Oct 4, 2023 at 10:18 AM Mathias Louboutin
> wrote:
> >
> > Hi
> >
> > Would it be