§AERE 351 Homework 2


Sep 25, 2025

§1.


Given:
x...=4y¨+3x˙5x+2y+8x¨2y˙ \overset{...}{x} = -4 \ddot y + 3 \dot x - 5 x + 2 y + 8 \ddot x - 2 \dot y
y...=5x7y˙+2x¨ \overset{...}{y} = 5 x - 7 \dot y + 2 \ddot x
Definitions:
x1=x,x2=x˙=x˙1,x3=x¨=x˙2y1=y,y2=y˙=y˙1,y3=y¨=y˙2 x_1 = x, \quad x_2 = \dot x = \dot x_1, \quad x_3 = \ddot x = \dot x_2 \\ y_1 = y, \quad y_2 = \dot y = \dot y_1, \quad y_3 = \ddot y = \dot y_2
Substitution:
x˙3=4y3+3x25x1+2y1+8x32y2 \dot x_3 = -4 y_3 + 3 x_2 - 5 x_1 + 2 y_1 + 8 x_3 - 2 y_2
y˙3=5x17y2+2x3 \dot y_3 = 5 x_1 - 7 y_2 + 2 x_3
Definition of zz involving xx and yy:
z=[x1x2x3y1y2y3],z˙=[x˙1x˙2x˙3y˙1y˙2y˙3] z = \begin{bmatrix} x_1 \\ x_2 \\ x_3 \\ y_1 \\ y_2 \\ y_3 \end{bmatrix}, \quad \dot z = \begin{bmatrix} \dot x_1 \\ \dot x_2 \\ \dot x_3 \\ \dot y_1 \\ \dot y_2 \\ \dot y_3 \end{bmatrix}
Identities re-written:
x˙1=x2 \dot x_1 = x_2
x˙2=x3 \dot x_2 = x_3
x˙3=5x1+3x2+8x3+2y12y24y3 \dot x_3 = - 5 x_1 + 3 x_2 + 8 x_3 + 2 y_1 - 2 y_2 - 4 y_3
y˙1=y2 \dot y_1 = y_2
y˙2=y3 \dot y_2 = y_3
y˙3=5x1+2x37y2 \dot y_3 = 5 x_1 + 2 x_3 - 7 y_2
Everything put together in a matrix equation:
[x˙1x˙2x˙3y˙1y˙2y˙3]=[010000001000538224000010000001502070][x1x2x3y1y2y3] \begin{bmatrix} \dot x_1 \\ \dot x_2 \\ \dot x_3 \\ \dot y_1 \\ \dot y_2 \\ \dot y_3 \end{bmatrix} = \begin{bmatrix} 0 & 1 & 0 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & 0 & 0 \\ -5 & 3 & 8 & 2 & -2 & -4 \\ 0 & 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 1 \\ 5 & 0 & 2 & 0 & -7 & 0 \end{bmatrix} \begin{bmatrix} x_1 \\ x_2 \\ x_3 \\ y_1 \\ y_2 \\ y_3 \end{bmatrix}
Hence:
z˙=Az \boxed{\dot z = A z}
Where:
A=[010000001000538224000010000001502070] \boxed{A = \begin{bmatrix} 0 & 1 & 0 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & 0 & 0 \\ -5 & 3 & 8 & 2 & -2 & -4 \\ 0 & 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 1 \\ 5 & 0 & 2 & 0 & -7 & 0 \end{bmatrix}}
Given:
r¨=μr3r \ddot r = \frac{\mu}{r^3} r
The flattening:
x1=x,x2=x˙=x˙1,x3=x¨=x˙2y1=y,y2=y˙=y˙1,y3=y¨=y˙2z1=z,z2=z˙=z˙1,z3=z¨=z˙2 x_1 = x, \quad x_2 = \dot x = \dot x_1, \quad x_3 = \ddot x = \dot x_2 \\ y_1 = y, \quad y_2 = \dot y = \dot y_1, \quad y_3 = \ddot y = \dot y_2 \\ z_1 = z, \quad z_2 = \dot z = \dot z_1, \quad z_3 = \ddot z = \dot z_2
The contents of rr:
r=[xyz] r = \begin{bmatrix} x \\ y \\ z \end{bmatrix}
Packing rr into a column vector:
w=[rr˙]    [xyzx˙y˙z˙] w = \begin{bmatrix} r \\ \dot r \end{bmatrix} \implies \begin{bmatrix} x \\ y \\ z \\ \dot x \\ \dot y \\ \dot z \end{bmatrix}
w˙=[r˙r¨]    [x˙y˙z˙x¨y¨z¨]=[x2y2z2x3y3z3]=[x2y2z2μr3x1μr3y1μr3z1] \dot w = \begin{bmatrix} \dot r \\ \ddot r \end{bmatrix} \implies \begin{bmatrix} \dot x \\ \dot y \\ \dot z \\ \ddot x \\ \ddot y \\ \ddot z \end{bmatrix} = \begin{bmatrix} x_2 \\ y_2 \\ z_2 \\ x_3 \\ y_3 \\ z_3 \end{bmatrix} = \begin{bmatrix} x_2 \\ y_2 \\ z_2 \\ \frac{\mu}{r^3} x_1 \\ \frac{\mu}{r^3} y_1 \\ \frac{\mu}{r^3} z_1 \end{bmatrix}
Resolving r3r^3:
r3=r3=(x2+y2+z2)3=(x2+y2+z2)3/2 r^3 = |r|^3 = \left( \sqrt{x^2 + y^2 + z^2} \right)^3 = (x^2 + y^2 + z^2)^{3/2}
MATLAB code:
r_0 = [5000; 10000; 2100]; r_dot_0 = [-5; 2; 1.5]; w_0 = [r_0; r_dot_0]; T = 4 * 60 * 60; % the default settings for ode45 are too lax options = odeset('RelTol', 1e-9, 'AbsTol', 1e-10); [t, y] = ode45(@orbit, [0, T], w_0, options); plot3(y(:, 1), y(:, 2), y(:, 3)); xlabel('x (km)'); ylabel('y (km)'); zlabel('z (km)'); grid on; final_state = y(end, 1:3); disp(final_state); % ode45 gives the time in the first argument but my intellisense complains % if I put a t there and don't use it so I have used ~ here function dw_dt = orbit(~, w) % matlab complains if I declare this above like all other constants mu = 3.98 * 10 ^ 5; r = w(1:3); r_dot = w(4:6); % I am sure there's a built in function for this but I like component-wise r_cubed = (r(1) ^ 2 + r(2) ^ 2 + r(3) ^ 2) ^ (3/2); r_ddot = (-mu .* r) ./ r_cubed; dw_dt = [r_dot; r_ddot]; end
MATLAB881B
Plot:
Console output:
1.0e+03 * -8.5505 -3.5230 0.4822
37B

