Emergency abort system for spacecraft flight
This project presents a model of a spacecraft flight emergency abort system based on the Finite Automata library, designed for visual design of the control logic of complex technical systems.
Using a macro @__DIR__ to define a path containing an interactive script:
demoroot = @__DIR__;
System requirements
If a malfunction of the spacecraft is detected, an emergency flight interruption must be carried out.
Depending on the altitude gained, the spacecraft may:
- Return to the launch site (RTLS mode, Return to launch site):
- Provided that the altitude is less than 10,000 m.
- Fuel must be discharged, the side boosters and the external fuel tank must be separated.
- Make an emergency landing on a pre-prepared pad (DRL mode, Downrange landing):
- Provided that the altitude is in the range from 10,000 m to 100,000 m.
- The side boosters and the external fuel tank must be separated.
- Make an emergency landing after one orbit around the Earth (AOA, Abort once around mode):
- Provided that the altitude is in the range from 100,000 m to 400,000 m.
- The external fuel tank must be separated.
- Achieve stable orbit (ATO mode, Abort to orbit):
- Provided that the altitude is more than 400,000 m.
Thus, if the altitude and speed of the vehicle do not allow for a return to the launch site, DRL mode is initiated. If the device could not achieve a stable orbit, but gained sufficient speed to complete a revolution around the Earth, the AOA mode is activated. If the target orbit cannot be reached, but it is possible to reach a lower stable orbit, the ATO command is sent on board.
An example of managing modes
The control panel for emergency flight interruption modes of the Challenger shuttle (photo taken during flight STS-51-F):
During the launch of the spacecraft, the sensors of the shuttle's engines failed, after which one of the three main engines was turned off. This is the only incident in all shuttle flights classified as "Reaching a stable orbit."
Description of the model
Model of the emergency flight abort system launch_abort_system.engee It consists of a subsystem for selecting the active scenario scenario_selection and a finite state machine launch_abort_controller, which implements the control logic:
At the entrance of the block launch_abort_controller Signals are coming in:
alt- the height of the spacecraft.anomaly- a sign of a malfunction.
Block output signals launch_abort_controller:
dumpFuel- fuel discharge indicator.releaseBoosters- a sign of separation of the side boosters.releaseTank- indicates the separation of the external fuel tank.
The emergency flight abort controller consists of two parallel states ModeLogic and Abort.
Condition ModeLogic determines the acceptable emergency flight abort mode depending on the current altitude of the spacecraft.:
Condition Abort controls the device when a malfunction is detected:
If the input signal is anomaly takes the value true, the system is transitioning from Normal in the state of AbortLogic, which implements the logic of flight interruption - fuel discharge, separation of the side boosters and the external fuel tank.
Coordination of parallel states (i.e. determining the mode selected in the state ModeLogic) is performed using the operator in().
The operator of temporal logic after() allows you to make a transition between states FuelDump, BoosterRelease and TankRelease 10 clock cycles after their activation.
Condition NoActionRequired corresponds to the mode ATO.
Entering and exiting the state AbortLogic implemented on the basis of super transitions.
Subsystem for selecting an active scenario scenario_selection It consists of blocks for loading data from the workspace and a variant source that determines the values of the signals. altitude and anomaly based on the truth of a logical expression:
Settings for a variant source:
The value of the variable active_scenario it will be determined before starting the simulation (based on the drop-down list in the mask of the code cell of the interactive script).
Emergency flight abort scenarios
Let's define the values of the signals anomaly and altitude for various emergency flight abort scenarios in the form of variables like WorkspaceArray.
RTLS mode
RTLS_anomaly_time = [0.0, 10.0, 10.0, 136.0];
RTLS_anomaly_value = [0.0, 0.0, 1.0, 1.0];
RTLS_altitude_time = [0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0, 25.0, 26.0, 27.0, 28.0, 29.0, 30.0, 31.0, 32.0, 33.0, 34.0, 35.0, 36.0, 37.0, 38.0, 39.0, 40.0, 41.0, 42.0, 43.0, 44.0, 45.0, 46.0, 47.0, 48.0, 49.0, 50.0, 51.0, 52.0, 53.0, 54.0, 55.0, 56.0, 57.0, 58.0, 59.0, 60.0, 61.0, 62.0, 63.0, 64.0, 65.0, 66.0, 67.0, 68.0, 69.0, 70.0, 71.0, 72.0, 73.0, 74.0, 75.0, 76.0, 77.0, 78.0, 79.0, 80.0, 81.0, 82.0, 83.0, 84.0, 85.0, 86.0, 87.0, 88.0, 89.0, 90.0, 91.0, 92.0, 93.0, 94.0, 95.0, 96.0, 97.0, 98.0, 99.0, 100.0, 101.0, 102.0, 103.0, 104.0, 105.0, 106.0, 107.0, 108.0, 109.0, 110.0, 111.0, 112.0, 113.0, 114.0, 115.0, 116.0, 117.0, 118.0, 119.0, 120.0, 121.0, 122.0, 123.0, 124.0, 125.0, 126.0, 127.0, 128.0, 129.0, 130.0, 131.0, 132.0, 133.0, 134.0, 135.0, 136.0];
RTLS_altitude_value = [0.0, 238.83418401927727, 473.82790161180975, 706.627066960488, 934.4884897604945, 1155.7662558289385, 1368.8144509829292, 1571.987161039576, 1739.1879956908977, 1863.4500084748431, 1971.2869080588416, 2071.2716641032416, 2164.6229115772194, 2278.2716398435027, 2421.28127268735, 2570.4964570329994, 2715.1505439327766, 2830.412157103741, 2923.5750342421434, 3023.184393769722, 3129.9367163790193, 3249.5898448793996, 3408.8300113444957, 3600.465782838117, 3794.3016946679513, 3986.238468840256, 4166.585340339876, 4307.345173874779, 4414.489404298698, 4513.151229927636, 4601.026833688474, 4681.536327982139, 4776.538637939075, 4870.94703061685, 4935.830300786651, 4978.674368023556, 5003.816562756626, 5013.284895255117, 5014.967054543678, 5014.967054543678, 5011.804490770724, 5005.482083164423, 4999.46368486074, 4996.4133770985045, 4995.747216056592, 4995.747216056592, 4996.417934636157, 4997.989644250674, 4999.664143288303, 5000.597652657715, 5000.695848528347, 5000.685990535441, 5000.662036769181, 5000.355686205225, 5000.201844608568, 5000.507180581901, 5001.164648152473, 5001.795481969884, 5001.933780418543, 5001.820273687701, 5001.416741843737, 4999.81521449166, 4997.008981225274, 4994.053575497205, 4991.884217505219, 4991.884217505219, 4992.838135279628, 4995.489654871515, 5003.187707967534, 5013.576220869276, 5020.802913160951, 5020.802913160951, 5020.326793018041, 5014.086470774979, 4986.353228819495, 4933.680790345622, 4857.003118546842, 4746.269936688438, 4602.493718790893, 4444.599578678139, 4290.045324860334, 4166.722996659114, 4072.37505511064, 3990.4204229175475, 3922.330097188704, 3859.539360441905, 3778.087948117197, 3683.1690715240757, 3610.2592980411655, 3551.795060613914, 3482.691553248512, 3399.607932792115, 3298.7836731884213, 3159.082645326051, 2982.940994801094, 2793.861637095698, 2597.1490557978527, 2398.1077344955465, 2237.8087623579167, 2117.913203197453, 2002.918701784611, 1894.6558131562974, 1793.867406770269, 1664.3076418205474, 1507.9185981752182, 1362.5836700618195, 1232.0941727690831, 1132.7481600611118, 1057.8445246935014, 988.1012651163192, 922.6072048975066, 855.6314594286775, 768.4452143565462, 672.9086146738782, 599.0409178963897, 537.9099739741458, 476.0085956994564, 414.6186482018665, 349.1332248834753, 271.06822753905976, 198.99626302395365, 147.87338676747203, 111.34081225111692, 88.88075132576502, 77.87818232677606, 67.87818232677606, 57.87818232677604, 52.0500788270874, 45.59954907462388, 36.60253222779843, 26.602532227798427, 16.602532227798427, 7.130396358607671, 1.0, 1.0, 1.0, 1.0];
RTLS_anomaly = WorkspaceArray("wa_RTLS_anomaly", DataFrame(time = RTLS_anomaly_time, value = RTLS_anomaly_value));
RTLS_altitude = WorkspaceArray("wa_RTLS_altitude", DataFrame(time = RTLS_altitude_time, value = RTLS_altitude_value));
DRL mode
DRL_anomaly_time = [0.0, 41.0, 41.0, 136.0];
DRL_anomaly_value = [0.0, 0.0, 1.0, 1.0];
DRL_altitude_time = [0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0, 25.0, 26.0, 27.0, 28.0, 29.0, 30.0, 31.0, 32.0, 33.0, 34.0, 35.0, 36.0, 37.0, 38.0, 39.0, 40.0, 41.0, 42.0, 43.0, 44.0, 45.0, 46.0, 47.0, 48.0, 49.0, 50.0, 51.0, 52.0, 53.0, 54.0, 55.0, 56.0, 57.0, 58.0, 59.0, 60.0, 61.0, 62.0, 63.0, 64.0, 65.0, 66.0, 67.0, 68.0, 69.0, 70.0, 71.0, 72.0, 73.0, 74.0, 75.0, 76.0, 77.0, 78.0, 79.0, 80.0, 81.0, 82.0, 83.0, 84.0, 85.0, 86.0, 87.0, 88.0, 89.0, 90.0, 91.0, 92.0, 93.0, 94.0, 95.0, 96.0, 97.0, 98.0, 99.0, 100.0, 101.0, 102.0, 103.0, 104.0, 105.0, 106.0, 107.0, 108.0, 109.0, 110.0, 111.0, 112.0, 113.0, 114.0, 115.0, 116.0, 117.0, 118.0, 119.0, 120.0, 121.0, 122.0, 123.0, 124.0, 125.0, 126.0, 127.0, 128.0, 129.0, 130.0, 131.0, 132.0, 133.0, 134.0, 135.0, 136.0];
DRL_altitude_value = [0.0, 298.0918059881316, 593.2168514777068, 886.6466052538208, 1176.2619526746478, 1457.109994865068, 1679.0177925432465, 1846.4297386890717, 2009.5713890124762, 2169.2929969245324, 2331.635662807361, 2549.369944330823, 2822.1584837840783, 3105.392177607269, 3396.3520964910867, 3634.0094306082583, 3825.2687997429975, 4033.4369901398118, 4259.1715623258815, 4509.361535531119, 4846.442723276801, 5262.154423246115, 5689.07068043535, 6119.651679331526, 6546.357604421659, 6961.648640192767, 7336.9432895652535, 7625.388790817116, 7850.329465575045, 8056.224642229942, 8243.36417674694, 8436.730493879484, 8683.228170245135, 8963.21558633446, 9239.587003095525, 9500.075245061736, 9706.708927929192, 9883.150151423823, 10074.25573647291, 10278.213638809317, 10510.0796510681, 10804.499815561687, 11128.37273141273, 11421.288317382583, 11658.167923334842, 11826.30191107606, 11937.218894321315, 11999.240354829984, 12017.952190047858, 12017.952190047858, 12017.952190047858, 12011.457518787653, 12000.946186250236, 11997.029773218092, 11997.029773218092, 11997.02977321809, 11999.121247755274, 12001.754332339717, 12001.88897928284, 12001.88897928284, 12001.880226431687, 11999.595782832, 11998.31362139505, 11998.31362139505, 11998.31362139505, 12002.896532615214, 12009.853784976738, 12010.180918146676, 12010.180918146676, 12002.326874880055, 11957.454428093311, 11863.440021029117, 11715.081980957797, 11498.756593987368, 11218.125029071813, 10897.408693584666, 10585.816340871193, 10334.174380942513, 10120.340658601193, 9914.524556645218, 9721.250345069453, 9510.146717920625, 9244.417490968292, 8955.42782357927, 8677.384115513669, 8431.67295099431, 8242.776578143139, 8082.225756638946, 7920.0116944856545, 7754.926514379689, 7560.633153136476, 7308.8719910622285, 7025.508004296224, 6739.118828042508, 6476.54942635223, 6270.842787595443, 6096.70742895015, 5922.420735960909, 5748.416795175865, 5549.140603426964, 5292.745179660741, 5005.6240604492905, 4720.50796043164, 4462.263916324462, 4261.5401080733645, 4093.5391267010755, 3927.287793164557, 3762.131293260738, 3572.3741326613044, 3325.8859703314924, 3045.3283506819002, 2758.884884711378, 2493.0882128446206, 2282.8453734440545, 2100.0639461634805, 1910.3658030856532, 1716.8559372198224, 1496.6024877318114, 1221.5834397496067, 930.0604810097218, 669.8652507196172, 469.0875560234799, 329.34100551149106, 229.18476252229578, 164.90963145929058, 129.75702961532502, 99.75702961532502, 69.5690580284263, 49.85010557336069, 36.03339891362815, 26.033398913628137, 16.033398913628137, 5.315210626608653, -0.7438897386855101, -1.8595036656778174, -3.0991727761296954, 0.0];
DRL_anomaly = WorkspaceArray("wa_DRL_anomaly", DataFrame(time = DRL_anomaly_time, value = DRL_anomaly_value));
DRL_altitude = WorkspaceArray("wa_DRL_altitude", DataFrame(time = DRL_altitude_time, value = DRL_altitude_value));
AOA mode
AOA_anomaly_time = [0.0, 70.0, 70.0, 136.0];
AOA_anomaly_value = [0.0, 0.0, 1.0, 1.0];
AOA_altitude_time = [0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0, 25.0, 26.0, 27.0, 28.0, 29.0, 30.0, 31.0, 32.0, 33.0, 34.0, 35.0, 36.0, 37.0, 38.0, 39.0, 40.0, 41.0, 42.0, 43.0, 44.0, 45.0, 46.0, 47.0, 48.0, 49.0, 50.0, 51.0, 52.0, 53.0, 54.0, 55.0, 56.0, 57.0, 58.0, 59.0, 60.0, 61.0, 62.0, 63.0, 64.0, 65.0, 66.0, 67.0, 68.0, 69.0, 70.0, 71.0, 72.0, 73.0, 74.0, 75.0, 76.0, 77.0, 78.0, 79.0, 80.0, 81.0, 82.0, 83.0, 84.0, 85.0, 86.0, 87.0, 88.0, 89.0, 90.0, 91.0, 92.0, 93.0, 94.0, 95.0, 96.0, 97.0, 98.0, 99.0, 100.0, 101.0, 102.0, 103.0, 104.0, 105.0, 106.0, 107.0, 108.0, 109.0, 110.0, 111.0, 112.0, 113.0, 114.0, 115.0, 116.0, 117.0, 118.0, 119.0, 120.0, 121.0, 122.0, 123.0, 124.0, 125.0, 126.0, 127.0, 128.0, 129.0, 130.0, 131.0, 132.0, 133.0, 134.0, 135.0, 136.0];
AOA_altitude_value = [0.0, 2785.921275281699, 5314.497101501311, 7314.497101501311, 8900.475460334066, 10421.203513621582, 11922.305335863419, 13652.710996071612, 15652.710996071612, 17506.369667867322, 19310.380888339918, 21429.93026527767, 23883.169934730176, 27048.620513298272, 31227.00392209639, 35982.89079945362, 40719.295263941734, 44535.64993428104, 47545.35858107984, 50475.334622653834, 53279.623850601994, 56126.25710591658, 59794.43765411858, 64088.262338752, 67979.90288837987, 70983.79771351689, 73394.48645452577, 75770.39633770857, 78145.7175288137, 80819.06143369994, 84365.64617582805, 88587.72969173649, 92543.6392603517, 95699.33415924627, 98512.67816860638, 101536.41794557704, 104775.28985344693, 108693.1138048021, 113849.35525176072, 119783.4745785262, 125911.9487270421, 132171.164367807, 138253.34041645186, 143097.09896949324, 146920.47912005824, 150712.35988926783, 154453.8468969249, 158386.35588267483, 163521.04177025205, 169605.78485175528, 175633.76785626408, 181622.08927915088, 187587.84761578817, 192453.16172821098, 196124.23125513087, 199699.99021174348, 203288.42723039386, 206891.42305547118, 211601.46240272446, 217522.57354924871, 223561.67473367776, 229612.25391551823, 235669.53128025556, 240959.49193300228, 245038.380786478, 248674.15147504635, 252306.27093702962, 255934.09567111672, 260327.57727668583, 265927.76756582456, 271965.3696492929, 278000.9333542085, 284036.47896763874, 289642.99736206955, 294042.80707293085, 297666.93310564634, 301294.2501661641, 304924.52671147644, 308987.496198557, 314260.5000068359, 320311.1086311488, 326357.9784512074, 332397.80768107926, 338334.8381939987, 343061.8343857198, 346672.6609367461, 350273.92328546435, 353866.7617950936, 357547.6710832808, 362427.5211587476, 368418.9796590614, 374424.87137750065, 380456.38409610617, 386524.705596919, 391644.85552145215, 395560.9404586724, 399260.87542302976, 402993.7276847959, 406747.2822974383, 411494.96497083624, 417470.58698329946, 423653.62370353844, 429751.87076032616, 435723.8785151237, 440976.19584172574, 445000.57382926246, 448374.18540782994, 451595.60254968255, 454634.96630677406, 458011.1341046509, 462154.4760394491, 466406.65525226534, 469837.77092872065, 472323.6140151891, 474299.2181660241, 475992.88425800466, 477536.4796793071, 479508.84451209585, 481508.8445120958, 483157.0725633841, 485083.82167789526, 487350.09451662644, 489747.7435774153, 492626.625305557, 495626.625305557, 497862.86816426704, 499252.5261910053, 499882.51229742763, 500003.630569286, 500003.630569286, 500003.630569286, 500000.61302446184, 500000.61302446184, 500000.61302446184, 500000.61302446184, 500000.0, 500000.0];
AOA_anomaly = WorkspaceArray("wa_AOA_anomaly", DataFrame(time = AOA_anomaly_time, value = AOA_anomaly_value));
AOA_altitude = WorkspaceArray("wa_AOA_altitude", DataFrame(time = AOA_altitude_time, value = AOA_altitude_value));
ATO mode
ATO_anomaly_time = [0.0, 110.0, 110.0, 136.0];
ATO_anomaly_value = [0.0, 0.0, 1.0, 1.0];
ATO_altitude_time = [0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0, 25.0, 26.0, 27.0, 28.0, 29.0, 30.0, 31.0, 32.0, 33.0, 34.0, 35.0, 36.0, 37.0, 38.0, 39.0, 40.0, 41.0, 42.0, 43.0, 44.0, 45.0, 46.0, 47.0, 48.0, 49.0, 50.0, 51.0, 52.0, 53.0, 54.0, 55.0, 56.0, 57.0, 58.0, 59.0, 60.0, 61.0, 62.0, 63.0, 64.0, 65.0, 66.0, 67.0, 68.0, 69.0, 70.0, 71.0, 72.0, 73.0, 74.0, 75.0, 76.0, 77.0, 78.0, 79.0, 80.0, 81.0, 82.0, 83.0, 84.0, 85.0, 86.0, 87.0, 88.0, 89.0, 90.0, 91.0, 92.0, 93.0, 94.0, 95.0, 96.0, 97.0, 98.0, 99.0, 100.0, 101.0, 102.0, 103.0, 104.0, 105.0, 106.0, 107.0, 108.0, 109.0, 110.0, 111.0, 112.0, 113.0, 114.0, 115.0, 116.0, 117.0, 118.0, 119.0, 120.0, 121.0, 122.0, 123.0, 124.0, 125.0, 126.0, 127.0, 128.0, 129.0, 130.0, 131.0, 132.0, 133.0, 134.0, 135.0, 136.0];
ATO_altitude_value = [0.0, 2785.921275281699, 5314.497101501311, 7314.497101501311, 8900.475460334066, 10421.203513621582, 11922.305335863419, 13652.710996071612, 15652.710996071612, 17506.369667867322, 19310.380888339918, 21429.93026527767, 23883.169934730176, 27048.620513298272, 31227.00392209639, 35982.89079945362, 40719.295263941734, 44535.64993428104, 47545.35858107984, 50475.334622653834, 53279.623850601994, 56126.25710591658, 59794.43765411858, 64088.262338752, 67979.90288837987, 70983.79771351689, 73394.48645452577, 75770.39633770857, 78145.7175288137, 80819.06143369994, 84365.64617582805, 88587.72969173649, 92543.6392603517, 95699.33415924627, 98512.67816860638, 101536.41794557704, 104775.28985344693, 108693.1138048021, 113849.35525176072, 119783.4745785262, 125911.9487270421, 132171.164367807, 138253.34041645186, 143097.09896949324, 146920.47912005824, 150712.35988926783, 154453.8468969249, 158386.35588267483, 163521.04177025205, 169605.78485175528, 175633.76785626408, 181622.08927915088, 187587.84761578817, 192453.16172821098, 196124.23125513087, 199699.99021174348, 203288.42723039386, 206891.42305547118, 211601.46240272446, 217522.57354924871, 223561.67473367776, 229612.25391551823, 235669.53128025556, 240959.49193300228, 245038.380786478, 248674.15147504635, 252306.27093702962, 255934.09567111672, 260327.57727668583, 265927.76756582456, 271965.3696492929, 278000.9333542085, 284036.47896763874, 289642.99736206955, 294042.80707293085, 297666.93310564634, 301294.2501661641, 304924.52671147644, 308987.496198557, 314260.5000068359, 320311.1086311488, 326357.9784512074, 332397.80768107926, 338334.8381939987, 343061.8343857198, 346672.6609367461, 350273.92328546435, 353866.7617950936, 357547.6710832808, 362427.5211587476, 368418.9796590614, 374424.87137750065, 380456.38409610617, 386524.705596919, 391644.85552145215, 395560.9404586724, 399260.87542302976, 402993.7276847959, 406747.2822974383, 411494.96497083624, 417470.58698329946, 423653.62370353844, 429751.87076032616, 435723.8785151237, 440976.19584172574, 445000.57382926246, 448374.18540782994, 451595.60254968255, 454634.96630677406, 458011.1341046509, 462154.4760394491, 466406.65525226534, 469837.77092872065, 472323.6140151891, 474299.2181660241, 475992.88425800466, 477536.4796793071, 479508.84451209585, 481508.8445120958, 483157.0725633841, 485083.82167789526, 487350.09451662644, 489747.7435774153, 492626.625305557, 495626.625305557, 497862.86816426704, 499252.5261910053, 499882.51229742763, 500003.630569286, 500003.630569286, 500003.630569286, 500000.61302446184, 500000.61302446184, 500000.61302446184, 500000.61302446184, 500000.0, 500000.0];
ATO_anomaly = WorkspaceArray("wa_ATO_anomaly", DataFrame(time = ATO_anomaly_time, value = ATO_anomaly_value));
ATO_altitude = WorkspaceArray("wa_ATO_altitude", DataFrame(time = ATO_altitude_time, value = ATO_altitude_value));
Normal Mode
Normal_anomaly_time = [0.0, 136.0];
Normal_anomaly_value = [0.0, 0.0];
Normal_altitude_time = [0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0, 25.0, 26.0, 27.0, 28.0, 29.0, 30.0, 31.0, 32.0, 33.0, 34.0, 35.0, 36.0, 37.0, 38.0, 39.0, 40.0, 41.0, 42.0, 43.0, 44.0, 45.0, 46.0, 47.0, 48.0, 49.0, 50.0, 51.0, 52.0, 53.0, 54.0, 55.0, 56.0, 57.0, 58.0, 59.0, 60.0, 61.0, 62.0, 63.0, 64.0, 65.0, 66.0, 67.0, 68.0, 69.0, 70.0, 71.0, 72.0, 73.0, 74.0, 75.0, 76.0, 77.0, 78.0, 79.0, 80.0, 81.0, 82.0, 83.0, 84.0, 85.0, 86.0, 87.0, 88.0, 89.0, 90.0, 91.0, 92.0, 93.0, 94.0, 95.0, 96.0, 97.0, 98.0, 99.0, 100.0, 101.0, 102.0, 103.0, 104.0, 105.0, 106.0, 107.0, 108.0, 109.0, 110.0, 111.0, 112.0, 113.0, 114.0, 115.0, 116.0, 117.0, 118.0, 119.0, 120.0, 121.0, 122.0, 123.0, 124.0, 125.0, 126.0, 127.0, 128.0, 129.0, 130.0, 131.0, 132.0, 133.0, 134.0, 135.0, 136.0];
Normal_altitude_value = [0.0, 2785.921275281699, 5314.497101501311, 7314.497101501311, 8900.475460334066, 10421.203513621582, 11922.305335863419, 13652.710996071612, 15652.710996071612, 17506.369667867322, 19310.380888339918, 21429.93026527767, 23883.169934730176, 27048.620513298272, 31227.00392209639, 35982.89079945362, 40719.295263941734, 44535.64993428104, 47545.35858107984, 50475.334622653834, 53279.623850601994, 56126.25710591658, 59794.43765411858, 64088.262338752, 67979.90288837987, 70983.79771351689, 73394.48645452577, 75770.39633770857, 78145.7175288137, 80819.06143369994, 84365.64617582805, 88587.72969173649, 92543.6392603517, 95699.33415924627, 98512.67816860638, 101536.41794557704, 104775.28985344693, 108693.1138048021, 113849.35525176072, 119783.4745785262, 125911.9487270421, 132171.164367807, 138253.34041645186, 143097.09896949324, 146920.47912005824, 150712.35988926783, 154453.8468969249, 158386.35588267483, 163521.04177025205, 169605.78485175528, 175633.76785626408, 181622.08927915088, 187587.84761578817, 192453.16172821098, 196124.23125513087, 199699.99021174348, 203288.42723039386, 206891.42305547118, 211601.46240272446, 217522.57354924871, 223561.67473367776, 229612.25391551823, 235669.53128025556, 240959.49193300228, 245038.380786478, 248674.15147504635, 252306.27093702962, 255934.09567111672, 260327.57727668583, 265927.76756582456, 271965.3696492929, 278000.9333542085, 284036.47896763874, 289642.99736206955, 294042.80707293085, 297666.93310564634, 301294.2501661641, 304924.52671147644, 308987.496198557, 314260.5000068359, 320311.1086311488, 326357.9784512074, 332397.80768107926, 338334.8381939987, 343061.8343857198, 346672.6609367461, 350273.92328546435, 353866.7617950936, 357547.6710832808, 362427.5211587476, 368418.9796590614, 374424.87137750065, 380456.38409610617, 386524.705596919, 391644.85552145215, 395560.9404586724, 399260.87542302976, 402993.7276847959, 406747.2822974383, 411494.96497083624, 417470.58698329946, 423653.62370353844, 429751.87076032616, 435723.8785151237, 440976.19584172574, 445000.57382926246, 448374.18540782994, 451595.60254968255, 454634.96630677406, 458011.1341046509, 462154.4760394491, 466406.65525226534, 469837.77092872065, 472323.6140151891, 474299.2181660241, 475992.88425800466, 477536.4796793071, 479508.84451209585, 481508.8445120958, 483157.0725633841, 485083.82167789526, 487350.09451662644, 489747.7435774153, 492626.625305557, 495626.625305557, 497862.86816426704, 499252.5261910053, 499882.51229742763, 500003.630569286, 500003.630569286, 500003.630569286, 500000.61302446184, 500000.61302446184, 500000.61302446184, 500000.61302446184, 500000.0, 500000.0];
Normal_anomaly = WorkspaceArray("wa_Normal_anomaly", DataFrame(time = Normal_anomaly_time, value = Normal_anomaly_value));
Normal_altitude = WorkspaceArray("wa_Normal_altitude", DataFrame(time = Normal_altitude_time, value = Normal_altitude_value));
Running the simulation
Let's choose the desired scenario for spacecraft flight interruption.:
active_scenario = "RTLS" # @param ["RTLS", "DRL", "AOA", "ATO", "Normal"]
;
Loading the model launchAbortSystem.engee:
launchAbortSystem = engee.load("$demoroot/launch_abort_system.engee");
And let's run her simulation.:
simulationResults = engee.run(launchAbortSystem);
We will close the model after the end of the simulation:
engee.close(launchAbortSystem, force = true);
Simulation results
Importing the simulation results:
launchAbortSystem_dumpFuel_t = simulationResults["dumpFuel"].time;
launchAbortSystem_dumpFuel_y = simulationResults["dumpFuel"].value;
launchAbortSystem_releaseBoosters_t = simulationResults["releaseBoosters"].time;
launchAbortSystem_releaseBoosters_y = simulationResults["releaseBoosters"].value;
launchAbortSystem_releaseTank_t = simulationResults["releaseTank"].time;
launchAbortSystem_releaseTank_y = simulationResults["releaseTank"].value;
And let's build graphs:
plot(launchAbortSystem_dumpFuel_t, launchAbortSystem_dumpFuel_y, label = "Fuel discharge indicator", legend=:bottomright)
plot!(launchAbortSystem_releaseBoosters_t, launchAbortSystem_releaseBoosters_y, label = "A sign of separation of the side boosters")
plot!(launchAbortSystem_releaseTank_t, launchAbortSystem_releaseTank_y, label = "Indication of separation of the external fuel tank")
title!("Emergency flight interruption. $active_scenario mode")
xlabel!("Time, [s]")
ylabel!("Sign")
Conclusions
This project demonstrates the advanced capabilities of the Finite Automata library:
- Hierarchical parallel states;
- Status Activity check operator
in(); - Operator of temporal logic
after(); - Super transitions.
In addition, the project shows the possibility of selecting different test scenarios based on the masks of the code cells of interactive scripts and the "Variant source" block.