I recently need to plot a 3d function that satisfies certain constraints, like
or things similar. So I wonder how to plot the part that only lies within the constraints?
An example surface can be
More interestingly, is it possible to do that for an implicit function, e.g. x^2+y^2-z^3-z=0, without solving for the equation? Thanks a lot!