Skip to main content

graphics - Obtaining a 3D animation as a drop in a liquid surface


Someone could get a similar solution like this animation?


enter image description here


I believe the solution is useful for demonstrations in class to other users who teach Math.


Spreading of a Thin Liquid Drop Under the Influence of Gravity, Rotation and Non-Uniform Surface Tension



Answer



Thanks to J.M.



drop = SetAlphaChannel[#, ColorNegate@#] &@
Binarize@Rasterize@
ParametricPlot[{r Cos[t] (1 - Sin[t]), -3 +
r (5/2 (Sin[t] - 1) + 3)}, {t, 0, 2 Pi}, {r, 0, 1},
BoundaryStyle -> None, Axes -> False, Frame -> False]

Something to start with:


circle = Table[
Translate[
Point[{##, 0} & @@@ CirclePoints[r, 10 + 20 r]],

{0, 0, Dynamic[f[#, t]] &@r}
],
{r, .5, 20, .5}
];

f[r_, t_] := UnitBox[(r - t)/(2 Pi) - .5] Sin[r - t];
t = -4 Pi;

Column@{
Trigger[Dynamic[t], {-4 Pi, 20}] ,

Graphics3D[
{AbsolutePointSize@2, circle,
Dynamic @ If[t < -1.9 Pi,
Inset[drop, {0, 0, -(t + 2 Pi)}, Automatic, Scaled[{.03, .05}]],
{}
]
},
ViewVertical -> {0, 0, 1}, ImageSize -> 700,
PlotRange -> {20 {-1, 1}, 20 {-1, 1}, 10 {-1, 1}},
ViewAngle -> Pi/16, Boxed -> False, ViewPoint -> {5, 0, 3},

BoxRatios -> Automatic]}

enter image description here


Comments