§2.


m=0.2kg m = 0.2kg
l=3m l = 3m
mbeam=0 m_\text{beam} = 0
c=0.06 c = 0.06
g=9.81m/s2 g = 9.81m/s^2
Free body diagram:
Sum of forces:
Fx=cv+mgsinθ=ma \sum F_x = cv + mg \sin \theta = -ma
cmv+gsinθ=a \frac{c}{m} v + g \sin \theta = -a
And assuming things stay in radians, dividing the velocity and acceleration of the tangential component by the length of the beam will result in the angular velocity and acceleration respectively:
cmθ˙+glsinθ=θ¨ \frac{c}{m} \dot \theta + \frac{g}{l} \sin \theta = -\ddot \theta
Rearranging stuff recovers the target equation:
θ¨+glsinθ+cmθ˙=0 \boxed{\ddot \theta + \frac{g}{l} \sin \theta + \frac{c}{m} \dot \theta = 0}
However, this will be more useful for the matrix form:
θ¨=glsinθcmθ˙ \ddot \theta = - \frac{g}{l} \sin \theta - \frac{c}{m} \dot \theta
Matrix form:
x1=θ x_1 = \theta
x2=θ˙=x˙1 x_2 = \dot \theta = \dot x_1
x˙2=glsinx1cmx2 \dot x_2 = - \frac{g}{l} \sin x_1 - \frac{c}{m} x_2
w=[x1x2],w˙=[x2glsinx1cmx2] \boxed{w = \begin{bmatrix} x_1 \\ x_2 \end{bmatrix}, \quad \dot w = \begin{bmatrix} x_2 \\ - \frac{g}{l} \sin x_1 - \frac{c}{m} x_2 \end{bmatrix}}
This can be plugged directly into MATLAB with ode45 and the following conditions:
t0=0,t1=15s t_0 = 0, \quad t_1 = 15s
θ0=60° \theta_0 = -60\degree
The code:
l = 3; theta_0 = -60 * (pi / 180); t_0 = 0; t_1 = 15; [t, w] = ode45(@pendulum, [t_0, t_1], [theta_0, 0]); plot(t, w(:, 1) * l, 'b', 'DisplayName', 'Position (m)'); hold on; plot(t, w(:, 2) * l, 'r', 'DisplayName', 'Velocity (m/s)'); legend('show'); xlabel('Time (s)'); ylabel('Position and Velocity (see respective units)'); grid on; function dw_dt = pendulum(~, w) l = 3; g = 9.81; c = 0.06; m = 0.2; x_1_dot = w(2); x_2_dot = (-g / l) * sin(w(1)) - (c / m) * w(2); dw_dt = [x_1_dot; x_2_dot]; end
MATLAB534B
The plot:
Looks about right! Time to move onto Runge-Kutta of order 4. My updated script to handle Runge-Kutta of order 4 with the ode45 function both at once:
l = 3; theta_0 = -60 * (pi / 180); t_0 = 0; t_1 = 15; dt = 0.5; [t, w] = ode45(@pendulum, [t_0, t_1], [theta_0, 0]); [t_rk, w_rk] = rk4(@pendulum, [t_0, t_1], [theta_0, 0], dt); plot(t, w(:, 1) * l, 'b', 'DisplayName', 'Position (m)'); hold on; plot(t, w(:, 2) * l, 'r', 'DisplayName', 'Velocity (m/s)'); plot(t_rk, w_rk(:, 1) * l, '--b', 'DisplayName', 'RK4 Position (m)'); hold on; plot(t_rk, w_rk(:, 2) * l, '--r', 'DisplayName', 'RK4 Velocity (m/s)'); legend('show'); xlabel('Time (s)'); ylabel('Position and Velocity (see respective units)'); grid on; function [t, w] = rk4(f, t_span, w0, dt) tn = t_span(1); wn = w0(:)'; % I initially did a for look until the dt's added up to t_span(2) % but that gave the w and t arrays mismatching sizes N = ceil((t_span(2) - t_span(1)) / dt); w = zeros(N + 1, length(wn)); t = zeros(N + 1, 1); t(1) = tn; w(1, :) = wn; for i = 1:N % transposing every time here is really bad for performance % but it will suffice for a homework k1 = f(tn, wn).'; k2 = f(tn + dt / 2, wn + (dt / 2) * k1).'; k3 = f(tn + dt / 2, wn + (dt / 2) * k2).'; k4 = f(tn + dt, wn + dt * k3).'; wn = wn + (dt / 6) * (k1 + 2 * k2 + 2 * k3 + k4); tn = tn + dt; w(i + 1, :) = wn; t(i + 1) = tn; end end function dw_dt = pendulum(~, w) l = 3; g = 9.81; c = 0.06; m = 0.2; x_1_dot = w(2); x_2_dot = (-g / l) * sin(w(1)) - (c / m) * w(2); dw_dt = [x_1_dot; x_2_dot]; end
MATLAB1545B
The plot:

