[Python] Why does `sympy.plot_implicit` not work on for combined conditionals that involve...

Discussão em 'Python' iniciado por Stack, Julho 17, 2025.

  1. Stack

    Stack Membro Participativo

    I have the following python code that uses sympy:

    from sympy import *
    x, y = symbols('x y')

    cond1 = y + 2*Abs(x) > 0
    cond2 = x > 0
    cond3 = y < 0

    p1 = plot_implicit(cond1)
    p2 = plot_implicit(cond2)
    p3 = plot_implicit(And(cond2, cond3))
    try:
    p4 = plot_implicit(And(cond1, cond2))
    except:
    print("Why is this not working")


    The last plot throws, but I don't know why.

    Continue reading...

Compartilhe esta Página