23

The surface show below is very beautiful; however, I don't know its function either as an implicit function or in parametric form.

Anyone have an idea about it and how to draw it with Mathematica?

Beautiful surface

m_goldberg
  • 107,779
  • 16
  • 103
  • 257
LCFactorization
  • 3,047
  • 24
  • 37
  • 3
    One way might be to browse on-line the Mathematica GUIDE book for graphics by Trott at google books http://books.google.com/books?id=9DGhukeFNLIC&printsec=frontcover&source=gbs_ge_summary_r&cad=0#v=onepage&q&f=false If anyone done something like the above, it will be in that book. Many more amazing plots there. – Nasser Nov 24 '13 at 09:15
  • 5
    Do you have any affiliation with this? http://translate.google.com/translate?sl=auto&tl=en&js=n&prev=_t&hl=en&ie=UTF-8&u=http%3A%2F%2Fwww.mysanco.com%2Fwenda%2Findex.php%3Fclass%3Ddiscuss%26action%3Dquestion_item%26questionid%3D6138 – Dr. belisarius Nov 24 '13 at 16:45
  • Can you please give an answer to @belisarius. You have had 4 days to respond and you are back here again today. – Mike Honeychurch Nov 28 '13 at 01:07
  • @belisarius I have no access to this due to the network being blocked – LCFactorization Nov 28 '13 at 01:48
  • Strange ... at least @MikeHoneychurch, four others and me aren't suffering any blocking. Someone is playing dirty with your network access. – Dr. belisarius Nov 28 '13 at 01:51
  • Google services are usually instable here; – LCFactorization Nov 28 '13 at 01:55
  • @belisarius I did post similar questions in other forum and only got answers here. – LCFactorization Nov 28 '13 at 01:56
  • @belisarius I think the Chinese webpage you referred to is a Q/A forum in China which is popular among some academic people. Basically it's the same question as this one, only was asked earlier (15 Nov). And the OP there answered his/her own question 3 days ago. I suspect it's the same person as our OP here. So, IMO, this is not an abuse :) – Silvia Nov 28 '13 at 02:18
  • @Silvia Thanks! And yes, he just answered that at my original comment. Personally I dislike cross-posting without leaving a notice because the OP is the only one who can get benefits from the answers on both sites. But in this case, it's worse, as the answer in the Chinese site is a copy of the code here, without attribution. A shame. – Dr. belisarius Nov 28 '13 at 02:28
  • About the blocking, It really depends. Geography, timing, ISP, etc. They all play a part on the power of the GFW. Say, we were having Lianghui here a few days ago, thus many oversea sites are temporarily blocked.. – Silvia Nov 28 '13 at 02:29
  • @belisarius thanks for pointing out this. I would add a link to here the original answer. As a matter of fact, I also post the similar answer in other places before with original link attached. – LCFactorization Nov 28 '13 at 02:35
  • @belisarius Have taken a close look at his post there, and yes I totally agree with you. It's not right copying the whole answer without leaving any ref to the original one... Hope OP can add this information. – Silvia Nov 28 '13 at 02:35
  • @LCFactorization Hi. Don't be frightened! Most people here are super nice! Just keep in mind some common manners and form the habit of honour others’ authorship. :) – Silvia Nov 28 '13 at 02:49
  • @Silvia, LCFactorization. Ok, everything is in its place now. Thanks to both of you! – Dr. belisarius Nov 28 '13 at 03:04
  • @belisarius You are welcome! – Silvia Nov 28 '13 at 03:05
  • @LCFactorization We could chat here. – Silvia Nov 28 '13 at 03:22
  • your question lead to this one on a sibling site: Rotation transformation of a parametrized plot :) – cmhughes Jul 22 '14 at 19:42

2 Answers2

52

Consider this:

ParametricPlot3D[
 RotationTransform[a, {0, 1, 0}][{0, 0, Sin[3 a] + 5/4}],
  {a, 0, 2 Pi}, Evaluated -> True]

enter image description here

Now rotate this around a circle, while rotating it at the same time around its' origin:

ParametricPlot3D[
 RotationTransform[b, {0, 0, 1}][{6, 0, 0} + 
   RotationTransform[a + 3 b, {0, 1, 0}][{0, 0, Sin[3 a] + 5/4}]],
    {a, 0, 2 Pi}, {b, 0, 2 Pi}, PlotPoints -> 40, Evaluated -> True]

enter image description here

EDIT:

A color function, omitting surface mesh, fixing direction of rotation and adding a hint of transparency, like the original:

ParametricPlot3D[
 RotationTransform[b, {0, 0, 1}][{6, 0, 0} + 
   RotationTransform[a - 3 b + Pi, {0, 1, 0}][{0, 0, Sin[3 a] + 5/4}]],
 {a, 0, 2 Pi}, {b, 0, 2 Pi}, PlotPoints -> 40, 
 ColorFunction -> (RGBColor[#, 0, 1 - #, 4/5] &[1/2 + {1, -1}.{#1, #2}/2] &),
 Mesh -> False, Evaluated -> True]

enter image description here

This might be slightly more intuitive way to write ColorFunction using Blend and Opacity in PlotStyle:

ParametricPlot3D[
 RotationTransform[b, {0, 0, 1}][{6, 0, 0} + 
   RotationTransform[a - 3 b + Pi, {0, 1, 0}][{0, 0, Sin[3 a] + 5/4}]],
 {a, 0, 2 Pi}, {b, 0, 2 Pi},
 PlotPoints -> 40, 
 PlotStyle -> Opacity[4/5], 
 ColorFunction -> (Blend[{Red, Blue}, 1/2 + {1, -1}.{#1, #2}/2] &), 
 Mesh -> False, Evaluated -> True]
kirma
  • 19,056
  • 1
  • 51
  • 93
21

I'm adding this answer to put on record an answer to the second part the question, "what is the parametric equation?".

The parametric equation is implicit in Kirma's RotationTransform expression. To extract it, one need simply write something like

Clear[a, b]
quoit[a_, b_] := 
  Evaluate @ RotationTransform[b, {0, 0, 1}][{6, 0, 0} + 
    RotationTransform[a - 3 b + Pi, {0, 1, 0}][{0, 0, Sin[3 a] + 5/4}]]

The function defined by the above expression, looks like this

Definition @ quoit
quoit[a_, b_] := 
   {
     Cos[b] (6 - (5/4 + Sin[3 a]) Sin[a - 3 b]), 
     (6 - (5/4 + Sin[3 a]) Sin[a - 3 b]) Sin[b], 
     -Cos[a - 3 b] (5/4 + Sin[3 a])
   }
m_goldberg
  • 107,779
  • 16
  • 103
  • 257
  • thank you very much ! very useful – LCFactorization Nov 24 '13 at 15:47
  • Indeed; maybe I left this part a bit too much implied. – kirma Nov 24 '13 at 17:23
  • 4
    Also the order of wrapping rotation matrix is critical. When the foil rotates around the circle (outmost transform function), the Z axis is fixed. While it spins about its center, the attached Z axis changes direction. Thats why the transform with {0,1,0} is inside the first transform. – yshk Nov 25 '13 at 02:16