restart:with(plots):
f:=(x,y) -> x*cos(x*y);
p1:=plot3d(f(x,y), x=-3..3, y=-3..3, axes=normal, scaling=constrained):
p2:=spacecurve([2*cos(t), 2*sin(t), f(2*cos(t), 2*sin(t))], t=0..2*Pi, color=red, thickness=2):
display(p1,p2);
p3:=contourplot(f(x,y), x=-3..3, y=-3..3, contours=30, coloring=[blue,red]):
p4:=plot([2*cos(t),2*sin(t), t=0..2*Pi], color=red, thickness=2):
display(p3,p4);