How to include 2 dimensional disks in a Graphics3D object (Ellipsoid) - Mathematica Stack Exchange most recent 30 from mathematica.stackexchange.com 2019-09-18T14:56:17Z https://mathematica.stackexchange.com/feeds/question/99958 https://creativecommons.org/licenses/by-sa/4.0/rdf https://mathematica.stackexchange.com/q/99958 6 How to include 2 dimensional disks in a Graphics3D object (Ellipsoid) Dimitris https://mathematica.stackexchange.com/users/16314 2015-11-20T10:20:16Z 2015-11-20T12:02:23Z <p>I hope I am not doing something wrong.</p> <p>Compare the following figures.</p> <p>1) <code>Ellipsoid</code></p> <pre><code>Graphics3D[{{Specularity[White, 40], Opacity[0.5], Ellipsoid[{0, 0, 0}, {10, 3, 2}]}, {Opacity, Ellipsoid[{0, 0, 0}, {0, 3, 2}], Ellipsoid[{0, 0, 0}, {10, 0, 2}], Ellipsoid[{0, 0, 0}, {10, 3, 0}]}}, ImageSize -&gt; Large] </code></pre> <p><a href="https://i.stack.imgur.com/fdW2t.png"><img src="https://i.stack.imgur.com/fdW2t.png" alt="enter image description here"></a></p> <p>2) The same goal but in a more "user-defined" way</p> <pre><code> Graphics3D[{Specularity[White, 40], Opacity[0.5], Scale[#, {10, 3, 2}], {Opacity, Scale[#, {.001, 3, 2}], Scale[#, {10, 0.001, 2}], Scale[#, {10, 3, 0.001}]}} &amp;@Sphere[], ImageSize -&gt; Large] </code></pre> <p><a href="https://i.stack.imgur.com/oN5vH.png"><img src="https://i.stack.imgur.com/oN5vH.png" alt="enter image description here"></a></p> <p>Why the quality of the first <code>Graphics3D</code> is so bad?</p> <pre><code>\$Version (*"10.3.0 for Linux x86 (64-bit) (October 9, 2015)"*) </code></pre> https://mathematica.stackexchange.com/questions/99958/how-to-include-2-dimensional-disks-in-a-graphics3d-object-ellipsoid/99959#99959 5 Answer by Jason B. for How to include 2 dimensional disks in a Graphics3D object (Ellipsoid) Jason B. https://mathematica.stackexchange.com/users/9490 2015-11-20T11:00:36Z 2015-11-20T12:02:23Z <p>The problem with the first graphic is that you are trying to create a 3D object with exactly zero width in one dimension. In the second graphic, you make the width in that dimension equal to a small value. This same workaround can be applied to the <code>Ellipsoid</code> call,</p> <pre><code>Graphics3D[{{Specularity[White, 40], Opacity[0.5], Ellipsoid[{0, 0, 0}, {10, 3, 2}]}, {Opacity, Ellipsoid[{0, 0, 0}, {0.001, 3, 2}], Ellipsoid[{0, 0, 0}, {10, 0.001, 2}], Ellipsoid[{0, 0, 0}, {10, 3, 0.001}]}}, ImageSize -&gt; Large] </code></pre> <p><a href="https://i.stack.imgur.com/kmI0r.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/kmI0r.png" alt="enter image description here"></a></p> <p>Thanks to shrx for pointing out a better way to do this, as shown in in <a href="https://mathematica.stackexchange.com/a/79793/9490">this</a> post by Taiki. Using the function <code>ellipse3D[center,{r1,r2},normal]</code>, which takes as argument the center position, the two semiaxes, and the normal vector to the plane, we get</p> <pre><code>Graphics3D[{{Specularity[White, 40], Opacity[0.5], Ellipsoid[{0, 0, 0}, {10, 3, 2}]}, {Opacity, EdgeForm[None], ellipse3D[{0, 0, 0}, {2, 3}, {1, 0, 0}], ellipse3D[{0, 0, 0}, {10, 2}, {0, 1, 0}], ellipse3D[{0, 0, 0}, {10, 3}, {0, 0, 1}]}}, ImageSize -&gt; Large] </code></pre> <p><a href="https://i.stack.imgur.com/eWogA.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/eWogA.png" alt="enter image description here"></a></p> <p>giving an identical looking result which, as halirutan says, will behave better in the long run.</p>