§3.


Given:
mS=2000kg m_S = 2000kg
rS=42200km r_S = 42200km
mE=5.96361024kg m_E = 5.9636 * 10^{24} kg
rM=384400km r_M = 384400km
gEgM=6 \frac{g_E}{g_M} = 6
RMRE=0.27 \frac{R_M}{R_E} = 0.27
From the Internet:
G=6.674301011Nm2kg2 G = 6.67430 * 10^{-11} \frac{N * m^2}{kg^2}
RE=6378km R_E = 6378 km
The force between the satellite and the Earth can be calculated right away:
F=Gm1m2r2=GmSmE(rS+RE)2 F = G \frac{m_1 m_2}{r^2} = G \frac{m_S m_E}{(r_S + R_E)^2}
FES=6.674301011Nm2kg22000kg5.96361024kg(6378km+42200km)2=337.34N F_{ES} = 6.67430 * 10^{-11} \frac{N * m^2}{kg^2} * \frac{2000kg * 5.9636 * 10^{24} kg}{(6378km + 42200km)^2} = \boxed{337.34N}
For the force between the Moon and Earth, I will need the mass of the Moon first. The force on an object of mass mm at the surface of a planet of mass MM and radius RR should be:
F=GmMR2 F = G \frac{m M}{R^2}
Newton's second law:
F=ma=mg=GmMR2 F = ma = \cancel{m}g = G \frac{\cancel{m} M}{R^2}
g=GMR2 g = \frac{GM}{R^2}
Applying this to the given ratio:
gEgM=6=GmERE2RM2GmM=mEmMRM2RE2 \frac{g_E}{g_M} = 6 = \frac{\cancel{G} m_E}{R_E^2} \frac{R_M^2}{\cancel{G} m_M} = \frac{m_E}{m_M} \frac{R_M^2}{R_E^2}
The mass of the Moon can be solved for now:
mM=mEgMgERM2RE2 m_M = m_E \frac{g_M}{g_E} \frac{R_M^2}{R_E^2}
mM=5.96361024kg160.272=7.2461022kg m_M = 5.9636 * 10^{24} kg * \frac{1}{6} * 0.27^2 = 7.246 * 10^{22} kg
Now, the force between the two:
F=GmEmMrM2 F = G \frac{m_E m_M}{r_M^2}
FEM=6.674301011Nm2kg25.96361024kg7.2461022kg(384400km)2=1.95181020N F_{EM} = 6.67430 * 10^{-11} \frac{N * m^2}{kg^2} * \frac{5.9636 * 10^{24} kg * 7.246 * 10^{22} kg}{(384400km)^2} = \boxed{1.9518 * 10^{20} N}
The force on the satellite from the Moon:
FMS=GmMmS(rMrS)2 F_{MS} = G \frac{m_M m_S}{(r_M - r_S)^2}
FMS=6.674301011Nm2kg27.2461022kg2000kg(384400km42200km)2=0.0826N F_{MS} = 6.67430 * 10^{-11} \frac{N * m^2}{kg^2} * \frac{7.246 * 10^{22} kg * 2000kg}{(384400km - 42200km)^2} = 0.0826N
And as for the percentage comparing the Moon's effect on the satellite vs. the Earth's:
γEM=FMSFES100%=0.0826N337.34N100%=0.0245% \gamma_{EM} = \frac{F_{MS}}{F_{ES}} * 100\% = \frac{0.0826N}{337.34N} * 100\% = \boxed{0.0245\%}
Safe to say, the Moon can be ignored in this orbit for low fidelity calculations. Now it's time to evaluate the Sun's effect on the moon vs Earth's. Given:
mSu=1.98911030kg m_{Su} = 1.9891 * 10^{30} kg
From the Internet:
rSu=149.6106km r_{Su} = 149.6 * 10^6 km
Because of how far away the Sun is, the Earth's radius is practically the average radius of the moon around the Sun:
FSuM=GmSumMrSu2 F_{SuM} = G \frac{m_{Su} m_M}{r_{Su}^2}
FSuM=6.674301011Nm2kg21.98911030kg7.2461022kg(149.6106km)2=4.2981020N F_{SuM} = 6.67430 * 10^{-11} \frac{N * m^2}{kg^2} * \frac{1.9891 * 10^{30} kg * 7.246 * 10^{22} kg}{(149.6 * 10^6 km)^2} = \boxed{4.298 * 10^{20} N}
γSuE=FSuMFEM=4.2981020N1.95181020N=2.2=220% \gamma_{SuE} = \frac{F_{SuM}}{F_{EM}} = \frac{4.298 * 10^20 N}{1.9518 * 10^{20} N} = \boxed{2.2 = 220\%}
This is significant. I was not anticipating this! I was expecting it to be less than 1%.

