I want to graph a circle in 3d, but don't know the code for it. I've tried the following code, but it doesn't seem to work.

Asked
Active
Viewed 1,374 times
1
fidafa123
- 145
- 1
- 8
-
Since it seems you weren't told yet: please do not post code as an image. Copy the text of your code and paste it in your question. In the meantime, please look at the linked thread to see if anything there suits your needs. – J. M.'s missing motivation Sep 20 '17 at 00:13
1 Answers
3
Circle is a 2D graphics primitive. The corresponding primitive in 3D would be Cylinder:
Graphics3D[{FaceForm[None], Cylinder[{{0, 0, 0}, {0, 0, 0.01}}]}]

Or use ParametricPlot:
ParametricPlot3D[{Sin[u], Cos[u], 0}, {u, 0, 2 Pi}]

You can also use Line like this:
pts = Table[{Sin[u], Cos[u], 0}, {u, 0, 2 Pi, 0.01}];
Graphics3D[Line[pts]]

C. E.
- 70,533
- 6
- 140
- 264