示例#1
0
def payload_setup():
    name = "Payload"
    # Constraints
    max_ke = 75.0  # ft lbs
    max_time = 90.0  # sec

    # import parachute data
    pay = parachutes['certL']
    fall = parachutes['freefall']

    # Rocket mission
    initial_state = np.array([4000.0, 0.0])
    phases = 2
    # set up mission parameters
    m_drone = toslugs(1.57, 'lb')
    m_nose = toslugs(2.4, 'lb')  # mass of nose cone (slug)
    m_can = toslugs(9.34, 'lb')  # mass of payload section (slug)
    m_pay = m_can + m_nose
    m_pay_empty = m_can + m_nose
    dt = [0.01, 0.01]  #, 0.01]  # time step for each phase
    mass = [m_pay, m_pay]  #, m_pay_empty]  # mass for each phase
    bc = [600.0, 0.0]  # 400, 0.0]  # altitude breaking conditions
    chutes = [fall, pay]  #, pay]  # parachute used for each phase
    return [
        name, phases, initial_state, dt, bc, mass, chutes, max_time, max_ke
    ]
示例#2
0
def rocket_setup():
    name = "Rocket"
    # import parachutes
    drogue = parachutes['24']
    main = parachutes['certXXL']

    # Constraints
    max_ke = 75.0  # ft lbs
    max_time = 90.0  # sec

    initial_state = np.array([4000.0, 0.0])
    phases = 2
    # set up mission parameters
    dt = [0.01, 0.01]  # time step for each phase
    mid_section = toslugs(17.81, 'lb')
    aft_section = toslugs(14.67 + 4.06, 'lb')
    rocket = mid_section + aft_section  # total rocket mass
    mass = [rocket, rocket]  # mass for each phase
    bc = [600.0, 0.0]  # altitude breaking conditions
    chutes = [drogue, main]  # parachute used for each phase
    return [
        name, phases, initial_state, dt, bc, mass, chutes, max_time, max_ke
    ]
示例#3
0
from tools import toslugs
import numpy as np

name = "Rocket"
drogue = '24'
main = 'certXXL'

# Constraints
max_ke = 75.0  # ft lbs
max_time = 90.0  # sec

initial_state = np.array([4000.0, 0.0])
phases = 2
# set up mission parameters
dt = [0.01, 0.01]  # time step for each phase
mid_section = toslugs(17.81, 'lb')
aft_section = toslugs(14.67 + 4.06, 'lb')
rocket = mid_section + aft_section  # total rocket mass
mass = [rocket, rocket]  # mass for each phase
bc = [600.0, 0.0]  # altitude breaking conditions
chutes = [drogue, main]  # parachute used for each phase

rocket_setup = MissionSetup(name, phases, chutes, mass, bc, dt, initial_state)

name = "Payload"
pay = 'certL'
fall = 'freefall'
# Rocket mission
initial_state = np.array([4000.0, 0.0])
phases = 2
# set up mission parameters
示例#4
0
from tools import toslugs, tofeet
from mission import Mission
from payload_setup import payload_setup
from rocket_setup import rocket_setup
import matplotlib.pyplot as plt

# call mission setups
rocket_mission = rocket_setup()
pay_mission = payload_setup()

# setup the missions
rocket = Mission(rocket_mission)
rocket.run_mission()
rocket.results("Rocket", masses=[toslugs(14.2), toslugs(17.6)])

payload = Mission(pay_mission)
payload.run_mission()
payload.results("Payload", masses=[toslugs(5.795), toslugs(1.875)])

# Plotting results
plt.figure(1)
rocket.plot_path("Rocket Path")
payload.plot_path("Payload Path")
plt.legend()

plt.figure(2)
rocket.plot_vel("Rocket Velocity")
payload.plot_vel("Payload Velocity")
plt.legend()
示例#5
0
diam = tofeet(36.0, 'in')  # ft
cd = 0.75
drg36 = chute.Parachute(cd, None)
drg36.circular_area(diam, update=True)

# cd = 1.21 + 1.17
cd = 4.0
diam = tofeet(7.5, 'in')
pay_free = chute.Parachute(cd, None)
pay_free.circular_area(diam, update=True)

###################### Mains ######################
cd = 1.87
classicII_44 = chute.Parachute(cd, None)
classicII_44.effective_area(17.0, toslugs(4.4, 'lb'), rho, g, update=True)

cd = 1.26
certL = chute.Parachute(cd, None)
certL.effective_area(17.0, toslugs(16.2, 'lb'), rho, g, update=True)

cd = 2.59
certXL = chute.Parachute(cd, None)
certXL.effective_area(17.0, toslugs(32.6, 'lb'), rho, g, update=True)

cd = 2.92
certXXL = chute.Parachute(cd, None)
certXXL.effective_area(17.0, toslugs(60.0, 'lb'), rho, g, update=True)

diam = tofeet(58.0, 'in')
cd = 1.75
示例#6
0
from tools import toslugs
from simulator.mission import Mission
from setup_files.rocket_post_build_space_jam import rocket_setup, payload_setup
import matplotlib.pyplot as plt
import numpy as np

# setup_files the missions class for each independent section
rocket = Mission(rocket_setup)
payload = Mission(payload_setup)

# run simulation
mid_section = toslugs(17.81, 'lb')
aft_section = toslugs(14.67 + 4.06, 'lb')
split = [np.array([mid_section, aft_section]),
         np.array([mid_section, aft_section])]
rocket.run_mission(split=split)

full_pay_section = toslugs(9.34, 'lb')
nose_section = toslugs(2.4, 'lb')
split = [np.array([full_pay_section, nose_section]),
         np.array([full_pay_section, nose_section])]
payload.run_mission(split=split)

# Plotting results
plt.figure(1)
rocket.plot_path("Rocket Path")
payload.plot_path("Payload Path")
plt.legend()

# Printing tables for results
rocket.display('drift')
示例#7
0
###################### Drogues ######################
diam = tofeet(24.0)  # ft
cd = 0.75
drg24 = chute.parachute(cd, None)
drg24.circular_area(diam, update=True)

diam = tofeet(36.0)  # ft
cd = 0.75
drg36 = chute.parachute(cd, None)
drg36.circular_area(diam, update=True)

###################### Mains ######################
cd = 2.59
certXL = chute.parachute(cd, None)
certXL.effective_area(17.0, toslugs(32.6), rho, g, update=True)

cd = 2.92
certXXL = chute.parachute(cd, None)
certXXL.effective_area(17.0, toslugs(60.0), rho, g, update=True)

###################### Payload ######################
cd = 0.5 + 0.3
diam = tofeet(7.5)
pay_free = chute.parachute(cd, None)
pay_free.circular_area(diam, update=True)

diam = tofeet(58.0)
cd = 1.75
pay = chute.parachute(cd, None)
pay.circular_area(diam, update=True)