§4.


The force between the two upon each other:
Fgravity=Gmmd2=Gm2d2 F_\text{gravity} = G \frac{m m}{d^2} = G \frac{m^2}{d^2}
There exists an imaginary point in the middle about which both the object rotate with a radius rr:
r=12d r = \frac{1}{2}d
The centrifugal force on one of the objects orbiting this imaginary center:
Fcentrifugal=mω2r=12mω2d F_\text{centrifugal} = m \omega^2 r = \frac{1}{2} m \omega^2 d
Both the forces are opposite and equal:
FgravityFcentrifugal=matangential F_\text{gravity} - F_\text{centrifugal} = m a_\text{tangential}
Since the planets never leave the orbit, they will never have a tangential acceleration.
FgravityFcentrifugal=0    Fcentrifugal=Fgravity F_\text{gravity} - F_\text{centrifugal} = 0 \implies F_\text{centrifugal} = F_\text{gravity}
12mω2d=Gm2d2 \frac{1}{2} m \omega^2 d = G \frac{m^2}{d^2}
The question asks for the angular velocity:
ω2=2Gm2d2md=2Gmd3 \omega^2 = 2 G \frac{m^2}{d^2 m d} = 2 G \frac{m}{d^3}
ω=2Gmd3 \boxed{\omega = \sqrt{\frac{2 G m}{d^3}}}

