Bahninterpolation (Algol)

Deutschsprachige Version
Benutzeravatar
Yukterez
Administrator
Beiträge: 280
Registriert: Mi 21. Okt 2015, 02:16

Bahninterpolation (Algol)

Beitragvon Yukterez » Do 4. Feb 2016, 02:38

Code: Alles auswählen

P[w_] := {Cos[-w 2 π - π/2], Sin[-w 2 π - π/2], 0}
Xyz[{x_, y_, z_}, α_] := {x Cos[α] - y Sin[α], x Sin[α] + y Cos[α], z}
xYz[{x_, y_, z_}, β_] := {x Cos[β] + z Sin[β], y, z Cos[β] - x Sin[β]}
xyZ[{x_, y_, z_}, ψ_] := {x, y Cos[ψ] - z Sin[ψ], y Sin[ψ] + z Cos[ψ]}
Pt[w_] := Xyz[xYz[xyZ[P[w], ψ], β], α]

α = 0;            (* Rotation α *)
β = π/180*43.3;   (* Rotation β *)
ψ = π/180*8.7;    (* Orbit Inclination *)

xr = 1.1;         (* Plot Range *)

plot[w_, {X_, Y_, Z_}] := Show[Graphics3D[{
    {Opacity[0.5], Red, PointSize[0.2/2], Point[{0, 0, 0}]},
    {Opacity[0.5], Orange, PointSize[0.28/2], Point[Pt[w - 2/100]]},
    {Opacity[1], Red, PointSize[0.02], Point[{0, 0, 0}]},
    {Opacity[1], Orange, PointSize[0.028], Point[Pt[w - 2/100]]}
    }, PlotRange -> {{-xr, +xr}, {-xr, +xr}, {-xr, +xr}},
       ViewPoint -> {X, Y, Z}, ImageSize -> 260],
       ParametricPlot3D[Pt[W - 2/100], {W, w - 1/4, w},
       PlotStyle -> Orange]]

animation =
Do[Print[Rasterize[Grid[{{
       Grid[{{plot[w + 1/50, {0, -10 , 0}]},
             {Evaluate[N[w]]}}],
       Grid[{{plot[w, {5, -5 , 5}]}, {" "}}]}}]]],
{w, 0, 1 - 1/200, 1/200}]

(* Code: Yukterez, Syntax: Mathematica *)

Rohmaterial:

Bild

Composite:

Bild
Bild
by Simon Tyran, Vienna @ youtube || rumble || odysee || minds || wikipedia || stackexchange || License: CC-BY 4 ▣ If images don't load: [ctrl]+[F5]Bild

Zurück zu „Yukterez Notizblock“

Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder und 2 Gäste