I am trying to place a 3D arrow in a Plot3D
:
g[x_, y_] := 1/(2*π*σ^2)*E^(-((x^2 + y^2)/(2*σ^2))) /. {σ -> 1};
Show[
Plot3D[g[x, y], {x, -5, 5}, {y, -5, 5},
PlotRange -> All,
PlotStyle -> Opacity[0.5]],
Graphics3D[{Red, Arrow[Tube[{{0, 0, g[0, 0]}, {1, 1, g[0, 0]}}]]}]]
But the problem is that this results in a very squeezed arrow:
I think it has something to do with the different scaling at the z-axis but I don't know how to overcome that (without scaling the original function). Adding the option BoxRatios -> Automatic
to the show command makes the arrow look normal but then the plot reduces to a flat surface:
Related question but without a satisfactory answer for 3D arrows: How to make 3 dimensional arrows look good when their lenghs are wildly different?
So, any ideas of how to place a 3D arrow in a 3D plot without messing one of the graphics up?