5
$\begingroup$

As we all know in spherical coordinates a function phi = π/3 gives us a cone. The cone makes an angle of π/3 with the imagined z-axis. How do I type this formula into Mathematica?

$\endgroup$
2
  • 1
    $\begingroup$ RevolutionPlot3D[3 z, {z, 0, -2}, ColorFunction -> "Rainbow", Mesh -> None] $\endgroup$ Commented Dec 14, 2013 at 5:49
  • 1
    $\begingroup$ Related cones on spheres: Cone image refinement. $\endgroup$
    – Artes
    Commented Dec 14, 2013 at 12:20

1 Answer 1

8
$\begingroup$

You can use CoordinateTransform to change coordinates to Cartesian and then use ParametricPlot3D to make the plot.

cone[r_, θ_] := 
  Evaluate[CoordinateTransform["Spherical" -> "Cartesian", {r, ϕ, θ}] /. ϕ -> π/4]
ParametricPlot3D[cone[r, θ], {r, 0, 1}, {θ, 0, 2. π}]

This gives

plot.png

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.