Merge branch 'main' of https://gitlab.rconnorjohnstone.com/school/thesis
This commit is contained in:
@@ -44,7 +44,7 @@ function inner_loop(launch_date::DateTime,
|
|||||||
end
|
end
|
||||||
|
|
||||||
time = utc2et(Dates.format(launch_date,"yyyy-mm-ddTHH:MM:SS"))
|
time = utc2et(Dates.format(launch_date,"yyyy-mm-ddTHH:MM:SS"))
|
||||||
thrust_profiles = []
|
thrust_profiles = Vector{Matrix{Float64}}()
|
||||||
|
|
||||||
for phase in phases
|
for phase in phases
|
||||||
planet1_state = [spkssb(ids[phase.from_planet], time, "ECLIPJ2000"); 0.0]
|
planet1_state = [spkssb(ids[phase.from_planet], time, "ECLIPJ2000"); 0.0]
|
||||||
|
|||||||
@@ -47,15 +47,14 @@
|
|||||||
|
|
||||||
# The first leg should be valid
|
# The first leg should be valid
|
||||||
fresh_sc = copy(sc)
|
fresh_sc = copy(sc)
|
||||||
mass, thrusts = inner_loop( launch_date,
|
thrusts = inner_loop( launch_date,
|
||||||
sc,
|
sc,
|
||||||
start_mass,
|
start_mass,
|
||||||
[phase1],
|
[phase1],
|
||||||
verbose=true,
|
verbose=true,
|
||||||
mbh_specs=(25,50) )
|
mbh_specs=(25,50) )
|
||||||
@test sc.mass > sc.dry_mass
|
path, final = prop(thrusts[1], earth_state+[zeros(3);v∞s[1];0.0], Sc("test"), μs["Sun"], leg1_tof)
|
||||||
path, final = prop(thrusts[1], earth_state+[zeros(3);v∞s[1]], fresh_sc, μs["Sun"], leg1_tof)
|
@test final[1:6] ≈ p1_state[1:6] + [zeros(3); v∞s[2]]
|
||||||
@test final ≈ p1_state + [zeros(3); v∞s[2]]
|
|
||||||
savefig(plot_orbits( [earth, p1_path, path],
|
savefig(plot_orbits( [earth, p1_path, path],
|
||||||
primary="Sun",
|
primary="Sun",
|
||||||
labels=["Earth", p1, "Leg 1"],
|
labels=["Earth", p1, "Leg 1"],
|
||||||
|
|||||||
Reference in New Issue
Block a user