HA5 A12: Rotationsparaboloid

by Jan Totz, jantotz@itp.tu.berlin.de

Numerik

lagrangianEquations[kin_,pot_,Q_:0,genCoords_List]:=Module[
{L=kin-pot},
(D[D[L,D[#,t]],t] == Q + D[L,#])& /@ genCoords
];

Profil des Rotationskörpers wählen

z[r_]:=a r;                           (** cone **)

z[r_]:=a r^2;                     (** paraboloid **)

z[r_]:=r^4-r^2+0.5; (** mexican hat **)

genCoords0={r,ϕ};
genCoords=#[t]&/@genCoords0;
kin=m/2 (r'[t]^2(1.0+D[z[r[t]],r[t]]^2)+r[t]^2ϕ'[t]^2 );
pot=m g z[r[t]];

lagrangianEquations[kin,pot,0,genCoords]

tfinal=100.0;
{m,g,a}={1.0,9.81,1.0};
ic={r[0]==1.0,r'[0]==0.0,ϕ[0]==0.0,ϕ'[0]==1.0};
sol=NDSolve[{lagrangianEquations[kin,pot,0,genCoords],ic},genCoords0,{t,0,tfinal}];

perfekter Plot für Hausaufgaben

plot=Show[
ParametricPlot3D[Evaluate[{r[t] Cos[ϕ[t]],r[t] Sin[ϕ[t]],z[r[t]]}/.sol],{t,0,tfinal},ImageSize->500,PlotRange->{1.2{-1,1},1.2{-1,1},{0,1.4}},ViewPoint->{-2.4309600120876804`,-1.2243054021718944`,2.0103506415158985`},ViewVertical->{-0.012823185242416747`,-0.017724532197335066`,1.7138754425160627`},AxesLabel->{" x","y","z"},LabelStyle->Directive[Black,18]],
RevolutionPlot3D[z[r],{r,0,1.1},(*Mesh->None,*)PlotStyle->Opacity[0.5]]
]

Animation des Teilchens im Rotationskörper

Manipulate[
Show[
ParametricPlot3D[Evaluate[{r[t] Cos[ϕ[t]],r[t] Sin[ϕ[t]],z[r[t]]}/.sol],{t,0,tt},ImageSize->500,PlotRange->{1.2{-1,1},1.2{-1,1},{0,1.4}},ViewPoint->{-2.2187586815375675`,-2.308281081210128`,1.0949650054814908`},ViewVertical->{-0.21576257163055168`,-0.23687810985064248`,1.6239048392560518`},AxesLabel->{" x","y","z"},LabelStyle->Directive[Black,18],PerformanceGoal->"Quality"],
Graphics3D[{ColorData[97,1],Ball[{r[tt] Cos[ϕ[tt]],r[tt] Sin[ϕ[tt]],z[r[tt]]}/.sol,0.02]}],
RevolutionPlot3D[z[r],{r,0,1.1},(*Mesh->None,*)PlotStyle->Opacity[0.5],PerformanceGoal->"Quality"]
]
,{{tt,0.1,"time t"},0.1,tfinal,0.001,Appearance->"Open",AnimationRate->1},TrackedSymbols:>{tt}]

Bewegung mit Rotationfreiheitsgraden des Massekörpers (unfertig)