§5.


This problem seems to be identical to the one before, but just with trigonometry now. The contribution of object 11 on object 33:
F1=Gm2d02[sin30°cos30°] F_1 = G \frac{m^2}{d_0^2} \begin{bmatrix} - \sin 30 \degree \\ - \cos 30 \degree \end{bmatrix}
Object 22 applies a similar force on object 33:
F2=Gm2d02[sin30°cos30°] F_2 = G \frac{m^2}{d_0^2} \begin{bmatrix} \sin 30 \degree \\ - \cos 30 \degree \end{bmatrix}
The sum of the forces on object 33:
F=F1+F2=Gm2d02[02cos30°] F = F_1 + F_2 = G \frac{m^2}{d_0^2} \begin{bmatrix} 0 \\ - 2 \cos 30 \degree \end{bmatrix}
For simplicity sake, since object 33 is vertically aligned with the center of mass and the only component of the force is in the yy axis, it's okay to omit the xx component and just worry about the happenings of the yy components now:
Fgravity=2Gm2d02cos30° F_\text{gravity} = -2 G \frac{m^2}{d_0^2} \cos 30 \degree
Meanwhile, the centrifugal force is similar to what I used in the previous problem:
Fcentrifugal=mω2r=23mω2h F_\text{centrifugal} = m \omega^2 r = \frac{2}{3} m \omega^2 h
The positive sign here means up. The sum of the forces is 00 again for the same reason as before, but this time the signs are built into the forces so I haven't added them again here:
Fgravity+Fcentrifugal=0 F_\text{gravity} + F_\text{centrifugal} = 0
2Gm2d02cos30°+23mω2h=0 -2 G \frac{m^2}{d_0^2} \cos 30 \degree + \frac{2}{3} m \omega^2 h = 0
23mω2h=2Gm2d02cos30° \frac{2}{3} m \omega^2 h = 2 G \frac{m^2}{d_0^2} \cos 30 \degree
ω2=3Gmd02hcos30° \omega^2 = 3 G \frac{m}{d_0^2 h} \cos 30 \degree
ω=3Gmd02hcos30° \omega = \sqrt{3 G \frac{m}{d_0^2 h} \cos 30 \degree}
Oh, and I almost forgot, the cos\cos is analytically simplifiable:
ω=332Gmd02h \boxed{\omega = \sqrt{\frac{3 \sqrt{3}}{2} G \frac{m}{d_0^2 h}}}