I am trying to make a 3d plot of a surface that is defined in different ways for different regions. As an example, take f(x,y) that is defined as 1 if x > y and as x^2 if x <= y.
I defined f with logical operators, and tried to plot it with the "plot_surface" function, evaluating it in a grid. Unfortunately, I got an error saying that "the truth value of an array with more than one element is ambiguous".
Do you know any way of solving this?