1 /**********************************************************************
3 FILENAME: uiuc_menu_ice.cpp
5 ----------------------------------------------------------------------
7 DESCRIPTION: reads input data for specified aircraft and creates
8 approporiate data storage space
10 ----------------------------------------------------------------------
14 ----------------------------------------------------------------------
16 REFERENCES: based on "menu reader" format of Michael Selig
18 ----------------------------------------------------------------------
20 HISTORY: 04/04/2003 initial release
22 ----------------------------------------------------------------------
24 AUTHOR(S): Robert Deters <rdeters@uiuc.edu>
25 Michael Selig <m-selig@uiuc.edu>
27 ----------------------------------------------------------------------
31 ----------------------------------------------------------------------
35 ----------------------------------------------------------------------
39 ----------------------------------------------------------------------
41 CALLED BY: uiuc_menu()
43 ----------------------------------------------------------------------
45 CALLS TO: check_float() if needed
51 ----------------------------------------------------------------------
53 COPYRIGHT: (C) 2003 by Michael Selig
55 This program is free software; you can redistribute it and/or
56 modify it under the terms of the GNU General Public License
57 as published by the Free Software Foundation.
59 This program is distributed in the hope that it will be useful,
60 but WITHOUT ANY WARRANTY; without even the implied warranty of
61 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
62 GNU General Public License for more details.
64 You should have received a copy of the GNU General Public License
65 along with this program; if not, write to the Free Software
66 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
67 USA or view http://www.gnu.org/copyleft/gpl.html.
69 **********************************************************************/
71 #include <simgear/compiler.h>
73 #if defined( __MWERKS__ )
74 // -dw- optimizer chokes (big-time) trying to optimize humongous
75 // loop/switch statements
76 #pragma optimization_level 0
83 #include "uiuc_menu_ice.h"
93 void parse_ice( const string& linetoken2, const string& linetoken3,
94 const string& linetoken4, const string& linetoken5,
95 const string& linetoken6, const string& linetoken7,
96 const string& linetoken8, const string& linetoken9,
97 const string& linetoken10, const string& aircraft_directory,
100 int token_value_convert1, token_value_convert2, token_value_convert3;
101 double datafile_xArray[100][100], datafile_yArray[100];
102 double datafile_zArray[100][100];
103 int datafile_nxArray[100], datafile_ny;
104 istrstream token3(linetoken3.c_str());
105 istrstream token4(linetoken4.c_str());
106 istrstream token5(linetoken5.c_str());
107 istrstream token6(linetoken6.c_str());
108 istrstream token7(linetoken7.c_str());
109 istrstream token8(linetoken8.c_str());
110 istrstream token9(linetoken9.c_str());
111 istrstream token10(linetoken10.c_str());
113 static bool tactilefadef_first = true;
115 switch(ice_map[linetoken2])
119 if (check_float(linetoken3))
120 token3 >> token_value;
123 uiuc_warnings_errors(1, *command_line);
126 iceTime = token_value;
129 case transientTime_flag:
131 if (check_float(linetoken3))
132 token3 >> token_value;
134 uiuc_warnings_errors(1, *command_line);
136 transientTime = token_value;
139 case eta_ice_final_flag:
141 if (check_float(linetoken3))
142 token3 >> token_value;
144 uiuc_warnings_errors(1, *command_line);
146 eta_ice_final = token_value;
149 case beta_probe_wing_flag:
151 if (check_float(linetoken3))
152 token3 >> token_value;
154 uiuc_warnings_errors(1, *command_line);
157 x_probe_wing = token_value;
160 case beta_probe_tail_flag:
162 if (check_float(linetoken3))
163 token3 >> token_value;
165 uiuc_warnings_errors(1, *command_line);
168 x_probe_tail = token_value;
173 if (check_float(linetoken3))
174 token3 >> token_value;
176 uiuc_warnings_errors(1, *command_line);
183 if (check_float(linetoken3))
184 token3 >> token_value;
186 uiuc_warnings_errors(1, *command_line);
193 if (check_float(linetoken3))
194 token3 >> token_value;
196 uiuc_warnings_errors(1, *command_line);
203 if (check_float(linetoken3))
204 token3 >> token_value;
206 uiuc_warnings_errors(1, *command_line);
208 kCD_adot = token_value;
213 if (check_float(linetoken3))
214 token3 >> token_value;
216 uiuc_warnings_errors(1, *command_line);
223 if (check_float(linetoken3))
224 token3 >> token_value;
226 uiuc_warnings_errors(1, *command_line);
228 kCD_de = token_value;
233 if (check_float(linetoken3))
234 token3 >> token_value;
236 uiuc_warnings_errors(1, *command_line);
243 if (check_float(linetoken3))
244 token3 >> token_value;
246 uiuc_warnings_errors(1, *command_line);
253 if (check_float(linetoken3))
254 token3 >> token_value;
256 uiuc_warnings_errors(1, *command_line);
263 if (check_float(linetoken3))
264 token3 >> token_value;
266 uiuc_warnings_errors(1, *command_line);
268 kCX_a2 = token_value;
273 if (check_float(linetoken3))
274 token3 >> token_value;
276 uiuc_warnings_errors(1, *command_line);
278 kCX_a3 = token_value;
283 if (check_float(linetoken3))
284 token3 >> token_value;
286 uiuc_warnings_errors(1, *command_line);
288 kCX_adot = token_value;
293 if (check_float(linetoken3))
294 token3 >> token_value;
296 uiuc_warnings_errors(1, *command_line);
303 if (check_float(linetoken3))
304 token3 >> token_value;
306 uiuc_warnings_errors(1, *command_line);
308 kCX_de = token_value;
313 if (check_float(linetoken3))
314 token3 >> token_value;
316 uiuc_warnings_errors(1, *command_line);
318 kCX_dr = token_value;
323 if (check_float(linetoken3))
324 token3 >> token_value;
326 uiuc_warnings_errors(1, *command_line);
328 kCX_df = token_value;
333 if (check_float(linetoken3))
334 token3 >> token_value;
336 uiuc_warnings_errors(1, *command_line);
338 kCX_adf = token_value;
343 if (check_float(linetoken3))
344 token3 >> token_value;
346 uiuc_warnings_errors(1, *command_line);
353 if (check_float(linetoken3))
354 token3 >> token_value;
356 uiuc_warnings_errors(1, *command_line);
363 if (check_float(linetoken3))
364 token3 >> token_value;
366 uiuc_warnings_errors(1, *command_line);
368 kCL_adot = token_value;
373 if (check_float(linetoken3))
374 token3 >> token_value;
376 uiuc_warnings_errors(1, *command_line);
383 if (check_float(linetoken3))
384 token3 >> token_value;
386 uiuc_warnings_errors(1, *command_line);
388 kCL_de = token_value;
393 if (check_float(linetoken3))
394 token3 >> token_value;
396 uiuc_warnings_errors(1, *command_line);
403 if (check_float(linetoken3))
404 token3 >> token_value;
406 uiuc_warnings_errors(1, *command_line);
413 if (check_float(linetoken3))
414 token3 >> token_value;
416 uiuc_warnings_errors(1, *command_line);
418 kCZ_a2 = token_value;
423 if (check_float(linetoken3))
424 token3 >> token_value;
426 uiuc_warnings_errors(1, *command_line);
428 kCZ_a3 = token_value;
433 if (check_float(linetoken3))
434 token3 >> token_value;
436 uiuc_warnings_errors(1, *command_line);
438 kCZ_adot = token_value;
443 if (check_float(linetoken3))
444 token3 >> token_value;
446 uiuc_warnings_errors(1, *command_line);
453 if (check_float(linetoken3))
454 token3 >> token_value;
456 uiuc_warnings_errors(1, *command_line);
458 kCZ_de = token_value;
463 if (check_float(linetoken3))
464 token3 >> token_value;
466 uiuc_warnings_errors(1, *command_line);
468 kCZ_deb2 = token_value;
473 if (check_float(linetoken3))
474 token3 >> token_value;
476 uiuc_warnings_errors(1, *command_line);
478 kCZ_df = token_value;
483 if (check_float(linetoken3))
484 token3 >> token_value;
486 uiuc_warnings_errors(1, *command_line);
488 kCZ_adf = token_value;
493 if (check_float(linetoken3))
494 token3 >> token_value;
496 uiuc_warnings_errors(1, *command_line);
503 if (check_float(linetoken3))
504 token3 >> token_value;
506 uiuc_warnings_errors(1, *command_line);
513 if (check_float(linetoken3))
514 token3 >> token_value;
516 uiuc_warnings_errors(1, *command_line);
518 kCm_a2 = token_value;
523 if (check_float(linetoken3))
524 token3 >> token_value;
526 uiuc_warnings_errors(1, *command_line);
528 kCm_adot = token_value;
533 if (check_float(linetoken3))
534 token3 >> token_value;
536 uiuc_warnings_errors(1, *command_line);
543 if (check_float(linetoken3))
544 token3 >> token_value;
546 uiuc_warnings_errors(1, *command_line);
548 kCm_de = token_value;
553 if (check_float(linetoken3))
554 token3 >> token_value;
556 uiuc_warnings_errors(1, *command_line);
558 kCm_b2 = token_value;
563 if (check_float(linetoken3))
564 token3 >> token_value;
566 uiuc_warnings_errors(1, *command_line);
573 if (check_float(linetoken3))
574 token3 >> token_value;
576 uiuc_warnings_errors(1, *command_line);
578 kCm_df = token_value;
583 if (check_float(linetoken3))
584 token3 >> token_value;
586 uiuc_warnings_errors(1, *command_line);
593 if (check_float(linetoken3))
594 token3 >> token_value;
596 uiuc_warnings_errors(1, *command_line);
598 kCY_beta = token_value;
603 if (check_float(linetoken3))
604 token3 >> token_value;
606 uiuc_warnings_errors(1, *command_line);
613 if (check_float(linetoken3))
614 token3 >> token_value;
616 uiuc_warnings_errors(1, *command_line);
623 if (check_float(linetoken3))
624 token3 >> token_value;
626 uiuc_warnings_errors(1, *command_line);
628 kCY_da = token_value;
633 if (check_float(linetoken3))
634 token3 >> token_value;
636 uiuc_warnings_errors(1, *command_line);
638 kCY_dr = token_value;
643 if (check_float(linetoken3))
644 token3 >> token_value;
646 uiuc_warnings_errors(1, *command_line);
648 kCY_dra = token_value;
653 if (check_float(linetoken3))
654 token3 >> token_value;
656 uiuc_warnings_errors(1, *command_line);
658 kCY_bdot = token_value;
663 if (check_float(linetoken3))
664 token3 >> token_value;
666 uiuc_warnings_errors(1, *command_line);
673 if (check_float(linetoken3))
674 token3 >> token_value;
676 uiuc_warnings_errors(1, *command_line);
678 kCl_beta = token_value;
683 if (check_float(linetoken3))
684 token3 >> token_value;
686 uiuc_warnings_errors(1, *command_line);
693 if (check_float(linetoken3))
694 token3 >> token_value;
696 uiuc_warnings_errors(1, *command_line);
703 if (check_float(linetoken3))
704 token3 >> token_value;
706 uiuc_warnings_errors(1, *command_line);
708 kCl_da = token_value;
713 if (check_float(linetoken3))
714 token3 >> token_value;
716 uiuc_warnings_errors(1, *command_line);
718 kCl_dr = token_value;
723 if (check_float(linetoken3))
724 token3 >> token_value;
726 uiuc_warnings_errors(1, *command_line);
728 kCl_daa = token_value;
733 if (check_float(linetoken3))
734 token3 >> token_value;
736 uiuc_warnings_errors(1, *command_line);
743 if (check_float(linetoken3))
744 token3 >> token_value;
746 uiuc_warnings_errors(1, *command_line);
748 kCn_beta = token_value;
753 if (check_float(linetoken3))
754 token3 >> token_value;
756 uiuc_warnings_errors(1, *command_line);
763 if (check_float(linetoken3))
764 token3 >> token_value;
766 uiuc_warnings_errors(1, *command_line);
773 if (check_float(linetoken3))
774 token3 >> token_value;
776 uiuc_warnings_errors(1, *command_line);
778 kCn_da = token_value;
783 if (check_float(linetoken3))
784 token3 >> token_value;
786 uiuc_warnings_errors(1, *command_line);
788 kCn_dr = token_value;
793 if (check_float(linetoken3))
794 token3 >> token_value;
796 uiuc_warnings_errors(1, *command_line);
803 if (check_float(linetoken3))
804 token3 >> token_value;
806 uiuc_warnings_errors(1, *command_line);
808 kCn_b3 = token_value;
814 if (check_float(linetoken4))
815 token4 >> token_value;
817 uiuc_warnings_errors(1, *command_line);
819 if (index < 0 || index >= 20)
820 uiuc_warnings_errors(1, *command_line);
821 bootTime[index] = token_value;
822 bootTrue[index] = true;
825 case eta_wing_left_input_flag:
827 eta_from_file = true;
828 eta_wing_left_input = true;
829 eta_wing_left_input_file = aircraft_directory + linetoken3;
830 token4 >> token_value_convert1;
831 token5 >> token_value_convert2;
832 convert_y = uiuc_convert(token_value_convert1);
833 convert_x = uiuc_convert(token_value_convert2);
834 uiuc_1DdataFileReader(eta_wing_left_input_file,
835 eta_wing_left_input_timeArray,
836 eta_wing_left_input_daArray,
837 eta_wing_left_input_ntime);
838 token6 >> token_value;
839 eta_wing_left_input_startTime = token_value;
842 case eta_wing_right_input_flag:
844 eta_from_file = true;
845 eta_wing_right_input = true;
846 eta_wing_right_input_file = aircraft_directory + linetoken3;
847 token4 >> token_value_convert1;
848 token5 >> token_value_convert2;
849 convert_y = uiuc_convert(token_value_convert1);
850 convert_x = uiuc_convert(token_value_convert2);
851 uiuc_1DdataFileReader(eta_wing_right_input_file,
852 eta_wing_right_input_timeArray,
853 eta_wing_right_input_daArray,
854 eta_wing_right_input_ntime);
855 token6 >> token_value;
856 eta_wing_right_input_startTime = token_value;
859 case eta_tail_input_flag:
861 eta_from_file = true;
862 eta_tail_input = true;
863 eta_tail_input_file = aircraft_directory + linetoken3;
864 token4 >> token_value_convert1;
865 token5 >> token_value_convert2;
866 convert_y = uiuc_convert(token_value_convert1);
867 convert_x = uiuc_convert(token_value_convert2);
868 uiuc_1DdataFileReader(eta_tail_input_file,
869 eta_tail_input_timeArray,
870 eta_tail_input_daArray,
871 eta_tail_input_ntime);
872 token6 >> token_value;
873 eta_tail_input_startTime = token_value;
876 case nonlin_ice_case_flag:
878 token3 >> nonlin_ice_case;
883 if (check_float(linetoken3))
884 token3 >> token_value;
886 uiuc_warnings_errors(1, *command_line);
888 eta_tail = token_value;
891 case eta_wing_left_flag:
893 if (check_float(linetoken3))
894 token3 >> token_value;
896 uiuc_warnings_errors(1, *command_line);
898 eta_wing_left = token_value;
901 case eta_wing_right_flag:
903 if (check_float(linetoken3))
904 token3 >> token_value;
906 uiuc_warnings_errors(1, *command_line);
908 eta_wing_right = token_value;
911 case demo_eps_alpha_max_flag:
913 demo_eps_alpha_max = true;
914 demo_eps_alpha_max_file = aircraft_directory + linetoken3;
915 token4 >> token_value_convert1;
916 token5 >> token_value_convert2;
917 convert_y = uiuc_convert(token_value_convert1);
918 convert_x = uiuc_convert(token_value_convert2);
919 uiuc_1DdataFileReader(demo_eps_alpha_max_file,
920 demo_eps_alpha_max_timeArray,
921 demo_eps_alpha_max_daArray,
922 demo_eps_alpha_max_ntime);
923 token6 >> token_value;
924 demo_eps_alpha_max_startTime = token_value;
927 case demo_eps_pitch_max_flag:
929 demo_eps_pitch_max = true;
930 demo_eps_pitch_max_file = aircraft_directory + linetoken3;
931 token4 >> token_value_convert1;
932 token5 >> token_value_convert2;
933 convert_y = uiuc_convert(token_value_convert1);
934 convert_x = uiuc_convert(token_value_convert2);
935 uiuc_1DdataFileReader(demo_eps_pitch_max_file,
936 demo_eps_pitch_max_timeArray,
937 demo_eps_pitch_max_daArray,
938 demo_eps_pitch_max_ntime);
939 token6 >> token_value;
940 demo_eps_pitch_max_startTime = token_value;
943 case demo_eps_pitch_min_flag:
945 demo_eps_pitch_min = true;
946 demo_eps_pitch_min_file = aircraft_directory + linetoken3;
947 token4 >> token_value_convert1;
948 token5 >> token_value_convert2;
949 convert_y = uiuc_convert(token_value_convert1);
950 convert_x = uiuc_convert(token_value_convert2);
951 uiuc_1DdataFileReader(demo_eps_pitch_min_file,
952 demo_eps_pitch_min_timeArray,
953 demo_eps_pitch_min_daArray,
954 demo_eps_pitch_min_ntime);
955 token6 >> token_value;
956 demo_eps_pitch_min_startTime = token_value;
959 case demo_eps_roll_max_flag:
961 demo_eps_roll_max = true;
962 demo_eps_roll_max_file = aircraft_directory + linetoken3;
963 token4 >> token_value_convert1;
964 token5 >> token_value_convert2;
965 convert_y = uiuc_convert(token_value_convert1);
966 convert_x = uiuc_convert(token_value_convert2);
967 uiuc_1DdataFileReader(demo_eps_roll_max_file,
968 demo_eps_roll_max_timeArray,
969 demo_eps_roll_max_daArray,
970 demo_eps_roll_max_ntime);
971 token6 >> token_value;
972 demo_eps_roll_max_startTime = token_value;
975 case demo_eps_thrust_min_flag:
977 demo_eps_thrust_min = true;
978 demo_eps_thrust_min_file = aircraft_directory + linetoken3;
979 token4 >> token_value_convert1;
980 token5 >> token_value_convert2;
981 convert_y = uiuc_convert(token_value_convert1);
982 convert_x = uiuc_convert(token_value_convert2);
983 uiuc_1DdataFileReader(demo_eps_thrust_min_file,
984 demo_eps_thrust_min_timeArray,
985 demo_eps_thrust_min_daArray,
986 demo_eps_thrust_min_ntime);
987 token6 >> token_value;
988 demo_eps_thrust_min_startTime = token_value;
991 case demo_eps_airspeed_max_flag:
993 demo_eps_airspeed_max = true;
994 demo_eps_airspeed_max_file = aircraft_directory + linetoken3;
995 token4 >> token_value_convert1;
996 token5 >> token_value_convert2;
997 convert_y = uiuc_convert(token_value_convert1);
998 convert_x = uiuc_convert(token_value_convert2);
999 uiuc_1DdataFileReader(demo_eps_airspeed_max_file,
1000 demo_eps_airspeed_max_timeArray,
1001 demo_eps_airspeed_max_daArray,
1002 demo_eps_airspeed_max_ntime);
1003 token6 >> token_value;
1004 demo_eps_airspeed_max_startTime = token_value;
1007 case demo_eps_airspeed_min_flag:
1009 demo_eps_airspeed_min = true;
1010 demo_eps_airspeed_min_file = aircraft_directory + linetoken3;
1011 token4 >> token_value_convert1;
1012 token5 >> token_value_convert2;
1013 convert_y = uiuc_convert(token_value_convert1);
1014 convert_x = uiuc_convert(token_value_convert2);
1015 uiuc_1DdataFileReader(demo_eps_airspeed_min_file,
1016 demo_eps_airspeed_min_timeArray,
1017 demo_eps_airspeed_min_daArray,
1018 demo_eps_airspeed_min_ntime);
1019 token6 >> token_value;
1020 demo_eps_airspeed_min_startTime = token_value;
1023 case demo_eps_flap_max_flag:
1025 demo_eps_flap_max = true;
1026 demo_eps_flap_max_file = aircraft_directory + linetoken3;
1027 token4 >> token_value_convert1;
1028 token5 >> token_value_convert2;
1029 convert_y = uiuc_convert(token_value_convert1);
1030 convert_x = uiuc_convert(token_value_convert2);
1031 uiuc_1DdataFileReader(demo_eps_flap_max_file,
1032 demo_eps_flap_max_timeArray,
1033 demo_eps_flap_max_daArray,
1034 demo_eps_flap_max_ntime);
1035 token6 >> token_value;
1036 demo_eps_flap_max_startTime = token_value;
1039 case demo_boot_cycle_tail_flag:
1041 demo_boot_cycle_tail = true;
1042 demo_boot_cycle_tail_file = aircraft_directory + linetoken3;
1043 token4 >> token_value_convert1;
1044 token5 >> token_value_convert2;
1045 convert_y = uiuc_convert(token_value_convert1);
1046 convert_x = uiuc_convert(token_value_convert2);
1047 uiuc_1DdataFileReader(demo_boot_cycle_tail_file,
1048 demo_boot_cycle_tail_timeArray,
1049 demo_boot_cycle_tail_daArray,
1050 demo_boot_cycle_tail_ntime);
1051 token6 >> token_value;
1052 demo_boot_cycle_tail_startTime = token_value;
1055 case demo_boot_cycle_wing_left_flag:
1057 demo_boot_cycle_wing_left = true;
1058 demo_boot_cycle_wing_left_file = aircraft_directory + linetoken3;
1059 token4 >> token_value_convert1;
1060 token5 >> token_value_convert2;
1061 convert_y = uiuc_convert(token_value_convert1);
1062 convert_x = uiuc_convert(token_value_convert2);
1063 uiuc_1DdataFileReader(demo_boot_cycle_wing_left_file,
1064 demo_boot_cycle_wing_left_timeArray,
1065 demo_boot_cycle_wing_left_daArray,
1066 demo_boot_cycle_wing_left_ntime);
1067 token6 >> token_value;
1068 demo_boot_cycle_wing_left_startTime = token_value;
1071 case demo_boot_cycle_wing_right_flag:
1073 demo_boot_cycle_wing_right = true;
1074 demo_boot_cycle_wing_right_file = aircraft_directory + linetoken3;
1075 token4 >> token_value_convert1;
1076 token5 >> token_value_convert2;
1077 convert_y = uiuc_convert(token_value_convert1);
1078 convert_x = uiuc_convert(token_value_convert2);
1079 uiuc_1DdataFileReader(demo_boot_cycle_wing_right_file,
1080 demo_boot_cycle_wing_right_timeArray,
1081 demo_boot_cycle_wing_right_daArray,
1082 demo_boot_cycle_wing_right_ntime);
1083 token6 >> token_value;
1084 demo_boot_cycle_wing_right_startTime = token_value;
1087 case demo_eps_pitch_input_flag:
1089 demo_eps_pitch_input = true;
1090 demo_eps_pitch_input_file = aircraft_directory + linetoken3;
1091 token4 >> token_value_convert1;
1092 token5 >> token_value_convert2;
1093 convert_y = uiuc_convert(token_value_convert1);
1094 convert_x = uiuc_convert(token_value_convert2);
1095 uiuc_1DdataFileReader(demo_eps_pitch_input_file,
1096 demo_eps_pitch_input_timeArray,
1097 demo_eps_pitch_input_daArray,
1098 demo_eps_pitch_input_ntime);
1099 token6 >> token_value;
1100 demo_eps_pitch_input_startTime = token_value;
1103 case demo_ap_Theta_ref_deg_flag:
1105 demo_ap_Theta_ref_deg = true;
1106 demo_ap_Theta_ref_deg_file = aircraft_directory + linetoken3;
1107 token4 >> token_value_convert1;
1108 token5 >> token_value_convert2;
1109 convert_y = uiuc_convert(token_value_convert1);
1110 convert_x = uiuc_convert(token_value_convert2);
1111 uiuc_1DdataFileReader(demo_ap_Theta_ref_deg_file,
1112 demo_ap_Theta_ref_deg_timeArray,
1113 demo_ap_Theta_ref_deg_daArray,
1114 demo_ap_Theta_ref_deg_ntime);
1115 token6 >> token_value;
1116 demo_ap_Theta_ref_deg_startTime = token_value;
1119 case demo_ap_pah_on_flag:
1121 demo_ap_pah_on = true;
1122 demo_ap_pah_on_file = aircraft_directory + linetoken3;
1123 token4 >> token_value_convert1;
1124 token5 >> token_value_convert2;
1125 convert_y = uiuc_convert(token_value_convert1);
1126 convert_x = uiuc_convert(token_value_convert2);
1127 uiuc_1DdataFileReader(demo_ap_pah_on_file,
1128 demo_ap_pah_on_timeArray,
1129 demo_ap_pah_on_daArray,
1130 demo_ap_pah_on_ntime);
1131 token6 >> token_value;
1132 demo_ap_pah_on_startTime = token_value;
1135 case tactilefadef_flag:
1137 int tactilefadef_index, i;
1138 string tactilefadef_file;
1140 tactilefadef = true;
1141 tactilefadef_file = aircraft_directory + linetoken3;
1142 token4 >> tactilefadef_index;
1143 if (tactilefadef_index < 0 || tactilefadef_index >= 30)
1144 uiuc_warnings_errors(1, *command_line);
1145 if (tactilefadef_index > tactilefadef_nf)
1146 tactilefadef_nf = tactilefadef_index;
1147 token5 >> flap_value;
1148 tactilefadef_fArray[tactilefadef_index] = flap_value;
1149 token6 >> token_value_convert1;
1150 token7 >> token_value_convert2;
1151 token8 >> token_value_convert3;
1152 token9 >> tactilefadef_nice;
1153 convert_z = uiuc_convert(token_value_convert1);
1154 convert_x = uiuc_convert(token_value_convert2);
1155 convert_y = uiuc_convert(token_value_convert3);
1156 /* call 2D File Reader with file name (tactilefadef_file) and
1157 conversion factors; function returns array of
1158 elevator deflections (deArray) and corresponding
1159 alpha (aArray) and delta CZ (CZArray) values and
1160 max number of terms in alpha arrays (nAlphaArray)
1161 and delfection array (nde) */
1162 uiuc_2DdataFileReader(tactilefadef_file,
1168 d_2_to_3(datafile_xArray, tactilefadef_aArray, tactilefadef_index);
1169 d_1_to_2(datafile_yArray, tactilefadef_deArray, tactilefadef_index);
1170 d_2_to_3(datafile_zArray, tactilefadef_tactileArray, tactilefadef_index);
1171 i_1_to_2(datafile_nxArray, tactilefadef_nAlphaArray, tactilefadef_index);
1172 tactilefadef_nde[tactilefadef_index] = datafile_ny;
1173 if (tactilefadef_first==true)
1175 if (tactilefadef_nice == 1)
1177 tactilefadef_na_nice = datafile_nxArray[1];
1178 tactilefadef_nde_nice = datafile_ny;
1179 d_1_to_1(datafile_yArray, tactilefadef_deArray_nice);
1180 for (i=1; i<=tactilefadef_na_nice; i++)
1181 tactilefadef_aArray_nice[i] = datafile_xArray[1][i];
1183 tactilefadef_first=false;
1187 case tactile_pitch_flag:
1192 case demo_tactile_flag:
1194 demo_tactile = true;
1195 demo_tactile_file = aircraft_directory + linetoken3;
1196 token4 >> token_value_convert1;
1197 token5 >> token_value_convert2;
1198 convert_y = uiuc_convert(token_value_convert1);
1199 convert_x = uiuc_convert(token_value_convert2);
1200 uiuc_1DdataFileReader(demo_tactile_file,
1201 demo_tactile_timeArray,
1202 demo_tactile_daArray,
1203 demo_tactile_ntime);
1204 token6 >> token_value;
1205 demo_tactile_startTime = token_value;
1208 case demo_ice_tail_flag:
1210 demo_ice_tail = true;
1211 demo_ice_tail_file = aircraft_directory + linetoken3;
1212 token4 >> token_value_convert1;
1213 token5 >> token_value_convert2;
1214 convert_y = uiuc_convert(token_value_convert1);
1215 convert_x = uiuc_convert(token_value_convert2);
1216 uiuc_1DdataFileReader(demo_ice_tail_file,
1217 demo_ice_tail_timeArray,
1218 demo_ice_tail_daArray,
1219 demo_ice_tail_ntime);
1220 token6 >> token_value;
1221 demo_ice_tail_startTime = token_value;
1224 case demo_ice_left_flag:
1226 demo_ice_left = true;
1227 demo_ice_left_file = aircraft_directory + linetoken3;
1228 token4 >> token_value_convert1;
1229 token5 >> token_value_convert2;
1230 convert_y = uiuc_convert(token_value_convert1);
1231 convert_x = uiuc_convert(token_value_convert2);
1232 uiuc_1DdataFileReader(demo_ice_left_file,
1233 demo_ice_left_timeArray,
1234 demo_ice_left_daArray,
1235 demo_ice_left_ntime);
1236 token6 >> token_value;
1237 demo_ice_left_startTime = token_value;
1240 case demo_ice_right_flag:
1242 demo_ice_right = true;
1243 demo_ice_right_file = aircraft_directory + linetoken3;
1244 token4 >> token_value_convert1;
1245 token5 >> token_value_convert2;
1246 convert_y = uiuc_convert(token_value_convert1);
1247 convert_x = uiuc_convert(token_value_convert2);
1248 uiuc_1DdataFileReader(demo_ice_right_file,
1249 demo_ice_right_timeArray,
1250 demo_ice_right_daArray,
1251 demo_ice_right_ntime);
1252 token6 >> token_value;
1253 demo_ice_right_startTime = token_value;
1258 if (ignore_unknown_keywords) {
1261 // print error message
1262 uiuc_warnings_errors(2, *command_line);