用Mathematica让3D图形动起来

2024-10-11 18:49:19

1、 画一个单位正方体,再让它绕z轴旋转,代码如下:Animate[Graphics3D[Rotate[Cuboid[], n Degree, {0, 0, 1}]], {n, 0, 360,1}]

用Mathematica让3D图形动起来

3、 再画一个稍微复杂的图形:Animate[Graphics3D职邗珩垃[{PointSize[0.03], Opacity[.5], Rotate[{EdgeForm[Blue], Po造婷用痃lyhedronData["TruncatedDodecahedron", "Faces"], Style[Point[ PolyhedronData["TruncatedDodecahedron", "VertexCoordinates"]], Opacity[1], Red]}, n Degree, {0, 0, 1}, {0.5, 0.5, 0}]}, Boxed -> False], {n, 0, 360, 1}]

用Mathematica让3D图形动起来
猜你喜欢