Info
Questa domanda è chiusa. Riaprila per modificarla o per rispondere.
How to code Epicycles?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Epicycles. Write a program, epicycles.m, to draw circular motion with one epicycle, as illustrated in Figure 6.4. The object moves around the origin with a period T1 and around the center of the epicycle with a period T2. The radius of the primary orbit is R and of the epicycle is r. The angular frequency of each orbit is: ω1 = 2π/T1 and ω2 = 2π/T2. The x and y coordinates of the motion are given by (convince yourself of this): x(t) = r cos(ω1t) + r cos(ω2t) and y(t) = r sin(ω1t) + r sin(ω2t). Let R=5 and r =2 initially. Let T1 =1 and T2 =T1/tratio. Start with tratio = 9.25. Let the number of large cycles be Nc (initially 10, say). Let the number of time points per cycle be Ntpc (initially 200). The total time is Nc*T1 and the total number of times for which you calculate the position is Nt=Nc*Ntpc. Calculate the frequencies omega1 and omega2. For each time in the interval [0,Tf] (say loop index it goes from 1 to Nt), calculate x(it) and y(it). Plot the position of the object and a line tracing its path from the beginning to its present position. I am really confused on how to go about this, I have done everything its given but the plot is not what it seems.
0 Commenti
Risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!