From e711e88b590291394042321c3bd31d928cdad407 Mon Sep 17 00:00:00 2001
From: Anson " + $('#ref-' + ref).html() + " Simulating the performance of an air propulsion system as an alternative to solid rocket motors.
using Plots
-:ggplot2); # In true R spirit
+ theme(theme(:ggplot2); # In true R spirit
using Unitful
using DataFrames
@@ -1535,11 +1561,11 @@ Show code
= P0 |> u"Pa"
P = V * (P / (R * T)) |> u"kg"
M = 1u"ms"
- ts = DataFrame(Thrust=(0 ± 0)u"N", Pressure=P0, Time=0.0u"s", Mass=M)
- df while M > 0.005u"kg"
+ = DataFrame(Thrust=(0 ± 0)u"N", Pressure=P0, Time=0.0u"s", Mass=M)
+ df while M > 0.005u"kg"
# Calculate what is leaving tank
- = minimum([P, Pmax])
- P = sqrt((2 * γ / (γ - 1)) * R * T * (1 - P_amb / P)^((γ - 1) / γ)) |> u"m/s"
+ ve = minimum([P, Pmax])
+ P = sqrt((2 * γ / (γ - 1)) * R * T * (1 - P_amb / P)^((γ - 1) / γ)) |> u"m/s"
ve = P / (R * T) |> u"kg/m^3"
ρ = ρ * a_nozzle * ve |> u"kg/s"
ṁ
@@ -1550,9 +1576,9 @@ Show code
= (M * R * T) / V |> u"Pa"
P = t + ts
t
- = DataFrame(Thrust=Thrust, Pressure=P, Time=t, Mass=M)
- df_step append!(df, df_step)
- end
+ = DataFrame(Thrust=Thrust, Pressure=P, Time=t, Mass=M)
+ df_step append!(df, df_step)
+ end
dfend
-= df.Thrust .|> ustrip .|> value;
- thrust_values = df.Thrust .|> ustrip .|> uncertainty;
+ thrust_uncertainties = df.Thrust .|> ustrip .|> value;
+ thrust_values = df.Thrust .|> ustrip .|> uncertainty;
thrust_uncertainties
-= DataFrame(Thrust=thrust_values, Uncertainty=thrust_uncertainties, Time=df.Time .|> u"s" .|> ustrip);
+ air = DataFrame(Thrust=thrust_values, Uncertainty=thrust_uncertainties, Time=df.Time .|> u"s" .|> ustrip);
air
-Time .|> ustrip, thrust_values,
+ plot(df.plot(df.Time .|> ustrip, thrust_values,
="Thrust Over Time",
title=(thrust_uncertainties, thrust_uncertainties),
ribbon=.2,label="Thrust",
@@ -1578,7 +1604,7 @@ Show code
fillalpha="Thrust (N)",
ylabel )
Figure 1: Air Proplsion Simulation @@ -1592,22 +1618,22 @@ Figure 1: Air Proplsion Simulation Show code
-= CSV.read("AeroTech_F10.csv", DataFrame);
- f10 = CSV.read("Estes_F15.csv", DataFrame);
- f15 = CSV.read("AeroTech_G8ST.csv", DataFrame);
+ g8 = CSV.read("AeroTech_F10.csv", DataFrame);
+ f10 = CSV.read("Estes_F15.csv", DataFrame);
+ f15 = CSV.read("AeroTech_G8ST.csv", DataFrame);
g8
-Time, air.Thrust, label="Air Propulsion", legend=:topleft);
+ plot(air.plot(air.Time, air.Thrust, label="Air Propulsion", legend=:topleft);
-for (d, l) in [(f10, "F10"), (f15, "F15"), (g8, "G8ST")]
-!(d[!,"Time (s)"], d[!, "Thrust (N)"], label=l);
- plotend
+for (d, l) in [(f10, "F10"), (f15, "F15"), (g8, "G8ST")]
+plot!(d[!,"Time (s)"], d[!, "Thrust (N)"], label=l);
+ end
-!("Propulsion Comparison");
- title!("Time (s)");
- xlabel!("Thrust (N)") ylabel
Figure 2: Rocket Motor Data: (Coker, n.d.) @@ -1619,12 +1645,12 @@ Figure 2: Rocket Motor Data: (After determining that solid model rocket motors are the best option for the current mission scope, the next step is determining what motor to use. There are many great options, and deciding what thrust profile is ideal may have to wait until a Simulink simulation of the landing can be built so that the metrics of each motor can be constrained more. Instead of throttling motors, the current working idea is that thrust vector control may be a way to squeeze a little more control out of a solid rocket motor. Thrust Vector Control will undoubtedly be challenging to control, so another essential piece that needs exploring is whether an LQR controller is feasible or if a PID controller is accurate enough to control our system.
?zM(teKJ?%jeM?a4O{U95|M_E%Y=zF%wEHsvvIXjF5O;*EMtLs;K_s~Fg)+M+
zj6iBth>}Kv;Elh3WK`5=At%{v^*sPR;A1D-)$3nZfU!7UjI+tpSPAB;8!oeag8s0P
zdfXC$6vhxUxaQp49J4}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