Reputation:
Can matplotlib draw relations like x^2+y^2<=2 in blue and then x^2+y^2<=1+0.5*sin((x^3+y^3)*2pi) in red ?
x^2+y^2<=2
x^2+y^2<=1+0.5*sin((x^3+y^3)*2pi)
Upvotes: 3
Views: 497
Reputation: 362756
You should look at plot_implicit in sympy.
plot_implicit
>>> from sympy import plot_implicit, sin, symbols, pi >>> x, y = symbols('x y') >>> my_plot = plot_implicit(x**2 + y**2 <= 1 + 0.5 * sin((x**3 + y**3) * 2 * pi))
Upvotes: 4